Changeset 192 in dev for trunk/jenga/include/smoothie
- Timestamp:
- Jun 26, 2007, 5:04:29 AM (17 years ago)
- Location:
- trunk/jenga/include/smoothie
- Files:
-
- 1 deleted
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/jenga/include/smoothie/Class.h
r190 r192 321 321 class Classes 322 322 { 323 protected: 323 324 int GetHashCode(const char *name) const; 324 325 void DestroyClass(CClass *pobj_c); … … 331 332 332 333 const CClass *Find( const string &fullName ) const; 333 const CClass *Find( const NamespaceScopes &namespaceScopes, const string &name ) const;334 virtual const CClass *Find( const NamespaceScopes &namespaceScopes, const string &name ) const = 0; 334 335 335 336 virtual CClass *Create( const NamespaceScopes &namespaceScopes, const NamespaceScopesCollection &importedNamespaces, const char *name) = 0; -
trunk/jenga/include/smoothie/Namespace.h
r170 r192 70 70 } 71 71 72 bool IsImported() const;73 74 72 bool IsLiving() const; 75 73 … … 82 80 bool IsCoverd( const string &name ) const; 83 81 bool IsCoverd( const NamespaceScopes &namespaceScopes ) const; 84 85 // 指定された名前空間が同一エリアと見なされるかどうかをチェック86 static bool IsSameArea( const NamespaceScopes &baseNamespaceScopes, const NamespaceScopes &entryNamespaceScopes ){87 if( entryNamespaceScopes.size() ){88 if( baseNamespaceScopes.IsCoverd( entryNamespaceScopes ) ){89 // 包括しているときは同一と見なす90 return true;91 }92 }93 else{94 if( baseNamespaceScopes.size() ){95 // 名前空間の判断が必要なとき96 if( baseNamespaceScopes.IsImported()97 || baseNamespaceScopes.IsLiving() ){98 // Using指定があるとき99 // または100 // 指定された名前空間が現在の名前空間スコープと同一のとき101 return true;102 }103 }104 else{105 return true;106 }107 }108 109 return false;110 }111 82 }; 112 83 … … 128 99 return IsExist( NamespaceScopes( namespaceStr ) ); 129 100 } 101 102 bool IsImported( const NamespaceScopes &namespaceScopes ) const 103 { 104 const NamespaceScopesCollection &namespaceScopesCollection = *this; 105 BOOST_FOREACH( const NamespaceScopes &tempNamespaceScopes, namespaceScopesCollection ) 106 { 107 if( namespaceScopes.IsEqual( tempNamespaceScopes ) ) 108 { 109 return true; 110 } 111 } 112 return false; 113 } 114 130 115 void SplitNamespace( const char *fullName, char *namespaceStr, char *simpleName ) const; 131 132 bool Imports( const string &namespaceStr );133 116 134 117 static bool CollectNamespaces( const char *source, NamespaceScopesCollection &namespaceScopesCollection ); -
trunk/jenga/include/smoothie/ObjectModule.h
r190 r192 1 1 #pragma once 2 2 3 #include "TypeDef.h"4 3 #include "Namespace.h" 5 4 #include "Procedure.h" … … 24 23 } 25 24 26 // 名前空間27 NamespaceScopesCollection namespaceScopesCollection;28 29 25 // クラス 30 26 virtual Classes &GetClasses() = 0; 31 27 virtual void SetClasses( Classes *pClasses ) = 0; 32 28 virtual bool AutoWrite( const std::string &filePath ) = 0; 33 34 // TypeDef35 TypeDefCollection typeDefs;36 29 37 30 // 関数ポインタ … … 40 33 return *pProcPointers; 41 34 } 42 43 // blittable型44 BlittableTypes blittableTypes;45 35 46 36 // XMLシリアライズ用 -
trunk/jenga/include/smoothie/Procedure.h
r181 r192 281 281 ~DllProc(){} 282 282 283 bool IsEqualSymbol( const NamespaceScopes &namespaceScopes, const string &name ) const;283 virtual bool IsEqualSymbol( const NamespaceScopes &namespaceScopes, const string &name ) const = 0; 284 284 bool IsEqualSymbol( const string &name ) const; 285 285 -
trunk/jenga/include/smoothie/Prototype.h
r190 r192 51 51 52 52 // シンボル比較 53 bool IsEqualSymbol( const NamespaceScopes &namespaceScopes, const string &name ) const;53 virtual bool IsEqualSymbol( const NamespaceScopes &namespaceScopes, const string &name ) const = 0; 54 54 bool IsEqualSymbol( const Prototype &prototype ) const; 55 55 bool IsEqualSymbol( const string &name ) const; -
trunk/jenga/include/smoothie/Smoothie.h
r190 r192 17 17 Smoothie::isUnicode = isUnicode; 18 18 } 19 20 static Meta &GetMeta();21 19 22 20 class Lexical{ -
trunk/jenga/include/smoothie/Type.h
r173 r192 59 59 void SetIndex( LONG_PTR index ){ 60 60 this->index = index; 61 } 62 void SetClassPtr( const CClass *pClass ) 63 { 64 this->pClass = pClass; 61 65 } 62 66 void SetNull(){ … … 130 134 } 131 135 132 static Type String();133 134 136 135 137 private: … … 138 140 public: 139 141 static bool StringToBasicType( const std::string &typeName, int &basicType ); 140 static bool StringToType( const std::string &typeName,Type &type );142 static const char *Type::BasicTypeToCharPtr( const Type &type ); 141 143 static int GetBasicTypeFromSimpleName( const char *variable ); 142 144 }; -
trunk/jenga/include/smoothie/Variable.h
r173 r192 52 52 ~Variable(){} 53 53 54 const NamespaceScopes &GetNamespaceScopes() const 55 { 56 return namespaceScopes; 57 } 58 54 59 void SetArray( const int *pSubScripts ){ 55 60 isArray = true; … … 62 67 } 63 68 64 bool IsEqualSymbol( const Symbol &symbol, bool isSupportStaticMember = true ) const;69 virtual bool IsEqualSymbol( const Symbol &symbol, bool isSupportStaticMember = true ) const = 0; 65 70 66 71 void ConstOff(){
Note:
See TracChangeset
for help on using the changeset viewer.