Changes in src/GenPoly/GenPoly.h [bfae637:8488c715]
- File:
-
- 1 edited
-
src/GenPoly/GenPoly.h (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/GenPoly/GenPoly.h
rbfae637 r8488c715 17 17 #define GENPOLY_H 18 18 19 #include <map> 19 20 #include <string> 20 21 #include <iostream> 21 22 #include <utility> 22 23 #include "ErasableScopedMap.h"24 25 #include "SymTab/Mangler.h"26 23 27 24 #include "SynTree/Declaration.h" … … 30 27 31 28 namespace GenPoly { 32 typedef ErasableScopedMap< std::string, TypeDecl::Kind > TyVarMap;29 typedef std::map< std::string, TypeDecl::Kind > TyVarMap; 33 30 34 31 /// A function needs an adapter if it returns a polymorphic value or if any of its … … 72 69 void printTyVarMap( std::ostream &os, const TyVarMap &tyVarMap ); 73 70 74 /// Gets the mangled name of this type; alias for SymTab::Mangler::mangleType(). 75 inline std::string mangleType( Type *ty ) { return SymTab::Mangler::mangleType( ty ); } 76 77 /// Gets the name of the sizeof parameter for the type, given its mangled name 78 inline std::string sizeofName( const std::string &name ) { return std::string( "_sizeof_" ) + name; } 71 /// Gets the name of the sizeof parameter for the type 72 std::string sizeofName( Type *ty ); 79 73 80 /// Gets the name of the alignof parameter for the type , given its mangled name81 inline std::string alignofName( const std::string &name ) { return std::string( "_alignof_" ) + name; }74 /// Gets the name of the alignof parameter for the type 75 std::string alignofName( Type *ty ); 82 76 83 /// Gets the name of the offsetof parameter for the type, given its mangled name 84 inline std::string offsetofName( const std::string &name ) { return std::string( "_offsetof_" ) + name; } 85 86 /// Gets the name of the layout function for a given aggregate type, given its declaration 87 inline std::string layoutofName( AggregateDecl *decl ) { return std::string( "_layoutof_" ) + decl->get_name(); } 88 77 /// Gets the name of the offsetof parameter for the type 78 std::string offsetofName( Type *ty ); 89 79 } // namespace GenPoly 90 80
Note:
See TracChangeset
for help on using the changeset viewer.