Project

General

Profile

« Previous | Next » 

Revision 5

Added by Willibald K. almost 10 years ago

Fixing undefined behavior in C++ AST.

View differences:

trunk/compiler/cppAst/ast/serialize/ProtoBufAstTraversal.cpp
void ProtoBufAstTraversal::allocate(const serialize::PBFunctionCall& call){
void* object;
int i = 0;
switch (call.allocate()) {
case serialize::PBAllocation::TIRESIAS_CREATE_IDENTIFIER :
{
// DLL void* TIRESIAS_CREATE_IDENTIFIER(void* context, std::int32_t ordinal, std::int32_t subOrd);
object = TIRESIAS_CREATE_IDENTIFIER (m_context
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value());
, call.parameters(0).int32_value()
, call.parameters(1).int32_value());
break;
}
case serialize::PBAllocation::TIRESIAS_CREATE_TYPE :
{
// DLL void* TIRESIAS_CREATE_TYPE(void* context, std::int32_t ordinal);
object = TIRESIAS_CREATE_TYPE (m_context
, call.parameters(i++).int32_value());
object = TIRESIAS_CREATE_TYPE (m_context, call.parameters(0).int32_value());
break;
}
case serialize::PBAllocation::TIRESIAS_CREATE_STATEMENT :
{
// DLL void* TIRESIAS_CREATE_STATEMENT(void* context, std::int32_t ordinal);
object = TIRESIAS_CREATE_STATEMENT (m_context
, call.parameters(i++).int32_value());
object = TIRESIAS_CREATE_STATEMENT (m_context, call.parameters(0).int32_value());
break;
}
case serialize::PBAllocation::TIRESIAS_CREATE_EXPRESSION :
{
// DLL void* TIRESIAS_CREATE_EXPRESSION(void* context, std::int32_t ordinal, std::int32_t subOrd);
object = TIRESIAS_CREATE_EXPRESSION (m_context
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value());
, call.parameters(0).int32_value()
, call.parameters(1).int32_value());
break;
}
case serialize::PBAllocation::TIRESIAS_CREATE_IDENTIFIERLIST :
......
case serialize::PBAllocation::TIRESIAS_CAST_ASTELEMENT_TO_ISCOPE :
{
// DLL void* TIRESIAS_CAST_ASTELEMENT_TO_ISCOPE(void* context, void* astelement);
object = TIRESIAS_CAST_ASTELEMENT_TO_ISCOPE (m_context
, m_objects.at(call.parameters(i++).uint64_value()));
object = TIRESIAS_CAST_ASTELEMENT_TO_ISCOPE(m_context
, m_objects.at(call.parameters(0).uint64_value()));
break;
}
default:
......
* Calls to functions that add objects to containers, like add identifier to symboltable etc.
* */
void ProtoBufAstTraversal::add(const serialize::PBFunctionCall& call){
int i = 0;
switch (call.add()) {
case serialize::PBAdd::TIRESIAS_ADD_IDENTIFIERTOLIST :
{
// DLL bool TIRESIAS_ADD_IDENTIFIERTOLIST(void* context, void* idList, void* idRef);
TIRESIAS_ADD_IDENTIFIERTOLIST (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_TYPETOLIST :
{
// DLL bool TIRESIAS_ADD_TYPETOLIST(void* context, void* typeList, void* type);
TIRESIAS_ADD_TYPETOLIST (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_STATEMENTTOLIST :
{
// DLL bool TIRESIAS_ADD_STATEMENTTOLIST(void* context, void* stmtList, void* stmntRef);
TIRESIAS_ADD_STATEMENTTOLIST (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_EXPRESSIONTOLIST :
{
// DLL bool TIRESIAS_ADD_EXPRESSIONTOLIST(void* context, void* exprList, void* exprRef);
TIRESIAS_ADD_EXPRESSIONTOLIST (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_IDTOSYMBTAB :
{
// DLL bool TIRESIAS_ADD_IDTOSYMBTAB(void* context, void* symbolTable, void* identifier);
TIRESIAS_ADD_IDTOSYMBTAB (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_PARAMTOLIST :
{
// DLL bool TIRESIAS_ADD_PARAMTOLIST(void* context, void* parameterList, void* par);
TIRESIAS_ADD_PARAMTOLIST (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_ACTIONSYSTEMINSTANCETOLIST :
{
// DLL bool TIRESIAS_ADD_ACTIONSYSTEMINSTANCETOLIST(void* context, void* objectsList, void* instanceRef);
TIRESIAS_ADD_ACTIONSYSTEMINSTANCETOLIST (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
case serialize::PBAdd::TIRESIAS_ADD_IDENTIFIERTOBLOCK :
{
// DLL bool TIRESIAS_ADD_IDENTIFIERTOBLOCK(void* context, void* idList, void* idRef);
TIRESIAS_ADD_IDENTIFIERTOBLOCK (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value()));
break;
}
default:
......
* Calls to functions that initialize the various subtypes of Identifier.
* */
void ProtoBufAstTraversal::identifier(const serialize::PBFunctionCall& call){
int i = 0;
bool ok = true;
switch (call.identifier()) {
case serialize::PBIdentifiers::TIRESIAS_INIT_ENUMIDENTIFIER :
{
// DLL bool TIRESIAS_INIT_ENUMIDENTIFIER(void* context,
// void* enumId, std::int32_t line, std::int32_t col, const char* text,
// void* scopeRef, void* typeRef, bool haveValue, std::int32_t value);
TIRESIAS_INIT_ENUMIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, call.parameters(i++).int32_value());
ok = TIRESIAS_INIT_ENUMIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).bool_value()
, call.parameters(7).int32_value());
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_CONSTIDENTIFIER :
......
// DLL bool TIRESIAS_INIT_CONSTIDENTIFIER(void* context,
// void* constId, std::int32_t line, std::int32_t col, const char* text,
// void* scopeRef, void* typeRef, void* valueRef);
TIRESIAS_INIT_CONSTIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
ok = TIRESIAS_INIT_CONSTIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value()));
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_ATTRIDENTIFIER :
......
// void* attrId, std::int32_t line, std::int32_t col, const char* text,
// void* scopeRef, void* typeRef, void* initRef,
// bool isStatic, bool isControllable, bool isObservable);
TIRESIAS_INIT_ATTRIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, call.parameters(i++).bool_value()
, call.parameters(i++).bool_value());
ok = TIRESIAS_INIT_ATTRIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, call.parameters(7).bool_value()
, call.parameters(8).bool_value()
, call.parameters(9).bool_value());
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_EXPRVARIDENTIFIER :
......
// DLL bool TIRESIAS_INIT_EXPRVARIDENTIFIER(void* context,
// void* exprVarId, std::int32_t line, std::int32_t col, const char* text,
// void* scopeRef, void* typeRef, bool initialized);
TIRESIAS_INIT_EXPRVARIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
ok = TIRESIAS_INIT_EXPRVARIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).bool_value());
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_PARAMIDENTIFIER :
......
// DLL bool TIRESIAS_INIT_PARAMIDENTIFIER(void* context,
// void* paramId, std::int32_t line, std::int32_t column, const char* text,
// void* scopeRef, void* typeRef);
TIRESIAS_INIT_PARAMIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
ok = TIRESIAS_INIT_PARAMIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value()));
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_LOCVARIDENTIFIER :
......
// DLL bool TIRESIAS_INIT_LOCVARIDENTIFIER(void* context,
// void* locVarId, std::int32_t line, std::int32_t column, const char* text,
// void* scopeRef, void* typeRef);
TIRESIAS_INIT_LOCVARIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
ok = TIRESIAS_INIT_LOCVARIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value()));
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_TYPEIDENTIFIER :
......
// DLL bool TIRESIAS_INIT_TYPEIDENTIFIER(void* context,
// void* typeId, std::int32_t line, std::int32_t column, const char* text,
// void* scopeRef, void* typeRef, const char* prefix);
TIRESIAS_INIT_TYPEIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).literal_value().c_str());
ok = TIRESIAS_INIT_TYPEIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).literal_value().c_str());
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_SELFIDENTIFIER :
......
// DLL bool TIRESIAS_INIT_SELFIDENTIFIER(void* context,
// void* typeId, std::int32_t line, std::int32_t column, const char* text,
// void* scopeRef, void* typeRef, const char* prefix);
TIRESIAS_INIT_SELFIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).literal_value().c_str());
ok = TIRESIAS_INIT_SELFIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).literal_value().c_str());
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_METHODIDENTIFIER :
......
// void* methodId, std::int32_t line, std::int32_t column, const char* text,
// void* scopeRef, void* typeRef, const char* prefix, void* parameterListRef,
// void* symbolTableRef, void* bodyRef);
TIRESIAS_INIT_METHODIDENTIFIER (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
ok = TIRESIAS_INIT_METHODIDENTIFIER (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).literal_value().c_str()
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value())
, m_objects.at(call.parameters(9).uint64_value()));
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_MODULE :
......
// DLL bool TIRESIAS_INIT_MODULE(void* context, void* moduleId,
// int line, int column, const char* text, void* scopeRef,
// void* typeRef, const char* prefix, void* symTabRef);
TIRESIAS_INIT_MODULE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value()));
ok = TIRESIAS_INIT_MODULE (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).literal_value().c_str()
, m_objects.at(call.parameters(7).uint64_value()));
break;
}
case serialize::PBIdentifiers::TIRESIAS_INIT_MAINMODULE :
......
// void* moduleId, int line, int column, const char* text,
// void* scopeRef, void* typeRef, const char* prefix,
// void* symTabRef, void* identifierListRef);
TIRESIAS_INIT_MAINMODULE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).literal_value().c_str()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
ok = TIRESIAS_INIT_MAINMODULE (m_context
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, call.parameters(3).literal_value().c_str()
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).literal_value().c_str()
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value()));
break;
}
default:
m_context->logError("Unknown value for enum PBIdentifiers.");
abort();
}
if (!ok) {
m_context->logError("Error initializing identifier.");
abort();
}
}
/**
* Calls to functions that initialize the various subtypes of Type.
* */
void ProtoBufAstTraversal::type(const serialize::PBFunctionCall& call){
int i = 0;
switch (call.type()) {
case serialize::PBTypes::TIRESIAS_INIT_INTTYPE :
{
......
// void* identifierRef, bool anonymousType, std::int32_t low,
// std::int32_t high);
TIRESIAS_INIT_INTTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value());
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, call.parameters(3).int32_value()
, call.parameters(4).int32_value());
break;
}
case serialize::PBTypes::TIRESIAS_INIT_BOOLTYPE :
......
// DLL bool TIRESIAS_INIT_BOOLTYPE(void* context, void* typeId,
// void* identifierRef, bool anonymousType);
TIRESIAS_INIT_BOOLTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value());
break;
}
......
// void* typeId, void* identifierRef,
// bool anonymousType, void* symTabRef, void* intTypeRef);
TIRESIAS_INIT_VALUEDENUMTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value()));
break;
}
case serialize::PBTypes::TIRESIAS_INIT_ENUMTYPE :
......
// void* identifierRef, bool anonymousType,
// void* symTabRef);
TIRESIAS_INIT_ENUMTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, m_objects.at(call.parameters(3).uint64_value()));
break;
}
case serialize::PBTypes::TIRESIAS_INIT_LISTTYPE :
......
// void* identifierRef, bool anonymousType,
// void* innerTypeRef, std::uint32_t maxNumberOfElements);
TIRESIAS_INIT_LISTTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).uint32_value());
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, m_objects.at(call.parameters(3).uint64_value())
, call.parameters(4).uint32_value());
break;
}
case serialize::PBTypes::TIRESIAS_INIT_TUPLETYPE :
......
// void* identifierRef, bool anonymousType,
// void* typeListRef);
TIRESIAS_INIT_TUPLETYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, m_objects.at(call.parameters(3).uint64_value()));
break;
}
case serialize::PBTypes::TIRESIAS_INIT_FUNCTIONTYPE :
......
// bool anonymousType, void* paramTypeListRef,
// void* returnTypeRef, std::int32_t functionKind, bool isPure);
TIRESIAS_INIT_FUNCTIONTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, call.parameters(5).int32_value()
, call.parameters(6).bool_value());
break;
}
case serialize::PBTypes::TIRESIAS_INIT_ACTIONSYSTEMINSTANCE :
......
// void* instance, void* typeRef, const char* name,
// std::int32_t numOfCreatedObjs, void* parentInstanceRef);
TIRESIAS_INIT_ACTIONSYSTEMINSTANCE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).literal_value().c_str()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).literal_value().c_str()
, call.parameters(3).int32_value()
, m_objects.at(call.parameters(4).uint64_value()));
break;
}
case serialize::PBTypes::TIRESIAS_INIT_ACTIONSYSTEMTYPE :
......
// void* derivedObjectsListRef, bool autoConstruction,
// bool isInSystemDescription);
TIRESIAS_INIT_ACTIONSYSTEMTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value()
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value())
, call.parameters(9).bool_value()
, call.parameters(10).bool_value());
break;
}
case serialize::PBTypes::TIRESIAS_INIT_NULLTYPE :
......
// DLL bool TIRESIAS_INIT_NULLTYPE(void* context, void* typeId,
// void* identifierRef, bool anonymousType);
TIRESIAS_INIT_NULLTYPE (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, m_objects.at(call.parameters(1).uint64_value())
, call.parameters(2).bool_value());
break;
}
default:
......
* Calls to functions that initialize the various subtypes of Statement.
* */
void ProtoBufAstTraversal::statement(const serialize::PBFunctionCall& call){
int i = 0;
switch (call.statement()) {
case serialize::PBStatements::TIRESIAS_INIT_SKIP :
{
// DLL bool TIRESIAS_INIT_SKIP(void* context, void* stmnt,
// std::int32_t line, std::int32_t col);
TIRESIAS_INIT_SKIP (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value());
break;
}
case serialize::PBStatements::TIRESIAS_INIT_BREAK :
......
// DLL bool TIRESIAS_INIT_BREAK(void* context, void* stmnt,
// std::int32_t line, std::int32_t col);
TIRESIAS_INIT_BREAK (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value());
break;
}
case serialize::PBStatements::TIRESIAS_INIT_ABORT :
......
// DLL bool TIRESIAS_INIT_ABORT(void* context, void* stmnt,
// std::int32_t line, std::int32_t col);
TIRESIAS_INIT_ABORT (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value());
break;
}
case serialize::PBStatements::TIRESIAS_INIT_NONDETBLOCK :
......
// std::int32_t line, std::int32_t col, void* symTabRef, void* stmtListRef,
// void* scopeRef);
TIRESIAS_INIT_NONDETBLOCK (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value()));
break;
}
case serialize::PBStatements::TIRESIAS_INIT_SEQBLOCK :
......
// std::int32_t line, std::int32_t col, void* symTabRef, void* stmtListRef,
// void* scopeRef, void* filterExprRef);
TIRESIAS_INIT_SEQBLOCK (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value()));
break;
}
case serialize::PBStatements::TIRESIAS_INIT_PRIOBLOCK :
......
// std::int32_t line, std::int32_t col, void* symTabRef, void* stmtListRef,
// void* scopeRef);
TIRESIAS_INIT_PRIOBLOCK (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value()));
break;
}
case serialize::PBStatements::TIRESIAS_INIT_GUARDEDCOMMAND :
......
// void* stmt, std::int32_t line, std::int32_t pos, void* scopeRef,
// void* guardExprRef, void* bodyRef);
TIRESIAS_INIT_GUARDEDCOMMAND (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value()));
break;
}
case serialize::PBStatements::TIRESIAS_INIT_ASSIGNMENT :
......
// void* placeExprListRef, void* valueExprListRef,
// void* symTabRef);
TIRESIAS_INIT_ASSIGNMENT (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value()));
break;
}
case serialize::PBStatements::TIRESIAS_INIT_CALL :
......
// DLL bool TIRESIAS_INIT_CALL(void* context, void* stmt,
// std::int32_t line, std::int32_t pos, void* callExprRef);
TIRESIAS_INIT_CALL (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value()));
break;
}
default:
......
* Calls to functions that initialize the various subtypes of Expression.
* */
void ProtoBufAstTraversal::expression(const serialize::PBFunctionCall& call){
int i = 0;
switch (call.expression()) {
case serialize::PBExpressions::TIRESIAS_INIT_TYPEEXPRESSION :
{
......
// void* expr, std::int32_t line, std::int32_t pos, void* typeRef,
// void* callTargetsIdentifierListRef, void* symbTabRef);
TIRESIAS_INIT_TYPEEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_IDENTIFIEREXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* identifierRef, bool isSelf);
TIRESIAS_INIT_IDENTIFIEREXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, call.parameters(7).bool_value());
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_UNARYEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* child);
TIRESIAS_INIT_UNARYEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_BINARYEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* left, void* right);
TIRESIAS_INIT_BINARYEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_TERNARYEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* left, void* mid, void* right, void* defScopeRef);
TIRESIAS_INIT_TERNARYEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value())
, m_objects.at(call.parameters(9).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_INTVALUEEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// std::int32_t value);
TIRESIAS_INIT_INTVALUEEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).int32_value());
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_BOOLVALUEEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// bool value);
TIRESIAS_INIT_BOOLVALUEEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, call.parameters(6).bool_value());
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_REFVALUEEXPRESSION :
......
// void* expr, std::int32_t line, std::int32_t pos, void* typeRef,
// void* callTargetsIdentifierListRef, void* symbTabRef,void* object);
TIRESIAS_INIT_REFVALUEEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_LISTCONSTRUCTOR :
......
// void* exprList, void* symTab, void* parentScope,
// void* comprehension, bool hasComprehension);
TIRESIAS_INIT_LISTCONSTRUCTOR (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value())
, m_objects.at(call.parameters(9).uint64_value())
, call.parameters(10).bool_value());
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_SETCONSTRUCTOR :
......
// void* exprList, void* symTab, void* parentScope,
// void* comprehension, bool hasComprehension);
TIRESIAS_INIT_SETCONSTRUCTOR (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value())
, m_objects.at(call.parameters(9).uint64_value())
, call.parameters(10).bool_value());
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_TUPLECONSTRUCTOR :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* exprList, void* tupleTypeId, bool isMatcher);
TIRESIAS_INIT_TUPLECONSTRUCTOR (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).bool_value());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, call.parameters(8).bool_value());
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_ACCESSEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* left, void* right);
TIRESIAS_INIT_ACCESSEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_TUPLEMAPACCESSEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* child, void* argument);
TIRESIAS_INIT_TUPLEMAPACCESSEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_CALLEXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* child, void* argumentList, void* scopeRef);
TIRESIAS_INIT_CALLEXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_QUANTIFIEREXPRESSION :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* child, void* symTabRef, void* scopeRef);
TIRESIAS_INIT_QUANTIFIEREXPRESSION (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value()));
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, m_objects.at(call.parameters(7).uint64_value())
, m_objects.at(call.parameters(8).uint64_value()));
break;
}
case serialize::PBExpressions::TIRESIAS_INIT_OBJECTCONSTRUCTOR :
......
// void* callTargetsIdentifierListRef, void* symbTabRef,
// void* instanceList, std::uint32_t currentInstance, const char* name);
TIRESIAS_INIT_OBJECTCONSTRUCTOR (m_context
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).int32_value()
, call.parameters(i++).int32_value()
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, m_objects.at(call.parameters(i++).uint64_value())
, call.parameters(i++).uint32_value()
, call.parameters(i++).literal_value().c_str());
, m_objects.at(call.parameters(0).uint64_value())
, call.parameters(1).int32_value()
, call.parameters(2).int32_value()
, m_objects.at(call.parameters(3).uint64_value())
, m_objects.at(call.parameters(4).uint64_value())
, m_objects.at(call.parameters(5).uint64_value())
, m_objects.at(call.parameters(6).uint64_value())
, call.parameters(7).uint32_value()
, call.parameters(8).literal_value().c_str());
break;
}
default:

Also available in: Unified diff