Changeset 554 in dev for trunk/ab5.0/abdev/BasicCompiler_Common/src
- Timestamp:
- May 5, 2008, 1:23:46 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ab5.0/abdev/BasicCompiler_Common/src/Source.cpp
r553 r554 7 7 std::vector<std::string> names; 8 8 public: 9 CDefine( int majorVer );10 ~CDefine();11 9 void Free(); 12 void Init( int majorVer );10 void Init( bool isDebug, bool isDll, bool isUnicode, int majorVer ); 13 11 14 12 BOOL add(char *name); … … 18 16 void DirectiveIfdef(char *buffer); 19 17 }; 20 // TODO: バージョン番号の識別子defineが未完成 21 CDefine objDefine(0); 18 CDefine objDefine; 22 19 23 20 … … 92 89 ////////////////////////////////////// 93 90 94 CDefine::CDefine( int majorVer ) 95 { 96 Init( majorVer ); 97 } 98 CDefine::~CDefine() 99 { 100 } 101 void CDefine::Init( int majorVer ) 91 void CDefine::Init( bool isDebug, bool isDll, bool isUnicode, int majorVer ) 102 92 { 103 93 names.clear(); 104 94 105 if( compiler.IsDebug())95 if( isDebug ) 106 96 { 107 97 add("_DEBUG"); … … 112 102 #endif 113 103 114 if( compiler.IsDll())104 if( isDll ) 115 105 { 116 106 add("_DLL"); 117 107 } 118 108 119 if( compiler.IsUnicode())109 if( isUnicode ) 120 110 { 121 111 add( "UNICODE" ); … … 854 844 } 855 845 856 bool BasicSource::ReadFile( const std::string &filePath ){846 bool BasicSource::ReadFile( const std::string &filePath, bool isDebug, bool isDll, bool isUnicode, int majorVer ){ 857 847 if( !Text::ReadFile( filePath ) ){ 858 848 return false; … … 871 861 // #defineと#requireを初期化 872 862 // TODO: バージョン番号の識別子defineが未完成 873 objDefine.Init( 0);863 objDefine.Init( isDebug, isDll, isUnicode, majorVer ); 874 864 requireFiles.clear(); 875 865
Note:
See TracChangeset
for help on using the changeset viewer.