Changeset 16ba4a6 for src/CodeGen
- Timestamp:
- Nov 10, 2020, 12:20:37 AM (4 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 18f0b70
- Parents:
- 3febb2d
- Location:
- src/CodeGen
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/CodeGen/CodeGenerator.cc
r3febb2d r16ba4a6 120 120 // GCC builtins should always be printed unmangled 121 121 if ( options.pretty || decl->linkage.is_gcc_builtin ) return decl->name; 122 if ( decl->mangleName != "" ) {122 if ( LinkageSpec::isMangled(decl->linkage) && decl->mangleName != "" ) { 123 123 // need to incorporate scope level in order to differentiate names for destructors 124 124 return decl->get_scopedMangleName(); -
src/CodeGen/FixMain.cc
r3febb2d r16ba4a6 26 26 #include "SynTree/Declaration.h" // for FunctionDecl, operator<< 27 27 #include "SynTree/Type.h" // for FunctionType 28 #include "SymTab/Mangler.h" 28 29 29 30 namespace CodeGen { … … 47 48 if( main_signature ) { 48 49 os << "static inline int invoke_main(int argc, char* argv[], char* envp[]) { (void)argc; (void)argv; (void)envp; return "; 50 main_signature->mangleName = SymTab::Mangler::mangle(main_signature.get()); 49 51 50 52 os << main_signature->get_scopedMangleName() << "("; -
src/CodeGen/FixNames.cc
r3febb2d r16ba4a6 31 31 #include "SynTree/Type.h" // for Type, BasicType, Type::Qualifiers 32 32 #include "SynTree/Visitor.h" // for Visitor, acceptAll 33 #include "CompilationState.h" 33 34 34 35 namespace CodeGen { … … 102 103 if ( dwt->get_name() != "" ) { 103 104 if ( LinkageSpec::isMangled( dwt->get_linkage() ) ) { 104 dwt->set_mangleName( SymTab::Mangler::mangle( dwt ) ); 105 if (!useNewAST) { 106 dwt->set_mangleName( SymTab::Mangler::mangle( dwt ) ); 107 } 105 108 dwt->set_scopeLevel( scopeLevel ); 106 109 } // if
Note: See TracChangeset
for help on using the changeset viewer.