Changeset 580 in dev for trunk/ab5.0/abdev


Ignore:
Timestamp:
May 8, 2008, 3:36:08 PM (17 years ago)
Author:
dai_9181
Message:

VariableクラスのLexicalAnalyzerクラスへの依存性をなくした。

Location:
trunk/ab5.0/abdev
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/ab5.0/abdev/BasicCompiler_Common/include/Variable.h

    r570 r580  
    5252
    5353public:
    54     Variable( const std::string &name, const Type &type, bool isConst, bool isRef, const std::string &paramStrForConstructor, bool hasInitData );
     54    Variable( const Symbol &symbol, const Type &type, bool isConst, bool isRef, const std::string &paramStrForConstructor, bool hasInitData );
    5555    Variable( const NamespaceScopes &namespaceScopes, const std::string &name, const Type &type, bool isConst, bool isRef, const std::string &paramStrForConstructor, bool hasInitData );
    5656    Variable( const Variable &var );
  • trunk/ab5.0/abdev/BasicCompiler_Common/src/Variable.cpp

    r570 r580  
    44#include <Variable.h>
    55
    6 Variable::Variable( const std::string &name, const Type &type, bool isConst, bool isRef, const std::string &paramStrForConstructor, bool hasInitData )
    7     : Symbol( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( name ) )
     6Variable::Variable( const Symbol &symbol, const Type &type, bool isConst, bool isRef, const std::string &paramStrForConstructor, bool hasInitData )
     7    : Symbol( symbol )
    88    , type( type )
    99    , isConst( isConst )
  • trunk/ab5.0/abdev/compiler_x86/Compile_ProcOp.cpp

    r565 r580  
    352352        Parameter &param = *pUserProc->RealParams()[i3];
    353353
    354         Variable *pVar = new Variable( param.GetVarName(), param, false, param.IsRef(), "", false );
     354        Variable *pVar = new Variable(
     355            ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( param.GetVarName().c_str() ),
     356            param,
     357            false,
     358            param.IsRef(),
     359            "",
     360            false
     361        );
    355362
    356363        if( param.IsArray() ){
  • trunk/ab5.0/abdev/compiler_x86/Compile_Var.cpp

    r570 r580  
    11181118        bool isConst = ( dwFlags & DIMFLAG_CONST ) ? true:false;
    11191119
    1120         Variable *pVar = new Variable( VarName, type, isConst, false, ConstractParameter, false );
     1120        Variable *pVar = new Variable(
     1121            ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( VarName ),
     1122            type,
     1123            isConst,
     1124            false,
     1125            ConstractParameter,
     1126            false
     1127        );
    11211128
    11221129        if( subscripts.size() > 0 ){
Note: See TracChangeset for help on using the changeset viewer.