X-Git-Url: http://svarog.pmf.uns.ac.rs/gitweb/?p=mjc2wsl.git;a=blobdiff_plain;f=src-wsl%2Ftransf-min.wsl;h=f1046aa58f408893d250880df167a31b4231aae6;hp=7437909bacdbbce7d88d999f0aa6c3a5515441fb;hb=a8f59160bc7c0f2d5e7b4616fd19ebf27e033924;hpb=8d85f9d4c90a0af22c965d92dae40d5ca82a96a2 diff --git a/src-wsl/transf-min.wsl b/src-wsl/transf-min.wsl index 7437909..f1046aa 100755 --- a/src-wsl/transf-min.wsl +++ b/src-wsl/transf-min.wsl @@ -18,6 +18,9 @@ License along with this program. If not, see . =========================================================="; +C:"set the following so that Action Systems are not automaticaly treated as regular"; +Assume_A_S_Regular := 0; + C:"Automatic transformation tool for simplification of WSL"; C:"code automaticaly translated from assembly using asm2wsl."; C:"a simple version"; @@ -26,7 +29,7 @@ MW_PROC @Process_Prog() == FOREACH Statement DO IF @ST(@I) = T_A_S THEN C:"don't need to test for this, works for T_A_S"; - @Trans(TR_Simplify_Action_System, ""); + @Trans(TR_Simplify_Action_System, ""); IF @Trans?(TR_Collapse_Action_System) THEN @Trans(TR_Collapse_Action_System, ""); FI; @@ -42,6 +45,13 @@ MW_PROC @Process_Prog() == @Delete FI OD; + + FOREACH Statement DO + IF @Trans?(TR_Simplify_Item) THEN + @Trans(TR_Simplify_Item,"") + FI + OD; + C:"Convert DO loops into WHILE loops"; FOREACH Statement DO IF @Trans?(TR_Floop_To_While) THEN @@ -78,7 +88,7 @@ IF @File_Exists?(inifilename) THEN OD; @Close_Input_Port(inifile); ELSE - PRINT("ini file (",inifile,") not found.", + PRINT("ini file (",inifilename,") not found.", " it should contain a list of filenames to be converted"); PRINT("you can input a filename now:"); filename := @Read_Line(Standard_Input_Port);