Changes in src/SymTab/Mangler.h [052cd71:d76c588]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/SymTab/Mangler.h
r052cd71 rd76c588 21 21 #include <utility> // for pair 22 22 23 #include "AST/Bitfield.hpp" 24 #include "AST/Fwd.hpp" 23 25 #include "SynTree/SynTree.h" // for Types 24 26 #include "SynTree/Visitor.h" // for Visitor, maybeAccept … … 75 77 } // SymTab 76 78 79 namespace Mangle { 80 /// Bitflags for mangle modes 81 enum { 82 NoOverrideable = 1 << 0, 83 Type = 1 << 1, 84 NoGenericParams = 1 << 2 85 }; 86 87 /// Bitflag type for mangler modes 88 struct mangle_flags { 89 union { 90 unsigned int val; 91 struct { 92 bool no_overrideable : 1; 93 bool type : 1; 94 bool no_generic_params : 1; 95 }; 96 }; 97 98 constexpr mangle_flags( unsigned int val ) : val(val) {} 99 }; 100 101 using Mode = bitfield<mangle_flags>; 102 103 /// Mangle declaration name 104 std::string mangle( const ast::Node * decl, Mode mode = {} ); 105 106 namespace Encoding { 107 using namespace SymTab::Mangler::Encoding; 108 }; 109 } 110 77 111 extern "C" { 78 112 char * cforall_demangle(const char *, int);
Note: See TracChangeset
for help on using the changeset viewer.