• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //===--- Demangle.h ---------------------------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #include <cstddef>
11 
12 namespace llvm {
13 /// This is a llvm local version of __cxa_demangle. Other than the name and
14 /// being in the llvm namespace it is identical.
15 ///
16 /// The mangled_name is demangled into buf and returned. If the buffer is not
17 /// large enough, realloc is used to expand it.
18 ///
19 /// The *status will be set to
20 ///   unknown_error: -4
21 ///   invalid_args:  -3
22 ///   invalid_mangled_name: -2
23 ///   memory_alloc_failure: -1
24 ///   success: 0
25 
26 char *itaniumDemangle(const char *mangled_name, char *buf, size_t *n,
27                       int *status);
28 }
29