ldc/gen/mangling.h
Johan Engelen 04b89e642c Windows: Move the prepending of 0x1 to C++ mangled functions from frontend to the backend.
Windows x64 ABI: remove unnecessary \01 from mangled symbol name.

This removes the 0x1 byte from `.mangleof` accessible from user code.
Resolves issue #1519

Also let mangleForLLVM take a std::string, to enable C++11's moves.
2016-05-30 10:18:39 +02:00

31 lines
1,007 B
C++
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//===-- mangling.h --------------------------------------------------------===//
//
// LDC the LLVM D compiler
//
// This file is distributed under the BSD-style LDC license. See the LICENSE
// file for details.
//
//===----------------------------------------------------------------------===//
//
// Tries to centralize functionality for mangling of symbols.
//
//===----------------------------------------------------------------------===//
#ifndef LDC_GEN_MANGLING_H
#define LDC_GEN_MANGLING_H
#include <string>
#include "ddmd/globals.h"
class AggregateDeclaration;
class FuncDeclaration;
class VarDeclaration;
std::string getMangledName(FuncDeclaration *fdecl, LINK link);
std::string getMangledName(VarDeclaration *vd);
std::string getMangledInitSymbolName(AggregateDeclaration *aggrdecl);
std::string getMangledVTableSymbolName(AggregateDeclaration *aggrdecl);
std::string getMangledClassInfoSymbolName(AggregateDeclaration *aggrdecl);
#endif // LDC_GEN_MANGLING_H