Commit 183d1167 authored by John van Groningen's avatar John van Groningen
Browse files

update backend.icl and dcl generated from backend.h updated by commit:

add BENumberedVarTypeNode and BENumberedTypeVar to set tv_argument_nr in type definitions,
add BESetMemberTypeOfField to store the member type of dictionary fields
parent a9a6835d
......@@ -49,6 +49,8 @@ BEBindSpecialModule :: !BESpecialIdentIndex !Int !BackEnd -> BackEnd;
// void BEBindSpecialModule (BESpecialIdentIndex index,int moduleIndex);
BEBindSpecialFunction :: !BESpecialIdentIndex !Int !Int !BackEnd -> BackEnd;
// void BEBindSpecialFunction (BESpecialIdentIndex index,int functionIndex,int moduleIndex);
BEBindSpecialType :: !Int !Int !Int !BackEnd -> BackEnd;
// void BEBindSpecialType (int special_type_n,int type_index,int module_index);
BESpecialArrayFunctionSymbol :: !BEArrayFunKind !Int !Int !BackEnd -> (!BESymbolP,!BackEnd);
// BESymbolP BESpecialArrayFunctionSymbol (BEArrayFunKind arrayFunKind,int functionIndex,int moduleIndex);
BEDictionarySelectFunSymbol :: !BackEnd -> (!BESymbolP,!BackEnd);
......@@ -93,6 +95,8 @@ BEBasicSymbol :: !Int !BackEnd -> (!BESymbolP,!BackEnd);
// BESymbolP BEBasicSymbol (BESymbKind kind);
BEVarTypeNode :: !String !BackEnd -> (!BETypeNodeP,!BackEnd);
// BETypeNodeP BEVarTypeNode (CleanString name);
BENumberedVarTypeNode :: !String !Int !BackEnd -> (!BETypeNodeP,!BackEnd);
// BETypeNodeP BENumberedVarTypeNode (CleanString name,int argument_n);
BETypeVarListElem :: !BETypeVarP !BEAttribution !BackEnd -> (!BETypeVarListP,!BackEnd);
// BETypeVarListP BETypeVarListElem (BETypeVarP typeVar,BEAttribution attribute);
BETypeVars :: !BETypeVarListP !BETypeVarListP !BackEnd -> (!BETypeVarListP,!BackEnd);
......@@ -143,6 +147,8 @@ BESwitchNode :: !BENodeIdP !BEArgP !BackEnd -> (!BENodeP,!BackEnd);
// BENodeP BESwitchNode (BENodeIdP nodeId,BEArgP caseNode);
BECaseNode :: !Int !BESymbolP !BENodeDefP !BEStrictNodeIdP !BENodeP !BackEnd -> (!BENodeP,!BackEnd);
// BENodeP BECaseNode (int symbolArity,BESymbolP symbol,BENodeDefP nodeDefs,BEStrictNodeIdP strictNodeIds,BENodeP node);
BEOverloadedCaseNode :: !BENodeP !BENodeP !BENodeP !BackEnd -> (!BENodeP,!BackEnd);
// BENodeP BEOverloadedCaseNode (BENodeP case_node,BENodeP equal_node,BENodeP from_integer_node);
BEEnterLocalScope :: !BackEnd -> BackEnd;
// void BEEnterLocalScope ();
BELeaveLocalScope :: !BENodeP !BackEnd -> BackEnd;
......@@ -221,6 +227,8 @@ BEDeclareField :: !Int !Int !String !BackEnd -> BackEnd;
// void BEDeclareField (int fieldIndex,int moduleIndex,CleanString name);
BEField :: !Int !Int !BETypeNodeP !BackEnd -> (!BEFieldListP,!BackEnd);
// BEFieldListP BEField (int fieldIndex,int moduleIndex,BETypeNodeP type);
BESetMemberTypeOfField :: !Int !Int !BETypeAltP !BackEnd -> BackEnd;
// void BESetMemberTypeOfField (int fieldIndex,int moduleIndex,BETypeAltP typeAlt);
BEFields :: !BEFieldListP !BEFieldListP !BackEnd -> (!BEFieldListP,!BackEnd);
// BEFieldListP BEFields (BEFieldListP field,BEFieldListP fields);
BENoFields :: !BackEnd -> (!BEFieldListP,!BackEnd);
......@@ -229,10 +237,14 @@ BEDeclareConstructor :: !Int !Int !String !BackEnd -> BackEnd;
// void BEDeclareConstructor (int constructorIndex,int moduleIndex,CleanString name);
BETypeVar :: !String !BackEnd -> (!BETypeVarP,!BackEnd);
// BETypeVarP BETypeVar (CleanString name);
BENumberedTypeVar :: !String !Int !BackEnd -> (!BETypeVarP,!BackEnd);
// BETypeVarP BENumberedTypeVar (CleanString name,int argument_n);
BEDeclareType :: !Int !Int !String !BackEnd -> BackEnd;
// void BEDeclareType (int typeIndex,int moduleIndex,CleanString name);
BEDeclareFunction :: !String !Int !Int !Int !BackEnd -> BackEnd;
// void BEDeclareFunction (CleanString name,int arity,int functionIndex,int ancestor);
BEStartFunction :: !Int !BackEnd -> BackEnd;
// void BEStartFunction (int functionIndex);
BECodeAlt :: !Int !BENodeDefP !BENodeP !BECodeBlockP !BackEnd -> (!BERuleAltP,!BackEnd);
// BERuleAltP BECodeAlt (int line,BENodeDefP lhsDefs,BENodeP lhs,BECodeBlockP codeBlock);
BEString :: !String !BackEnd -> (!BEStringListP,!BackEnd);
......@@ -254,7 +266,7 @@ BENodeIds :: !BENodeIdListP !BENodeIdListP !BackEnd -> (!BENodeIdListP,!BackEnd)
BENoNodeIds :: !BackEnd -> (!BENodeIdListP,!BackEnd);
// BENodeIdListP BENoNodeIds ();
BEAbcCodeBlock :: !Bool !BEStringListP !BackEnd -> (!BECodeBlockP,!BackEnd);
// BECodeBlockP BEAbcCodeBlock (int inline,BEStringListP instructions);
// BECodeBlockP BEAbcCodeBlock (int inlineFlag,BEStringListP instructions);
BEAnyCodeBlock :: !BECodeParameterP !BECodeParameterP !BEStringListP !BackEnd -> (!BECodeBlockP,!BackEnd);
// BECodeBlockP BEAnyCodeBlock (BECodeParameterP inParams,BECodeParameterP outParams,BEStringListP instructions);
BEDeclareIclModule :: !String !String !Int !Int !Int !Int !BackEnd -> BackEnd;
......@@ -267,6 +279,8 @@ BEDefineRules :: !BEImpRuleP !BackEnd -> BackEnd;
// void BEDefineRules (BEImpRuleP rules);
BEGenerateCode :: !String !BackEnd -> (!Bool,!BackEnd);
// int BEGenerateCode (CleanString outputFile);
BEGetError :: {#Char};
// CleanString BEGetError ();
BEExportType :: !Bool !Int !BackEnd -> BackEnd;
// void BEExportType (int isDictionary,int typeIndex);
BEExportConstructor :: !Int !BackEnd -> BackEnd;
......@@ -283,7 +297,7 @@ BESetMainDclModuleN :: !Int !BackEnd -> BackEnd;
// void BESetMainDclModuleN (int main_dcl_module_n_parameter);
BEStrictPositions :: !Int !BackEnd -> (!Int,!Int,!BackEnd);
// void BEStrictPositions (int functionIndex,int* bits,int** positions);
//BECopyInts :: !Int !Int !Int -> Int;
BECopyInts :: !Int !Int !Int -> Int;
// int BECopyInts (int cLength,int* ints,int* cleanArray);
BEGetIntFromArray :: !Int !Int -> Int;
// int BEGetIntFromArray (int index,int* ints);
......@@ -313,7 +327,7 @@ BEStringType:==5;
BEWorldType:==6;
BEProcIdType:==7;
BERedIdType:==8;
BENrOfBasicTypes:==9;
BERationalDenot:==9;
BEIntDenot:==10;
BEBoolDenot:==11;
BECharDenot:==12;
......@@ -369,6 +383,8 @@ BESpecialIdentUndef:==2;
BESpecialIdentStdBool:==3;
BESpecialIdentAnd:==4;
BESpecialIdentOr:==5;
BESpecialIdentPrelude:==6;
BESpecialIdentSeq:==7;
BESpecialIdentCount:==8;
BELhsNodeId:==0;
BERhsNodeId:==1;
......
......@@ -82,6 +82,12 @@ BEBindSpecialFunction a0 a1 a2 a3 = code {
}
// void BEBindSpecialFunction (BESpecialIdentIndex index,int functionIndex,int moduleIndex);
BEBindSpecialType :: !Int !Int !Int !BackEnd -> BackEnd;
BEBindSpecialType a0 a1 a2 a3 = code {
ccall BEBindSpecialType "III:V:p"
}
// void BEBindSpecialType (int special_type_n,int type_index,int module_index);
BESpecialArrayFunctionSymbol :: !BEArrayFunKind !Int !Int !BackEnd -> (!BESymbolP,!BackEnd);
BESpecialArrayFunctionSymbol a0 a1 a2 a3 = code {
ccall BESpecialArrayFunctionSymbol "III:p:p"
......@@ -214,6 +220,12 @@ BEVarTypeNode a0 a1 = code {
}
// BETypeNodeP BEVarTypeNode (CleanString name);
BENumberedVarTypeNode :: !String !Int !BackEnd -> (!BETypeNodeP,!BackEnd);
BENumberedVarTypeNode a0 a1 a2 = code {
ccall BENumberedVarTypeNode "SI:p:p"
}
// BETypeNodeP BENumberedVarTypeNode (CleanString name,int argument_n);
BETypeVarListElem :: !BETypeVarP !BEAttribution !BackEnd -> (!BETypeVarListP,!BackEnd);
BETypeVarListElem a0 a1 a2 = code {
ccall BETypeVarListElem "pI:p:p"
......@@ -364,6 +376,12 @@ BECaseNode a0 a1 a2 a3 a4 a5 = code {
}
// BENodeP BECaseNode (int symbolArity,BESymbolP symbol,BENodeDefP nodeDefs,BEStrictNodeIdP strictNodeIds,BENodeP node);
BEOverloadedCaseNode :: !BENodeP !BENodeP !BENodeP !BackEnd -> (!BENodeP,!BackEnd);
BEOverloadedCaseNode a0 a1 a2 a3 = code {
ccall BEOverloadedCaseNode "ppp:p:p"
}
// BENodeP BEOverloadedCaseNode (BENodeP case_node,BENodeP equal_node,BENodeP from_integer_node);
BEEnterLocalScope :: !BackEnd -> BackEnd;
BEEnterLocalScope a0 = code {
ccall BEEnterLocalScope ":V:p"
......@@ -598,6 +616,12 @@ BEField a0 a1 a2 a3 = code {
}
// BEFieldListP BEField (int fieldIndex,int moduleIndex,BETypeNodeP type);
BESetMemberTypeOfField :: !Int !Int !BETypeAltP !BackEnd -> BackEnd;
BESetMemberTypeOfField a0 a1 a2 a3 = code {
ccall BESetMemberTypeOfField "IIp:V:p"
}
// void BESetMemberTypeOfField (int fieldIndex,int moduleIndex,BETypeAltP typeAlt);
BEFields :: !BEFieldListP !BEFieldListP !BackEnd -> (!BEFieldListP,!BackEnd);
BEFields a0 a1 a2 = code {
ccall BEFields "pp:p:p"
......@@ -622,6 +646,12 @@ BETypeVar a0 a1 = code {
}
// BETypeVarP BETypeVar (CleanString name);
BENumberedTypeVar :: !String !Int !BackEnd -> (!BETypeVarP,!BackEnd);
BENumberedTypeVar a0 a1 a2 = code {
ccall BENumberedTypeVar "SI:p:p"
}
// BETypeVarP BENumberedTypeVar (CleanString name,int argument_n);
BEDeclareType :: !Int !Int !String !BackEnd -> BackEnd;
BEDeclareType a0 a1 a2 a3 = code {
ccall BEDeclareType "IIS:V:p"
......@@ -634,6 +664,12 @@ BEDeclareFunction a0 a1 a2 a3 a4 = code {
}
// void BEDeclareFunction (CleanString name,int arity,int functionIndex,int ancestor);
BEStartFunction :: !Int !BackEnd -> BackEnd;
BEStartFunction a0 a1 = code {
ccall BEStartFunction "I:V:p"
}
// void BEStartFunction (int functionIndex);
BECodeAlt :: !Int !BENodeDefP !BENodeP !BECodeBlockP !BackEnd -> (!BERuleAltP,!BackEnd);
BECodeAlt a0 a1 a2 a3 a4 = code {
ccall BECodeAlt "Ippp:p:p"
......@@ -698,7 +734,7 @@ BEAbcCodeBlock :: !Bool !BEStringListP !BackEnd -> (!BECodeBlockP,!BackEnd);
BEAbcCodeBlock a0 a1 a2 = code {
ccall BEAbcCodeBlock "Ip:p:p"
}
// BECodeBlockP BEAbcCodeBlock (int inline,BEStringListP instructions);
// BECodeBlockP BEAbcCodeBlock (int inlineFlag,BEStringListP instructions);
BEAnyCodeBlock :: !BECodeParameterP !BECodeParameterP !BEStringListP !BackEnd -> (!BECodeBlockP,!BackEnd);
BEAnyCodeBlock a0 a1 a2 a3 = code {
......@@ -736,6 +772,12 @@ BEGenerateCode a0 a1 = code {
}
// int BEGenerateCode (CleanString outputFile);
BEGetError :: {#Char};
BEGetError = code {
ccall BEGetError ":S"
}
// CleanString BEGetError ();
BEExportType :: !Bool !Int !BackEnd -> BackEnd;
BEExportType a0 a1 a2 = code {
ccall BEExportType "II:V:p"
......@@ -783,12 +825,11 @@ BEStrictPositions a0 a1 = code {
ccall BEStrictPositions "I:VIp:p"
}
// void BEStrictPositions (int functionIndex,int* bits,int** positions);
/*
BECopyInts :: !Int !Int !Int -> Int;
BECopyInts a0 a1 a2 = code {
ccall BECopyInts "Ipp:I"
}
*/
// int BECopyInts (int cLength,int* ints,int* cleanArray);
BEGetIntFromArray :: !Int !Int -> Int;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment