Changeset 600 in dev


Ignore:
Timestamp:
May 10, 2008, 8:50:41 PM (16 years ago)
Author:
dai_9181
Message:

依存関係を整理中

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

Legend:

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

    r515 r600  
    33
    44#define MAX_ARRAYDIM    16
    5 #define VN_SIZE         1024
    65#define MAX_LEN         65535
    76
  • trunk/ab5.0/abdev/BasicCompiler_Common/NumOpe_GetType.cpp

    r598 r600  
    850850                    );
    851851                    if(i3){
    852                         if( compiler.GetObjectModule().meta.GetGlobalConsts().IsStringPtr( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( term ) ) ){
     852                        if( compiler.GetObjectModule().meta.GetGlobalConsts().IsStringPtr( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( term ), compiler.IsUnicode() ) )
     853                        {
    853854                            //リテラル文字列
    854855                            goto StrLiteral;
  • trunk/ab5.0/abdev/BasicCompiler_Common/include/Const.h

    r579 r600  
    6969public:
    7070
    71     void Add( const NamespaceScopes &namespaceScopes, const std::string &name, const char *Expression);
     71    void Add( const NamespaceScopes &namespaceScopes, const std::string &name, _int64 i64data, const Type &type );
    7272    void Add( const NamespaceScopes &namespaceScopes, const std::string &name, int value);
    7373
     
    7979    _int64 GetWholeData( const Symbol &symbol );
    8080    double GetDoubleData( const Symbol &symbol );
    81     bool IsStringPtr( const Symbol &symbol );
     81    bool IsStringPtr( const Symbol &symbol, bool isUnicode );
    8282};
    8383
  • trunk/ab5.0/abdev/BasicCompiler_Common/src/BoostSerializationSupport.cpp

    r523 r600  
    4444
    4545#include <jenga/include/jenga.h>
     46#include <abdev/ab_common/include/ab_common.h>
    4647
    4748#include "../common.h"
  • trunk/ab5.0/abdev/BasicCompiler_Common/src/Const.cpp

    r597 r600  
    77}
    88
    9 void Consts::Add( const NamespaceScopes &namespaceScopes, const std::string &name , const char *Expression)
     9void Consts::Add( const NamespaceScopes &namespaceScopes, const std::string &name, _int64 i64data, const Type &type )
    1010{
    11     _int64 i64data;
    12     Type resultType;
    13     if( !StaticCalculation(false, Expression, 0, &i64data, resultType) ){
    14         //変数の場合
    15         //何もしない(実行領域コンパイル時にdim宣言として扱う)
    16         return;
    17     }
    18 
    19     //リテラル値の場合
    20     //登録を行う
    21 
    22     CConst *newconst = new CConst(namespaceScopes, name, resultType, i64data);
     11    CConst *newconst = new CConst(namespaceScopes, name, type, i64data);
    2312
    2413    //ハッシュリストに追加
     
    6958    return pConst->GetDoubleData();
    7059}
    71 bool Consts::IsStringPtr( const Symbol &symbol ){
     60bool Consts::IsStringPtr( const Symbol &symbol, bool isUnicode ){
    7261    CConst *pConst = GetObjectPtr( symbol );
    7362
     
    7665    const Type &type = pConst->GetType();
    7766
    78     return ( type.GetBasicType() == typeOfPtrChar && type.GetIndex() == LITERAL_STRING );
     67    int charType = isUnicode
     68        ? MAKE_PTR_TYPE(DEF_WORD,1)
     69        : MAKE_PTR_TYPE(DEF_SBYTE,1);
     70
     71    return ( type.GetBasicType() == charType && type.GetIndex() == LITERAL_STRING );
    7972}
    8073
  • trunk/ab5.0/abdev/BasicCompiler_Common/src/LexicalAnalyzer_Const.cpp

    r579 r600  
    173173                    // 定数
    174174                    const char *expression = temporary + i2 + 1;
    175                     consts.Add( namespaceScopes, name, expression );
     175
     176                    _int64 i64data;
     177                    Type resultType;
     178                    if( StaticCalculation(false, expression, 0, &i64data, resultType) )
     179                    {
     180                        consts.Add( namespaceScopes, name, i64data, resultType );
     181                    }
    176182                }
    177183                else
  • trunk/ab5.0/abdev/BasicCompiler_Common/src/ObjectModule.cpp

    r597 r600  
    5353
    5454#include <jenga/include/jenga.h>
     55#include <abdev/ab_common/include/ab_common.h>
    5556
    5657#include "../common.h"
     
    5859
    5960#include <option.h>
    60 
    61 #include <abdev/ab_common/include/ab_common.h>
    6261
    6362using namespace ActiveBasic::Common::Lexical;
  • trunk/ab5.0/abdev/ab_common/include/Lexical/TypeMisc.h

    r599 r600  
    11#pragma once
    22
     3#define VN_SIZE         1024
    34#define PTR_SIZE        sizeof(LONG_PTR)
    45
  • trunk/ab5.0/abdev/compiler_x64/NumOpe.cpp

    r598 r600  
    11581158                    );
    11591159                    if(i3){
    1160                         if( compiler.GetObjectModule().meta.GetGlobalConsts().IsStringPtr( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( term ) ) ){
     1160                        if( compiler.GetObjectModule().meta.GetGlobalConsts().IsStringPtr( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( term ), compiler.IsUnicode() ) ){
    11611161                            //リテラル文字列
    11621162
  • trunk/ab5.0/abdev/compiler_x86/NumOpe.cpp

    r598 r600  
    10581058                    );
    10591059                    if(i3){
    1060                         if( compiler.GetObjectModule().meta.GetGlobalConsts().IsStringPtr( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( term ) ) ){
     1060                        if( compiler.GetObjectModule().meta.GetGlobalConsts().IsStringPtr( ActiveBasic::Compiler::LexicalAnalyzer::FullNameToSymbol( term ), compiler.IsUnicode() ) ){
    10611061                            //リテラル文字列
    10621062
Note: See TracChangeset for help on using the changeset viewer.