Ignore:
Timestamp:
Mar 8, 2008, 10:38:39 PM (17 years ago)
Author:
dai_9181
Message:

デリゲートのパラメータや戻り値にクラス型を指定できない不具合を修正。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/abdev/BasicCompiler_Common/include/Delegate.h

    r339 r422  
    44#include <Procedure.h>
    55
    6 class Delegate : public Procedure, public Jenga::Common::ObjectInHashmap<Delegate>
     6class Delegates;
     7
     8class Delegate
     9    : public Procedure
     10    , public Jenga::Common::ObjectInHashmap<Delegate>
    711{
     12    friend Delegates;
     13
     14    std::string paramStr;
     15    std::string returnTypeName;
     16    int sourceIndex;
     17
    818    Parameters dynamicParams;
    919
     20    // XMLシリアライズ用
     21private:
     22    friend class boost::serialization::access;
     23    template<class Archive> void serialize(Archive& ar, const unsigned int version)
     24    {
     25        trace_for_serialize( "serializing - Delegate" );
     26
     27        ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP( Procedure );
     28        ar & BOOST_SERIALIZATION_NVP( dynamicParams );
     29    }
     30
    1031public:
    11     Delegate( const NamespaceScopes &namespaceScopes, const std::string &name, Procedure::Kind procKind, const char *paramStr, const Type &returnType, int nowLine );
     32    Delegate( const NamespaceScopes &namespaceScopes, const std::string &name, Procedure::Kind procKind, const char *paramStr, const std::string &returnTypeName, int sourceIndex )
     33        : Procedure( namespaceScopes, name, procKind, false )
     34        , paramStr( paramStr )
     35        , returnTypeName( returnTypeName )
     36        , sourceIndex( sourceIndex )
     37    {
     38    }
    1239    Delegate()
    1340    {
    1441    }
     42
     43    void RefleshParameterAndReturnType();
    1544
    1645    virtual const std::string &GetKeyName() const
     
    3059    void Collect( const BasicSource &source );
    3160    void GenerateSourceCode( std::string &destSource );
     61    void RefleshParameterAndReturnType();
    3262};
Note: See TracChangeset for help on using the changeset viewer.