Changeset 365 in dev for trunk/abdev/BasicCompiler_Common/src/Exception.cpp
- Timestamp:
- Nov 11, 2007, 5:15:30 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abdev/BasicCompiler_Common/src/Exception.cpp
r364 r365 38 38 class TryScope 39 39 { 40 int sourceCodePos; 40 41 bool isDefinedFinally; 41 42 … … 61 62 62 63 public: 63 TryScope() 64 : isDefinedFinally( false ) 64 TryScope( int sourceCodePos ) 65 : sourceCodePos( sourceCodePos ) 66 , isDefinedFinally( false ) 65 67 { 66 68 } … … 69 71 } 70 72 73 int GetSourceCodePos() const 74 { 75 return sourceCodePos; 76 } 71 77 const CatchScopes &GetCatchScopes() const 72 78 { … … 237 243 void TryCommand() 238 244 { 239 tryScopes.push_back( TryScope( ) );245 tryScopes.push_back( TryScope( cp ) ); 240 246 tryScopes.back().Try(); 241 247 … … 315 321 SetError(1,NULL,cp); 316 322 return; 323 } 324 325 if( !tryScopes.back().IsDefinedFinally() && !tryScopes.back().IsCatched() ) 326 { 327 // CatchもFinallyも存在しないとき 328 SetError(-108,NULL,tryScopes.back().GetSourceCodePos() ); 317 329 } 318 330
Note:
See TracChangeset
for help on using the changeset viewer.