summaryrefslogtreecommitdiff
path: root/2.3-1/macros/ASTManagement
diff options
context:
space:
mode:
authorukashanoor2017-06-21 11:54:14 +0530
committerukashanoor2017-06-21 11:54:14 +0530
commitf25acc874a1b46a46e9f026b0f110f2df63015f8 (patch)
treef2640d9f0c8616f8cb49af322d1c6af0d873b709 /2.3-1/macros/ASTManagement
parent5975188ba7090de2d9f646102ab006e1127fd6f8 (diff)
downloadScilab2C-f25acc874a1b46a46e9f026b0f110f2df63015f8.tar.gz
Scilab2C-f25acc874a1b46a46e9f026b0f110f2df63015f8.tar.bz2
Scilab2C-f25acc874a1b46a46e9f026b0f110f2df63015f8.zip
inter commit
Diffstat (limited to '2.3-1/macros/ASTManagement')
-rw-r--r--2.3-1/macros/ASTManagement/%comment_string.binbin780 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%cste_string.binbin3484 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%equal_string.binbin2152 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%equal_string.sci2
-rw-r--r--2.3-1/macros/ASTManagement/%for_string.binbin2124 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%funcall_string.binbin1748 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%ifthenel_string.binbin3784 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%ifthenelse_string.binbin3784 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%operatio_string.binbin1352 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%operatio_string.sci9
-rw-r--r--2.3-1/macros/ASTManagement/%operation_string.binbin1352 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%program_p.binbin520 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%program_string.binbin3276 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%variable_string.binbin3648 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/%while_string.binbin1972 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST2Ccode.binbin32736 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST2Ccode.sci60
-rw-r--r--2.3-1/macros/ASTManagement/AST_CheckCommonInOutArgs.binbin16824 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_CheckLastFunc.binbin9164 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_CheckLineLength.binbin3296 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_CheckPrecSpecifier.binbin10864 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_DisplayStack.binbin4704 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ExtractNameAndScope.binbin13184 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_GetASTFile.binbin7216 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_GetFuncallPrm.binbin6872 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_GetPrecAndLhsArg.binbin12552 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleEOL.binbin11704 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleEndFor.binbin10452 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleEndGenFun.binbin100596 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleEndProgram.binbin7968 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleEndWhile.binbin8984 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleFor.binbin12920 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleForStatem.binbin11348 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleFunRC.sci165
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleHeader.binbin39132 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleIfElse.binbin12056 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleRC.sci81
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleWhileExpr.binbin12140 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleWhileStatem.binbin15548 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ParseEqualStruct.binbin20312 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ParseEqualStruct.sci2
-rw-r--r--2.3-1/macros/ASTManagement/AST_ParseFuncallStruct.binbin15024 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ParseIfExprStruct.binbin16644 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ParseOperStruct.binbin16668 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_PopASTStack.binbin3896 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_PushASTStack.binbin3300 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ReadASTHeader.binbin11288 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/AST_ReadEqualRhsNames.binbin6972 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/GenOutArgNames.binbin17208 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/Operator2FunName.binbin18584 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/SciFile2ASTFile.binbin4192 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_comment_string.binbin780 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_cste_string.binbin3484 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_equal_string.binbin2152 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_for_string.binbin2124 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_funcall_string.binbin1748 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_ifthenel_string.binbin3784 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_ifthenelse_string.binbin3784 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_operatio_string.binbin1352 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_operation_string.binbin1352 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_program_p.binbin520 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_program_string.binbin3276 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_variable_string.binbin3648 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/_while_string.binbin1972 -> 0 bytes
-rw-r--r--2.3-1/macros/ASTManagement/libbin1768 -> 1816 bytes
-rw-r--r--2.3-1/macros/ASTManagement/names4
-rw-r--r--2.3-1/macros/ASTManagement/objectlist2string.binbin1384 -> 0 bytes
67 files changed, 302 insertions, 21 deletions
diff --git a/2.3-1/macros/ASTManagement/%comment_string.bin b/2.3-1/macros/ASTManagement/%comment_string.bin
deleted file mode 100644
index fb894945..00000000
--- a/2.3-1/macros/ASTManagement/%comment_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%cste_string.bin b/2.3-1/macros/ASTManagement/%cste_string.bin
deleted file mode 100644
index ba643c47..00000000
--- a/2.3-1/macros/ASTManagement/%cste_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%equal_string.bin b/2.3-1/macros/ASTManagement/%equal_string.bin
deleted file mode 100644
index 7f88fee6..00000000
--- a/2.3-1/macros/ASTManagement/%equal_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%equal_string.sci b/2.3-1/macros/ASTManagement/%equal_string.sci
index 9678f0e0..041fb84a 100644
--- a/2.3-1/macros/ASTManagement/%equal_string.sci
+++ b/2.3-1/macros/ASTManagement/%equal_string.sci
@@ -13,4 +13,4 @@ function txt=%equal_string(e)
' '+objectlist2string(e.lhs)
'EndEqual'
]
-endfunction \ No newline at end of file
+endfunction
diff --git a/2.3-1/macros/ASTManagement/%for_string.bin b/2.3-1/macros/ASTManagement/%for_string.bin
deleted file mode 100644
index c3fda16b..00000000
--- a/2.3-1/macros/ASTManagement/%for_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%funcall_string.bin b/2.3-1/macros/ASTManagement/%funcall_string.bin
deleted file mode 100644
index 8354586d..00000000
--- a/2.3-1/macros/ASTManagement/%funcall_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%ifthenel_string.bin b/2.3-1/macros/ASTManagement/%ifthenel_string.bin
deleted file mode 100644
index 1c6fa73d..00000000
--- a/2.3-1/macros/ASTManagement/%ifthenel_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%ifthenelse_string.bin b/2.3-1/macros/ASTManagement/%ifthenelse_string.bin
deleted file mode 100644
index 456ffadc..00000000
--- a/2.3-1/macros/ASTManagement/%ifthenelse_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%operatio_string.bin b/2.3-1/macros/ASTManagement/%operatio_string.bin
deleted file mode 100644
index 40abf6b2..00000000
--- a/2.3-1/macros/ASTManagement/%operatio_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%operatio_string.sci b/2.3-1/macros/ASTManagement/%operatio_string.sci
index 8421a3f4..c0ecb478 100644
--- a/2.3-1/macros/ASTManagement/%operatio_string.sci
+++ b/2.3-1/macros/ASTManagement/%operatio_string.sci
@@ -4,10 +4,17 @@ function txt=%operatio_string(O)
//fields:
// operands: a list
// operator: a string
+if O.operator <> 'rc'
txt=['Operation'
' Operands:'
' '+objectlist2string(O.operands)
' Operator: '+O.operator
'EndOperation'
]
-endfunction \ No newline at end of file
+else
+ txt=[' Operands:'
+ ' '+objectlist2string(O.operands)
+ 'Endrc'
+ ]
+end
+endfunction
diff --git a/2.3-1/macros/ASTManagement/%operation_string.bin b/2.3-1/macros/ASTManagement/%operation_string.bin
deleted file mode 100644
index dfbeec96..00000000
--- a/2.3-1/macros/ASTManagement/%operation_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%program_p.bin b/2.3-1/macros/ASTManagement/%program_p.bin
deleted file mode 100644
index 216a38b2..00000000
--- a/2.3-1/macros/ASTManagement/%program_p.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%program_string.bin b/2.3-1/macros/ASTManagement/%program_string.bin
deleted file mode 100644
index 3a8fc95b..00000000
--- a/2.3-1/macros/ASTManagement/%program_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%variable_string.bin b/2.3-1/macros/ASTManagement/%variable_string.bin
deleted file mode 100644
index f81fd6e0..00000000
--- a/2.3-1/macros/ASTManagement/%variable_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/%while_string.bin b/2.3-1/macros/ASTManagement/%while_string.bin
deleted file mode 100644
index 142189c6..00000000
--- a/2.3-1/macros/ASTManagement/%while_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST2Ccode.bin b/2.3-1/macros/ASTManagement/AST2Ccode.bin
deleted file mode 100644
index 9daefb83..00000000
--- a/2.3-1/macros/ASTManagement/AST2Ccode.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST2Ccode.sci b/2.3-1/macros/ASTManagement/AST2Ccode.sci
index 73183f79..19cf00c4 100644
--- a/2.3-1/macros/ASTManagement/AST2Ccode.sci
+++ b/2.3-1/macros/ASTManagement/AST2Ccode.sci
@@ -46,6 +46,9 @@ ReportFileName = FileInfo.Funct(nxtscifunnumber).ReportFileName;
// ---------------------------------
// --- Parameter Initialization. ---
// ---------------------------------
+global rc_count
+rc_count = 0;
+
global SCI2CSTACK
SCI2CSTACK = ['EMPTYSTACK'];
@@ -144,29 +147,45 @@ while ~meof(fidAST)
//NUT: per fare in modo di coprire le ins, anche se ci puo' essere qualche rischio quando
//NUT: ho miste ins e variabili, per esempio [c(1,1), a] = twooutfun();
//NUT: in questo caso solo una delle due equal va scartata.
- [FileInfo,SharedInfo] = AST_HandleEndGenFun(FileInfo,SharedInfo,'Equal');
- SharedInfo = INIT_SharedInfoEqual(SharedInfo);
+ if rc_count > 0
+ [FileInfo,SharedInfo] = AST_HandleFunRC(FileInfo,SharedInfo);
+ else
+ [FileInfo,SharedInfo] = AST_HandleEndGenFun(FileInfo,SharedInfo,'Equal');
+ SharedInfo = INIT_SharedInfoEqual(SharedInfo);
+ end
case 'Equal' then
SharedInfo.Equal.Enabled = 1; // 1 means enabled -> we are inside an equal AST block.
AST_PushASTStack(treeline);
case 'Lhs :' then
- SharedInfo.Equal.Lhs = 1; // 1 means that we are inside the Lhs block of the Equal
- //if SharedInfo.Equal.NOutArg > 0
- [EqualInArgName,EqualInArgScope,EqualNInArg] = AST_ReadEqualRhsNames(FileInfo,SharedInfo);
- SharedInfo.Equal.NInArg = EqualNInArg;
- //end
+ disp(rc_count);
+ if rc_count > 0
+ SharedInfo.Equal.Lhs = 1;
+ [EqualInArgName,EqualInArgScope,EqualNInArg] = AST_HandleRC(FileInfo,SharedInfo);
+ SharedInfo.Equal.NInArg = EqualNInArg;
+ AST_PushASTStack(treeline);
+ for tmpcnt = 1:SharedInfo.Equal.NInArg
+ SharedInfo.Equal.InArg(tmpcnt).Name = EqualInArgName(tmpcnt);
+ SharedInfo.Equal.InArg(tmpcnt).Scope = EqualInArgScope(tmpcnt);
+ end
+ else
+ SharedInfo.Equal.Lhs = 1; // 1 means that we are inside the Lhs block of the Equal
+ //if SharedInfo.Equal.NOutArg > 0
+ [EqualInArgName,EqualInArgScope,EqualNInArg] = AST_ReadEqualRhsNames(FileInfo,SharedInfo);
+ SharedInfo.Equal.NInArg = EqualNInArg;
+ //end
- // lengthNumber = length('Number_');
- // if (part(EqualInArgScope,1:lengthNumber) == 'Number_')
- // SharedInfo.SkipNextEqual = 1
- // end
-
- for tmpcnt = 1:SharedInfo.Equal.NInArg
- SharedInfo.Equal.InArg(tmpcnt).Name = EqualInArgName(tmpcnt);
- SharedInfo.Equal.InArg(tmpcnt).Scope = EqualInArgScope(tmpcnt);
- end
- //end
- AST_PushASTStack(treeline);
+ // lengthNumber = length('Number_');
+ // if (part(EqualInArgScope,1:lengthNumber) == 'Number_')
+ // SharedInfo.SkipNextEqual = 1
+ // end
+
+ for tmpcnt = 1:SharedInfo.Equal.NInArg
+ SharedInfo.Equal.InArg(tmpcnt).Name = EqualInArgName(tmpcnt);
+ SharedInfo.Equal.InArg(tmpcnt).Scope = EqualInArgScope(tmpcnt);
+ end
+ //end
+ AST_PushASTStack(treeline);
+ end
// ----------------
// --- If/Else. ---
@@ -233,6 +252,11 @@ while ~meof(fidAST)
SharedInfo = AST_HandleEndWhile(FileInfo,SharedInfo);
SharedInfo.While.Level = SharedInfo.While.Level - 1;
+
+ case 'Endrc' then
+ rc_count = rc_count + 1;
+ //[FileInfo,SharedInfo] = AST_HandleRC(FileInfo,SharedInfo);
+
// ----------------
// --- Default. ---
// ----------------
diff --git a/2.3-1/macros/ASTManagement/AST_CheckCommonInOutArgs.bin b/2.3-1/macros/ASTManagement/AST_CheckCommonInOutArgs.bin
deleted file mode 100644
index 5c190ba3..00000000
--- a/2.3-1/macros/ASTManagement/AST_CheckCommonInOutArgs.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_CheckLastFunc.bin b/2.3-1/macros/ASTManagement/AST_CheckLastFunc.bin
deleted file mode 100644
index 9cac2273..00000000
--- a/2.3-1/macros/ASTManagement/AST_CheckLastFunc.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_CheckLineLength.bin b/2.3-1/macros/ASTManagement/AST_CheckLineLength.bin
deleted file mode 100644
index db486797..00000000
--- a/2.3-1/macros/ASTManagement/AST_CheckLineLength.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_CheckPrecSpecifier.bin b/2.3-1/macros/ASTManagement/AST_CheckPrecSpecifier.bin
deleted file mode 100644
index 8e50397f..00000000
--- a/2.3-1/macros/ASTManagement/AST_CheckPrecSpecifier.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_DisplayStack.bin b/2.3-1/macros/ASTManagement/AST_DisplayStack.bin
deleted file mode 100644
index 90cbcc74..00000000
--- a/2.3-1/macros/ASTManagement/AST_DisplayStack.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ExtractNameAndScope.bin b/2.3-1/macros/ASTManagement/AST_ExtractNameAndScope.bin
deleted file mode 100644
index 1944d88b..00000000
--- a/2.3-1/macros/ASTManagement/AST_ExtractNameAndScope.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_GetASTFile.bin b/2.3-1/macros/ASTManagement/AST_GetASTFile.bin
deleted file mode 100644
index 261430e5..00000000
--- a/2.3-1/macros/ASTManagement/AST_GetASTFile.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_GetFuncallPrm.bin b/2.3-1/macros/ASTManagement/AST_GetFuncallPrm.bin
deleted file mode 100644
index 37dbe771..00000000
--- a/2.3-1/macros/ASTManagement/AST_GetFuncallPrm.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_GetPrecAndLhsArg.bin b/2.3-1/macros/ASTManagement/AST_GetPrecAndLhsArg.bin
deleted file mode 100644
index 71e44cb1..00000000
--- a/2.3-1/macros/ASTManagement/AST_GetPrecAndLhsArg.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleEOL.bin b/2.3-1/macros/ASTManagement/AST_HandleEOL.bin
deleted file mode 100644
index 3b6b3bd1..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleEOL.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleEndFor.bin b/2.3-1/macros/ASTManagement/AST_HandleEndFor.bin
deleted file mode 100644
index a6031b43..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleEndFor.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleEndGenFun.bin b/2.3-1/macros/ASTManagement/AST_HandleEndGenFun.bin
deleted file mode 100644
index 6aab0b75..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleEndGenFun.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleEndProgram.bin b/2.3-1/macros/ASTManagement/AST_HandleEndProgram.bin
deleted file mode 100644
index 5e02fdcd..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleEndProgram.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleEndWhile.bin b/2.3-1/macros/ASTManagement/AST_HandleEndWhile.bin
deleted file mode 100644
index bafccbc2..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleEndWhile.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleFor.bin b/2.3-1/macros/ASTManagement/AST_HandleFor.bin
deleted file mode 100644
index 27d44a12..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleFor.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleForStatem.bin b/2.3-1/macros/ASTManagement/AST_HandleForStatem.bin
deleted file mode 100644
index 4839b049..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleForStatem.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleFunRC.sci b/2.3-1/macros/ASTManagement/AST_HandleFunRC.sci
new file mode 100644
index 00000000..a70155a7
--- /dev/null
+++ b/2.3-1/macros/ASTManagement/AST_HandleFunRC.sci
@@ -0,0 +1,165 @@
+function [FileInfo,SharedInfo] = AST_HandleEndGenFun(FileInfo,SharedInfo)
+// function [FileInfo,SharedInfo] = AST_HandleEndGenFun(FileInfo,SharedInfo,ASTFunType)
+// -----------------------------------------------------------------
+// #RNU_RES_B
+// Handles the EndFuncall, EndOperation and EndEqual tags of the AST.
+// ASTFunType can be 'Funcall', 'Operation', 'Equal'
+// Structure of Funcall:
+// overloading function for "funcall" type tlist string function
+// this is a node of the AST
+// fields:
+// rhs : a list
+// name : string, the name of the function
+// lhsnb: number, the number of function lhs
+// txt=['Funcall : '+F.name
+// ' #lhs : '+string(F.lhsnb)
+// ' Rhs : '
+// ' '+objectlist2string(F.rhs)
+// 'EndFuncall'
+// ]
+// #RNU_RES_E
+//
+// Input data:
+// //NUT: add description here
+//
+// Output data:
+// //NUT: add description here
+//
+// Status:
+// 11-Apr-2007 -- Raffaele Nutricato: Author.
+//
+// Copyright 2007 Raffaele Nutricato.
+// Contact: raffaele.nutricato@tiscali.it
+// -----------------------------------------------------------------
+
+// ------------------------------
+// --- Check input arguments. ---
+// ------------------------------
+
+// -----------------------
+// --- Initialization. ---
+// -----------------------
+nxtscifunname = SharedInfo.NextSCIFunName;
+nxtscifunnumber = SharedInfo.NextSCIFunNumber;
+ReportFileName = FileInfo.Funct(nxtscifunnumber).ReportFileName;
+
+global SCI2CSTACK
+global StackPosition;
+global STACKDEDUG
+// ---------------------------
+// --- End Initialization. ---
+// ---------------------------
+
+// ------------------------------
+// --- Read output parameters. --
+// ------------------------------
+LhsField = AST_PopASTStack();
+NOutArg = 0;
+OutputArgumentNames = [];
+OutputArgumentScope = [];
+while (LhsField ~= 'Lhs :')
+ NOutArg = NOutArg + 1;
+ [OutputArgumentNames(NOutArg),OutputArgumentScope(NOutArg)] = AST_ExtractNameAndScope(LhsField);
+ LhsField = AST_PopASTStack();
+ if (LhsField == 'Expression:')
+ error(9999, 'Found Expression: before Lhs');
+ elseif (LhsField == 'Equal')
+ error(9999, 'Found Equal before Lhs');
+ end
+end
+
+// ------------------------------
+// --- Read input parameters. ---
+// ------------------------------
+
+
+RhsField = AST_PopASTStack();
+NInArg = 0;
+InArg = [];
+while (RhsField ~= 'Expression:')
+ NInArg = NInArg + 1;
+ InArg(NInArg) = RhsField;
+ RhsField = AST_PopASTStack();
+end
+InputArgumentNames = SCI2Cflipud(InputArgumentNames);
+InputArgumentScope = SCI2Cflipud(InputArgumentScope);
+
+
+// -------------------------------------
+// --- Generate the InArg structure. ---
+// -------------------------------------
+//#RNU_RES_E
+InArg = [];
+for counterinputargs = 1:NInArg
+ InArg(counterinputargs).Name=InputArgumentNames(counterinputargs);
+ InArg(counterinputargs).Scope=InputArgumentScope(counterinputargs);
+end
+
+//#RNU_RES_B
+// -------------------------------------
+// --- Generate the InArg structure. ---
+// -------------------------------------
+//#RNU_RES_E
+OutArg = [];
+for counteroutputargs = 1:NOutArg
+ OutArg(counteroutputargs).Name=OutputArgumentNames(counteroutputargs);
+ OutArg(counteroutputargs).Scope=OutputArgumentScope(counteroutputargs);
+end
+
+// ------------------------
+// --- Print Some Info. ---
+// ------------------------
+
+PrintStringInfo('N Input Arguments: '+string(NInArg),ReportFileName,'file','y','n');
+PrintStringInfo('N Output Arguments: '+string(NOutArg),ReportFileName,'file','y');
+ //#RNU_RES_E
+ for counterinputargs = 1:NInArg
+ //#RNU_RES_B
+ PrintStringInfo('Input Argument Number '+string(counterinputargs)+': '+InArg(counterinputargs).Name,...
+ ReportFileName,'file','y','n');
+ PrintStringInfo(' Scope: '+InArg(counterinputargs).Scope,...
+ ReportFileName,'file','y','n');
+ //#RNU_RES_E
+ end
+ for counteroutputargs = 1:NOutArg
+ //#RNU_RES_B
+ PrintStringInfo('Output Argument Number '+string(counteroutputargs)+': '+OutArg(counteroutputargs).Name,...
+ ReportFileName,'file','y','n');
+ PrintStringInfo(' Scope: '+OutArg(counterinputargs).Scope,...
+ ReportFileName,'file','y','n');
+ //#RNU_RES_E
+ end
+
+NOutArg_mod = NOutArg;
+
+FunTypeAnnot = '';
+FunSizeAnnot = '';
+NLhsArg = 0;
+LhsArg = [];
+PrintStringInfo('...Equal not found.',ReportFileName,'file','y');
+
+PrintStringInfo('***Analyzing Input Arguments***',ReportFileName,'file','y');
+UpdatedInArg = InArg;
+[InArg,SharedInfo] = ST_GetInArgInfo(InArg,NInArg,FileInfo,SharedInfo,'OpEqual');
+
+size_count = 0;
+for i = 1:NInArg
+ size_count = size_count + InArg(i).Size(2);
+end
+
+PrintStringInfo(' Generating Out Arg names.',ReportFileName,'file','y');
+OutArg(1).Type = InArg(1).Type;
+OutArg(1).Size(1) = '1'
+OutArg(1).Size(2) = string(size_count);
+OutArg(1).Dimension = InArg(1).Dimension;
+OutArg(1).Value = InArg(1).Value;
+OutArg(1).FindLike = InArg(1).FindLike;
+
+//--- Check for output Argument in symbol table ---//
+OutArg = ST_AnalyzeScope(OutArg,NOutArg,FileInfo,SharedInfo);
+
+//--- Put the output Argument in symbol table ---//
+ST_InsOutArg(OutArg,NOutArg,FileInfo,SharedInfo,'all');
+
+
+endfunction
diff --git a/2.3-1/macros/ASTManagement/AST_HandleHeader.bin b/2.3-1/macros/ASTManagement/AST_HandleHeader.bin
deleted file mode 100644
index 87ef763a..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleHeader.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleIfElse.bin b/2.3-1/macros/ASTManagement/AST_HandleIfElse.bin
deleted file mode 100644
index d30e47b4..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleIfElse.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleRC.sci b/2.3-1/macros/ASTManagement/AST_HandleRC.sci
new file mode 100644
index 00000000..b1a1003f
--- /dev/null
+++ b/2.3-1/macros/ASTManagement/AST_HandleRC.sci
@@ -0,0 +1,81 @@
+function [RhsNames,RhsScope,NRhs] = AST_ReadEqualRhsNames(FileInfo,SharedInfo)
+// function [FileInfo,SharedInfo] = AST_HandleEndGenFun(FileInfo,SharedInfo,ASTFunType)
+// -----------------------------------------------------------------
+// #RNU_RES_B
+// Handles the EndFuncall, EndOperation and EndEqual tags of the AST.
+// ASTFunType can be 'Funcall', 'Operation', 'Equal'
+// Structure of Funcall:
+// overloading function for "funcall" type tlist string function
+// this is a node of the AST
+// fields:
+// rhs : a list
+// name : string, the name of the function
+// lhsnb: number, the number of function lhs
+// txt=['Funcall : '+F.name
+// ' #lhs : '+string(F.lhsnb)
+// ' Rhs : '
+// ' '+objectlist2string(F.rhs)
+// 'EndFuncall'
+// ]
+// #RNU_RES_E
+//
+// Input data:
+// //NUT: add description here
+//
+// Output data:
+// //NUT: add description here
+//
+// Status:
+// 11-Apr-2007 -- Raffaele Nutricato: Author.
+//
+// Copyright 2007 Raffaele Nutricato.
+// Contact: raffaele.nutricato@tiscali.it
+// -----------------------------------------------------------------
+
+ReportFileName = FileInfo.Funct(nxtscifunnumber).ReportFileName;
+
+// ------------------------------
+// --- Check input arguments. ---
+// ------------------------------
+
+
+global SCI2CSTACK
+global StackPosition;
+global STACKDEDUG
+// ---------------------------
+// --- End Initialization. ---
+// ---------------------------
+
+
+// ------------------------------
+// --- Read input parameters. ---
+// ------------------------------
+cntpop = 1;
+NRhs = 0;
+RhsField(cntpop) = AST_PopASTStack();
+RhsNames = [];
+while (RhsField(cntpop) ~= 'Operands:')
+ NRhs = NRhs + 1;
+ [RhsNames(NRhs),RhsScope(NRhs)] = AST_ExtractNameAndScope(RhsField(cntpop));
+ cntpop = cntpop + 1;
+ RhsField(cntpop) = AST_PopASTStack();
+end
+RhsNames = SCI2Cflipud(RhsNames);
+RhsScope = SCI2Cflipud(RhsScope);
+
+// --- Repush everything into the stack. ---
+for cntpush = cntpop:-1:1
+ AST_PushASTStack(RhsField(cntpush));
+end
+
+
+for counterinputargs = 1:NRhs
+ //#RNU_RES_B
+ PrintStringInfo('Input Argument Number '+string(counterinputargs)+': '+InArg(counterinputargs).Name,...
+ ReportFileName,'file','y');
+ PrintStringInfo(' Scope: '+InArg(counterinputargs).Scope,...
+ ReportFileName,'file','y');
+ //#RNU_RES_E
+end
+
+endfunction
diff --git a/2.3-1/macros/ASTManagement/AST_HandleWhileExpr.bin b/2.3-1/macros/ASTManagement/AST_HandleWhileExpr.bin
deleted file mode 100644
index 5f3da2de..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleWhileExpr.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_HandleWhileStatem.bin b/2.3-1/macros/ASTManagement/AST_HandleWhileStatem.bin
deleted file mode 100644
index 4f7704ea..00000000
--- a/2.3-1/macros/ASTManagement/AST_HandleWhileStatem.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.bin b/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.bin
deleted file mode 100644
index 459c62e8..00000000
--- a/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.sci b/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.sci
index fa76a01d..68bc3da7 100644
--- a/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.sci
+++ b/2.3-1/macros/ASTManagement/AST_ParseEqualStruct.sci
@@ -123,7 +123,7 @@ end
// ------------------------
//#RNU_RES_B
PrintStringInfo('Function Name: '+FunctionName,ReportFileName,'file','y','n');
-PrintStringInfo('N Intput Arguments: '+string(NInArg),ReportFileName,'file','y','n');
+PrintStringInfo('N Input Arguments: '+string(NInArg),ReportFileName,'file','y','n');
//#RNU_RES_E
if (SharedInfo.Equal.Nins > 0)
//#RNU_RES_B
diff --git a/2.3-1/macros/ASTManagement/AST_ParseFuncallStruct.bin b/2.3-1/macros/ASTManagement/AST_ParseFuncallStruct.bin
deleted file mode 100644
index 1cbeb5c0..00000000
--- a/2.3-1/macros/ASTManagement/AST_ParseFuncallStruct.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ParseIfExprStruct.bin b/2.3-1/macros/ASTManagement/AST_ParseIfExprStruct.bin
deleted file mode 100644
index 19ea5fe9..00000000
--- a/2.3-1/macros/ASTManagement/AST_ParseIfExprStruct.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ParseOperStruct.bin b/2.3-1/macros/ASTManagement/AST_ParseOperStruct.bin
deleted file mode 100644
index e189cbc9..00000000
--- a/2.3-1/macros/ASTManagement/AST_ParseOperStruct.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_PopASTStack.bin b/2.3-1/macros/ASTManagement/AST_PopASTStack.bin
deleted file mode 100644
index f9b85d34..00000000
--- a/2.3-1/macros/ASTManagement/AST_PopASTStack.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_PushASTStack.bin b/2.3-1/macros/ASTManagement/AST_PushASTStack.bin
deleted file mode 100644
index 8fcd563c..00000000
--- a/2.3-1/macros/ASTManagement/AST_PushASTStack.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ReadASTHeader.bin b/2.3-1/macros/ASTManagement/AST_ReadASTHeader.bin
deleted file mode 100644
index 614231c4..00000000
--- a/2.3-1/macros/ASTManagement/AST_ReadASTHeader.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/AST_ReadEqualRhsNames.bin b/2.3-1/macros/ASTManagement/AST_ReadEqualRhsNames.bin
deleted file mode 100644
index a131c498..00000000
--- a/2.3-1/macros/ASTManagement/AST_ReadEqualRhsNames.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/GenOutArgNames.bin b/2.3-1/macros/ASTManagement/GenOutArgNames.bin
deleted file mode 100644
index 2ebce86c..00000000
--- a/2.3-1/macros/ASTManagement/GenOutArgNames.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/Operator2FunName.bin b/2.3-1/macros/ASTManagement/Operator2FunName.bin
deleted file mode 100644
index 884c99bc..00000000
--- a/2.3-1/macros/ASTManagement/Operator2FunName.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/SciFile2ASTFile.bin b/2.3-1/macros/ASTManagement/SciFile2ASTFile.bin
deleted file mode 100644
index be8bc0d5..00000000
--- a/2.3-1/macros/ASTManagement/SciFile2ASTFile.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_comment_string.bin b/2.3-1/macros/ASTManagement/_comment_string.bin
deleted file mode 100644
index fb894945..00000000
--- a/2.3-1/macros/ASTManagement/_comment_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_cste_string.bin b/2.3-1/macros/ASTManagement/_cste_string.bin
deleted file mode 100644
index ba643c47..00000000
--- a/2.3-1/macros/ASTManagement/_cste_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_equal_string.bin b/2.3-1/macros/ASTManagement/_equal_string.bin
deleted file mode 100644
index 7f88fee6..00000000
--- a/2.3-1/macros/ASTManagement/_equal_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_for_string.bin b/2.3-1/macros/ASTManagement/_for_string.bin
deleted file mode 100644
index c3fda16b..00000000
--- a/2.3-1/macros/ASTManagement/_for_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_funcall_string.bin b/2.3-1/macros/ASTManagement/_funcall_string.bin
deleted file mode 100644
index 8354586d..00000000
--- a/2.3-1/macros/ASTManagement/_funcall_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_ifthenel_string.bin b/2.3-1/macros/ASTManagement/_ifthenel_string.bin
deleted file mode 100644
index 1c6fa73d..00000000
--- a/2.3-1/macros/ASTManagement/_ifthenel_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_ifthenelse_string.bin b/2.3-1/macros/ASTManagement/_ifthenelse_string.bin
deleted file mode 100644
index 456ffadc..00000000
--- a/2.3-1/macros/ASTManagement/_ifthenelse_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_operatio_string.bin b/2.3-1/macros/ASTManagement/_operatio_string.bin
deleted file mode 100644
index 40abf6b2..00000000
--- a/2.3-1/macros/ASTManagement/_operatio_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_operation_string.bin b/2.3-1/macros/ASTManagement/_operation_string.bin
deleted file mode 100644
index dfbeec96..00000000
--- a/2.3-1/macros/ASTManagement/_operation_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_program_p.bin b/2.3-1/macros/ASTManagement/_program_p.bin
deleted file mode 100644
index 216a38b2..00000000
--- a/2.3-1/macros/ASTManagement/_program_p.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_program_string.bin b/2.3-1/macros/ASTManagement/_program_string.bin
deleted file mode 100644
index 3a8fc95b..00000000
--- a/2.3-1/macros/ASTManagement/_program_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_variable_string.bin b/2.3-1/macros/ASTManagement/_variable_string.bin
deleted file mode 100644
index f81fd6e0..00000000
--- a/2.3-1/macros/ASTManagement/_variable_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/_while_string.bin b/2.3-1/macros/ASTManagement/_while_string.bin
deleted file mode 100644
index 142189c6..00000000
--- a/2.3-1/macros/ASTManagement/_while_string.bin
+++ /dev/null
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/lib b/2.3-1/macros/ASTManagement/lib
index 42ffc2a7..c73eb6b2 100644
--- a/2.3-1/macros/ASTManagement/lib
+++ b/2.3-1/macros/ASTManagement/lib
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/names b/2.3-1/macros/ASTManagement/names
index a1aafbc1..26edaf7c 100644
--- a/2.3-1/macros/ASTManagement/names
+++ b/2.3-1/macros/ASTManagement/names
@@ -28,8 +28,10 @@ AST_HandleEndProgram
AST_HandleEndWhile
AST_HandleFor
AST_HandleForStatem
+AST_HandleFunRC
AST_HandleHeader
AST_HandleIfElse
+AST_HandleRC
AST_HandleWhileExpr
AST_HandleWhileStatem
AST_ParseEqualStruct
@@ -57,3 +59,5 @@ _program_string
_variable_string
_while_string
objectlist2string
+AST_HandleRC
+AST_HandleFunRC
diff --git a/2.3-1/macros/ASTManagement/objectlist2string.bin b/2.3-1/macros/ASTManagement/objectlist2string.bin
deleted file mode 100644
index 96159f22..00000000
--- a/2.3-1/macros/ASTManagement/objectlist2string.bin
+++ /dev/null
Binary files differ