Changeset 206 in dev for trunk/abdev/BasicCompiler_Common/include/TypeDef.h
- Timestamp:
- Jul 12, 2007, 2:58:26 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abdev/BasicCompiler_Common/include/TypeDef.h
r193 r206 4 4 #include <string> 5 5 6 #include <jenga/include/smoothie/Type.h>7 6 #include <jenga/include/smoothie/Namespace.h> 7 8 #include <Type.h> 9 #include <Symbol.h> 8 10 9 11 using namespace std; … … 11 13 class TypeDefCollection; 12 14 13 class TypeDef{ 15 class TypeDef : public Symbol 16 { 14 17 friend TypeDefCollection; 15 18 16 NamespaceScopes namespaceScopes;17 18 string name;19 19 string baseName; 20 20 Type baseType; 21 22 // XMLシリアライズ用 23 private: 24 friend class boost::serialization::access; 25 template<class Archive> void serialize(Archive& ar, const unsigned int version) 26 { 27 trace_for_serialize( "serializing - TypeDef" ); 28 29 ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP( Symbol ); 30 ar & BOOST_SERIALIZATION_NVP( baseName ); 31 ar & BOOST_SERIALIZATION_NVP( baseType ); 32 } 33 21 34 public: 22 35 TypeDef( const NamespaceScopes &namespaceScopes, const string &name, const string &baseName, int nowLine ); 23 ~TypeDef(); 36 TypeDef() 37 { 38 } 39 ~TypeDef() 40 { 41 } 24 42 25 const string &GetName() const26 {27 return name;28 }29 43 const string &GetBaseName() const 30 44 { … … 35 49 return baseType; 36 50 } 37 38 bool IsEqualSymbol( const NamespaceScopes &namespaceScopes, const string &name ) const;39 bool IsEqualSymbol( const string &name ) const;40 51 }; 41 52 42 class TypeDefCollection : public vector<TypeDef>53 class TypeDefCollection : public std::vector<TypeDef> 43 54 { 55 // XMLシリアライズ用 56 private: 57 friend class boost::serialization::access; 58 template<class Archive> void serialize(Archive& ar, const unsigned int version) 59 { 60 trace_for_serialize( "serializing - TypeDefCollection" ); 61 62 ar & boost::serialization::make_nvp("vector_TypeDef", 63 boost::serialization::base_object<std::vector<TypeDef>>(*this)); 64 } 65 44 66 public: 45 67 TypeDefCollection();
Note:
See TracChangeset
for help on using the changeset viewer.