Changeset 280 in dev for trunk/abdev/BasicCompiler_Common/include/Source.h
- Timestamp:
- Aug 14, 2007, 8:37:08 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abdev/BasicCompiler_Common/include/Source.h
r279 r280 11 11 12 12 #include <BoostSerializationSupport.h> 13 14 using namespace std;15 16 struct INCLUDEFILEINFO{17 char **ppFileNames;18 int FilesNum;19 int LineOfFile[MAX_LEN];20 };21 13 22 14 class IncludedFilesRelation … … 87 79 buffer = (char *)calloc( 1, 1 ); 88 80 length = 0; 81 } 82 Text( const Text &text ) 83 : length( text.length ) 84 { 85 buffer = (char *)malloc( length + 1 ); 86 memcpy( buffer, text.buffer, length ); 87 buffer[length] = 0; 89 88 } 90 89 ~Text(){ … … 195 194 public: 196 195 BasicSource(){} 196 BasicSource( const BasicSource &basicSource ) 197 : Text( basicSource ) 198 , includedFilesRelation( basicSource.includedFilesRelation ) 199 { 200 } 197 201 ~BasicSource(){} 198 202 … … 222 226 void Addition( const char *buffer ); 223 227 224 bool GetLineInfo( int sourceCodePos, int &line, std::string &fileName ) ;228 bool GetLineInfo( int sourceCodePos, int &line, std::string &fileName ) const; 225 229 226 230 void operator = ( const BasicSource &source ){ … … 238 242 } 239 243 }; 244 typedef std::vector<BasicSource> BasicSources;
Note:
See TracChangeset
for help on using the changeset viewer.