Changeset 100 in dev for BasicCompiler_Common/Procedure.h
- Timestamp:
- Apr 24, 2007, 3:17:29 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
BasicCompiler_Common/Procedure.h
r97 r100 1 1 #pragma once 2 3 #include <Namespace.h> 4 #include "Parameter.h" 5 #include "Variable.h" 6 7 class CClass; 8 class CMethod; 2 9 3 10 class Procedure{ … … 10 17 11 18 private: 12 const string name; 19 const string name; // プロシージャ名 13 20 14 21 Kind kind; … … 109 116 110 117 public: 111 // ハッシュリスト用112 UserProc *pNextData;113 118 114 119 UserProc( const string &name, Kind kind, bool isMacro, bool isCdecl, bool isExport ): … … 121 126 isAutoGeneration( false ), 122 127 isCompiled( false ), 123 pNextData( NULL ),124 128 beginOpAddress( 0 ), 125 129 endOpAddress( 0 ) … … 132 136 } 133 137 134 string GetFullName() const 135 { 136 if( HasParentClass() ){ 137 return (string)GetParentClass().name + "." + GetName(); 138 } 139 140 return GetName(); 141 } 138 string GetFullName() const; 142 139 143 140 bool IsMacro() const … … 214 211 return ( GetName()[0] == '~' ); 215 212 } 216 bool IsVirtual() const 217 { 218 if( pMethod == NULL ){ 219 return false; 220 } 221 return ( pMethod->bVirtual != 0 ); 222 } 223 213 bool IsVirtual() const; 224 214 225 215 // バイナリコードの位置 … … 259 249 return *pCompilingUserProc; 260 250 } 251 252 virtual bool EqualName( const string &name ) const; 253 }; 254 255 class GlobalProc : public UserProc 256 { 257 const NamespaceScopes namespaceScopes; 258 public: 259 // ハッシュリスト用 260 GlobalProc *pNextData; 261 262 GlobalProc( const NamespaceScopes &namespaceScopes, const string &name, Kind kind, bool isMacro, bool isCdecl, bool isExport ): 263 UserProc( name, kind, isMacro, isCdecl, isExport ), 264 namespaceScopes( namespaceScopes ), 265 pNextData( NULL ) 266 {} 267 ~GlobalProc(){} 268 269 GlobalProc *Create( const NamespaceScopes &namespaceScopes, char *buffer,int nowLine ); 270 bool AddGlobalProc( const NamespaceScopes &namespaceScopes, char *buffer,int nowLine ); 271 272 const NamespaceScopes &GetNamespaceScopes() const 273 { 274 return namespaceScopes; 275 } 276 277 virtual bool EqualName( const string &name ) const; 261 278 }; 262 279 263 280 class DllProc : public Procedure 264 281 { 282 const NamespaceScopes namespaceScopes; 283 265 284 const string dllFileName; 266 285 const string alias; … … 271 290 DllProc *pNextData; 272 291 273 DllProc( const string &name, Kind kind, bool isCdecl, const string &dllFileName, const string &alias ):292 DllProc( const NamespaceScopes &namespaceScopes, const string &name, Kind kind, bool isCdecl, const string &dllFileName, const string &alias ): 274 293 Procedure( name, kind, isCdecl ), 294 namespaceScopes( namespaceScopes ), 275 295 dllFileName( dllFileName ), 276 296 alias( alias ),
Note:
See TracChangeset
for help on using the changeset viewer.