summaryrefslogtreecommitdiff
path: root/macros/ASTManagement
diff options
context:
space:
mode:
authornutricato2009-06-04 04:51:29 +0000
committernutricato2009-06-04 04:51:29 +0000
commit79f469725862e0bc1ee1be9b7e2d6cdb12911e76 (patch)
tree0db6989ea1dcb99723f2e5722335d52b2aaaa279 /macros/ASTManagement
parent25f850906710d1da7291f48fa4cb89c4d82ca33b (diff)
downloadscilab2c-79f469725862e0bc1ee1be9b7e2d6cdb12911e76.tar.gz
scilab2c-79f469725862e0bc1ee1be9b7e2d6cdb12911e76.tar.bz2
scilab2c-79f469725862e0bc1ee1be9b7e2d6cdb12911e76.zip
Diffstat (limited to 'macros/ASTManagement')
-rw-r--r--macros/ASTManagement/%for_string.sci (renamed from macros/ASTManagement/for_string.sci)0
-rw-r--r--macros/ASTManagement/AST_HandleEOL.sci20
-rw-r--r--macros/ASTManagement/AST_HandleEndGenFun.sci3
-rw-r--r--macros/ASTManagement/AST_ParseEqualStruct.sci16
-rw-r--r--macros/ASTManagement/AST_ParseFuncallStruct.sci10
5 files changed, 25 insertions, 24 deletions
diff --git a/macros/ASTManagement/for_string.sci b/macros/ASTManagement/%for_string.sci
index 0ed9ca28..0ed9ca28 100644
--- a/macros/ASTManagement/for_string.sci
+++ b/macros/ASTManagement/%for_string.sci
diff --git a/macros/ASTManagement/AST_HandleEOL.sci b/macros/ASTManagement/AST_HandleEOL.sci
index 286bab7b..c258ff94 100644
--- a/macros/ASTManagement/AST_HandleEOL.sci
+++ b/macros/ASTManagement/AST_HandleEOL.sci
@@ -41,22 +41,22 @@ IndentLevel = SharedInfo.NIndent;
PrintStepInfo('Handling EOL',ReportFileName,'file');
sciline = mgetl(SciFileFid,1);
-
+
// #RNU_RES_B
-PrintStringInfo(' ',ReportFileName,'file','y');
-PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y');
-PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y');
-PrintStringInfo('### Scilab code: '+sciline+' ###',ReportFileName,'file','y');
-PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y');
-PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y');
+PrintStringInfo(' ',ReportFileName,'file','y','n');
+PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
+PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
+PrintStringInfo('### Scilab code: '+sciline+' ###',ReportFileName,'file','y','n');
+PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
+PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
// #RNU_RES_E
PrintStringInfo(' ',CPass1FileName,'file','y');
modeprintstringinfo = 'stdout';
if (SharedInfo.CopySciCodeIntoCCode == 1)
modeprintstringinfo = 'both';
end
-PrintStringInfo(C_IndentBlanks(IndentLevel)+'/*SCI2C: #############'+'############'+'##############'+'###############'+'############',CPass1FileName,modeprintstringinfo,'y');
-PrintStringInfo(C_IndentBlanks(IndentLevel)+' SCI2C: '+sciline,CPass1FileName,modeprintstringinfo,'y');
-PrintStringInfo(C_IndentBlanks(IndentLevel)+' SCI2C: #############'+'############'+'##############'+'###############'+'############*/',CPass1FileName,modeprintstringinfo,'y');
+PrintStringInfo(C_IndentBlanks(IndentLevel)+'/*SCI2C: #############'+'############'+'##############'+'###############'+'############',CPass1FileName,modeprintstringinfo,'y','n');
+PrintStringInfo(C_IndentBlanks(IndentLevel)+' SCI2C: '+sciline,CPass1FileName,modeprintstringinfo,'y','n');
+PrintStringInfo(C_IndentBlanks(IndentLevel)+' SCI2C: #############'+'############'+'##############'+'###############'+'############*/',CPass1FileName,modeprintstringinfo,'y','n');
endfunction
diff --git a/macros/ASTManagement/AST_HandleEndGenFun.sci b/macros/ASTManagement/AST_HandleEndGenFun.sci
index 2bc31969..3db11733 100644
--- a/macros/ASTManagement/AST_HandleEndGenFun.sci
+++ b/macros/ASTManagement/AST_HandleEndGenFun.sci
@@ -419,7 +419,8 @@ load(FunInfoDatFileName,'FunInfo');
//#RNU_RES_B
// --- Generate include. ---
//#RNU_RES_E
-if ((Flag_FunAlreadyCalled == 0) & (FunInfo.LibTypeInfo == 'USER2C'))
+if ((Flag_FunAlreadyCalled == 0) & (FunInfo.LibTypeInfo == 'USER2C') & (SharedInfo.NextCFunName ~= CFunName))
+ // (SharedInfo.NextCFunName ~= CFunName) I don't want an include in the same file. Ex. in main.h I don't want include "main.h"
// #RNU_RES_B
PrintStringInfo('Adding include',ReportFileName,'file','y');
PrintStringInfo('#include ""'+CFunName+'.h""',...
diff --git a/macros/ASTManagement/AST_ParseEqualStruct.sci b/macros/ASTManagement/AST_ParseEqualStruct.sci
index 1c86b765..3d917682 100644
--- a/macros/ASTManagement/AST_ParseEqualStruct.sci
+++ b/macros/ASTManagement/AST_ParseEqualStruct.sci
@@ -44,8 +44,8 @@ global StackPosition;
global STACKDEDUG
//#RNU_RES_B
-PrintStringInfo(' ',ReportFileName,'file','y');
-PrintStringInfo('***Reading AST***',ReportFileName,'file','y');
+PrintStringInfo(' ',ReportFileName,'file','y','n');
+PrintStringInfo('***Reading AST***',ReportFileName,'file','y','n');
//#RNU_RES_E
// -------------------------------
@@ -122,8 +122,8 @@ end
// --- Print Some Info. ---
// ------------------------
//#RNU_RES_B
-PrintStringInfo('Function Name: '+FunctionName,ReportFileName,'file','y');
-PrintStringInfo('N Intput Arguments: '+string(NInArg),ReportFileName,'file','y');
+PrintStringInfo('Function Name: '+FunctionName,ReportFileName,'file','y','n');
+PrintStringInfo('N Intput Arguments: '+string(NInArg),ReportFileName,'file','y','n');
//#RNU_RES_E
if (SharedInfo.Equal.Nins > 0)
//#RNU_RES_B
@@ -147,17 +147,17 @@ else
for counterinputargs = 1:NInArg
//#RNU_RES_B
PrintStringInfo('Input Argument Number '+string(counterinputargs)+': '+InArg(counterinputargs).Name,...
- ReportFileName,'file','y');
+ ReportFileName,'file','y','n');
PrintStringInfo(' Scope: '+InArg(counterinputargs).Scope,...
- ReportFileName,'file','y');
+ 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');
+ ReportFileName,'file','y','n');
PrintStringInfo(' Scope: '+OutArg(counterinputargs).Scope,...
- ReportFileName,'file','y');
+ ReportFileName,'file','y','n');
//#RNU_RES_E
end
if (NInArg ~= NOutArg)
diff --git a/macros/ASTManagement/AST_ParseFuncallStruct.sci b/macros/ASTManagement/AST_ParseFuncallStruct.sci
index 54496597..5840c05e 100644
--- a/macros/ASTManagement/AST_ParseFuncallStruct.sci
+++ b/macros/ASTManagement/AST_ParseFuncallStruct.sci
@@ -100,16 +100,16 @@ for counterinputargs = 1:NInArg
end
//#RNU_RES_B
-PrintStringInfo('Function Name: '+FunctionName,ReportFileName,'file','y');
-PrintStringInfo('N Intput Arguments: '+string(NInArg),ReportFileName,'file','y');
-PrintStringInfo('N Output Arguments: '+string(NOutArg),ReportFileName,'file','y');
+PrintStringInfo('Function Name: '+FunctionName,ReportFileName,'file','y','n');
+PrintStringInfo('N Intput Arguments: '+string(NInArg),ReportFileName,'file','y','n');
+PrintStringInfo('N Output Arguments: '+string(NOutArg),ReportFileName,'file','y','n');
//#RNU_RES_E
for counterinputargs = 1:NInArg
//#RNU_RES_B
PrintStringInfo('Input Argument Number '+string(counterinputargs)+': '+InArg(counterinputargs).Name,...
- ReportFileName,'file','y');
+ ReportFileName,'file','y','n');
PrintStringInfo(' Scope: '+InArg(counterinputargs).Scope,...
- ReportFileName,'file','y');
+ ReportFileName,'file','y','n');
//#RNU_RES_E
end