Ignore:
Timestamp:
Nov 15, 2007, 6:57:26 PM (16 years ago)
Author:
dai_9181
Message:

パラメータなしのCatchが無限ループしてしまうバグを修正

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/abdev/BasicCompiler_Common/src/Exception.cpp

    r366 r371  
    173173        if( !isDefinedFinally )
    174174        {
    175             Finally();
     175            SetError();
    176176        }
    177177
     
    284284    tryScopes.back().Catch( paramType );
    285285
     286    int backCp = cp;
     287
     288    char temporary[1024];
    286289    if( paramType.IsObject() )
    287290    {
    288         int backCp = cp;
    289 
    290         char temporary[1024];
    291291        sprintf( temporary, "Dim %s = Thread.CurrentThread().__GetThrowintParamObject() As %s", varName, paramType.GetClass().GetFullName().c_str() );
    292292        MakeMiddleCode( temporary );
    293293        ChangeOpcode( temporary );
    294         lstrcpy( temporary, "Thread.CurrentThread().__Catched()" );
    295         MakeMiddleCode( temporary );
    296         ChangeOpcode( temporary );
    297 
    298         cp = backCp;
    299     }
     294    }
     295    lstrcpy( temporary, "Thread.CurrentThread().__Catched()" );
     296    MakeMiddleCode( temporary );
     297    ChangeOpcode( temporary );
     298
     299    cp = backCp;
    300300}
    301301void FinallyCommand()
Note: See TracChangeset for help on using the changeset viewer.