Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0 |
Ingo Molnar | 3b7646e | 2013-09-30 15:53:31 +0200 | [diff] [blame] | 2 | #include <bfd.h> |
| 3 | |
Ingo Molnar | 1e3f30f | 2013-10-02 15:48:49 +0200 | [diff] [blame] | 4 | extern int printf(const char *format, ...); |
| 5 | |
Ingo Molnar | 3b7646e | 2013-09-30 15:53:31 +0200 | [diff] [blame] | 6 | int main(void) |
| 7 | { |
Ingo Molnar | 1e3f30f | 2013-10-02 15:48:49 +0200 | [diff] [blame] | 8 | char symbol[4096] = "FieldName__9ClassNameFd"; |
| 9 | char *tmp; |
| 10 | |
| 11 | tmp = bfd_demangle(0, symbol, 0); |
| 12 | |
| 13 | printf("demangled symbol: {%s}\n", tmp); |
| 14 | |
Ingo Molnar | 3b7646e | 2013-09-30 15:53:31 +0200 | [diff] [blame] | 15 | return 0; |
| 16 | } |