1.1 --- a/test/Tools/isac/Frontend/interface.sml Tue Sep 28 08:58:06 2010 +0200
1.2 +++ b/test/Tools/isac/Frontend/interface.sml Tue Sep 28 09:06:56 2010 +0200
1.3 @@ -60,10 +60,10 @@
1.4 "--------- encode ^ -> ^^^ ---------------------------------------";
1.5 "--------- encode ^ -> ^^^ ---------------------------------------";
1.6 if encode "a^2+b^2=c^2" = "a^^^2+b^^^2=c^^^2" then ()
1.7 -else raise error "interface.sml: diff.behav. in encode ^ -> ^^^ ";
1.8 +else error "interface.sml: diff.behav. in encode ^ -> ^^^ ";
1.9
1.10 if (decode o encode) "a^2+b^2=c^2" = "a^2+b^2=c^2" then ()
1.11 -else raise error "interface.sml: diff.behav. in de/encode ^ <-> ^^^ ";
1.12 +else error "interface.sml: diff.behav. in de/encode ^ <-> ^^^ ";
1.13
1.14 ==================================================================*)
1.15 "exported from struct --------------------------------------------";
1.16 @@ -167,7 +167,7 @@
1.17 val (Form f, tac, asms) = pt_extract (pt, ip);
1.18 (*exception just above means: 'ModSpec' has been returned: error anyway*)
1.19 if term2str f = "[x = 1]" then () else
1.20 - raise error "FE-Kernel-interface.sml: diff.behav. in solve_linear as rootpbl";
1.21 + error "FE-Kernel-interface.sml: diff.behav. in solve_linear as rootpbl";
1.22
1.23
1.24
1.25 @@ -188,10 +188,10 @@
1.26 moveActiveDown 1;
1.27 moveActiveDown 1;
1.28 if get_pos 1 1 = ([2], Res) then () else
1.29 - raise error "FE-interface.sml: diff.behav. in a inspect 1 with Iterator 2";
1.30 + error "FE-interface.sml: diff.behav. in a inspect 1 with Iterator 2";
1.31 moveActiveDown 1; refFormula 1 ([], Res);
1.32 if get_pos 1 1 = ([], Res) then () else
1.33 - raise error "FE-interface.sml: diff.behav. in b inspect 1 with Iterator 2";
1.34 + error "FE-interface.sml: diff.behav. in b inspect 1 with Iterator 2";
1.35 moveActiveCalcHead 1; refFormula 1 ([],Pbl);
1.36
1.37
1.38 @@ -317,7 +317,7 @@
1.39 val (Form f, tac, asms) = pt_extract (pt, ip);
1.40 (*exception just above means: 'ModSpec' has been returned: error anyway*)
1.41 if term2str f = "[x = 1]" then () else
1.42 - raise error "FE-interface.sml: diff.behav. in miniscript with mini-subpb";
1.43 + error "FE-interface.sml: diff.behav. in miniscript with mini-subpb";
1.44
1.45 DEconstrCalcTree 1;
1.46
1.47 @@ -372,7 +372,7 @@
1.48 val p = get_pos 1 1;
1.49 val (Form f, tac, asms) = pt_extract (pt, p);
1.50 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.51 - raise error "FE-interface.sml: diff.behav. in miniscript with mini-subpb";
1.52 + error "FE-interface.sml: diff.behav. in miniscript with mini-subpb";
1.53
1.54 DEconstrCalcTree 1;
1.55
1.56 @@ -397,7 +397,7 @@
1.57 val p = get_pos 1 1;
1.58 val (Form f, tac, asms) = pt_extract (pt, p);
1.59 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.60 - raise error "FE-interface.sml: diff.behav. in solve_linear/rt AUTOCALCULATE ";
1.61 + error "FE-interface.sml: diff.behav. in solve_linear/rt AUTOCALCULATE ";
1.62
1.63
1.64 "--------- solve_linear as rootpbl AUTOCALC CompleteHead/Calc ----";
1.65 @@ -420,7 +420,7 @@
1.66 autoCalculate 1 CompleteCalc;
1.67 val ((pt,p),_) = get_calc 1;
1.68 if p=([], Res) then () else
1.69 - raise error "FE-interface.sml: diff.behav. in solve_linear AUTOC Head/Calc ";
1.70 + error "FE-interface.sml: diff.behav. in solve_linear AUTOC Head/Calc ";
1.71
1.72
1.73 "--------- miniscript with mini-subpbl AUTOCALCULATE CompleteCalc-";
1.74 @@ -452,7 +452,7 @@
1.75 val p = get_pos 1 1;
1.76 val (Form f, tac, asms) = pt_extract (pt, p);
1.77 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.78 - raise error "FE-interface.sml: diff.behav. in mini-subpbl AUTOCALCULATE 6";
1.79 + error "FE-interface.sml: diff.behav. in mini-subpbl AUTOCALCULATE 6";
1.80
1.81
1.82 "--------- miniscript with mini-subpbl AUTO CompleteCalcHead------";
1.83 @@ -495,7 +495,7 @@
1.84 if get_obj g_spec pt [] = ("e_domID",
1.85 ["linear", "univariate","equation","test"],
1.86 ["Test","solve_linear"]) then ()
1.87 - else raise error "FE-interface.sml: diff.behav. in setProblem, setMethod";
1.88 + else error "FE-interface.sml: diff.behav. in setProblem, setMethod";
1.89
1.90 autoCalculate 1 CompleteCalcHead;
1.91 refFormula 1 (get_pos 1 1);
1.92 @@ -508,7 +508,7 @@
1.93 val p = get_pos 1 1;
1.94 val (Form f, tac, asms) = pt_extract (pt, p);
1.95 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.96 - raise error "FE-interface.sml: diff.behav. in mini-subpbl AUTOCALCULATE 6";
1.97 + error "FE-interface.sml: diff.behav. in mini-subpbl AUTOCALCULATE 6";
1.98
1.99
1.100 "--------- setContext..Thy ---------------------------------------";
1.101 @@ -558,7 +558,7 @@
1.102 writeln str;
1.103 if str = ". ----- pblobj -----\n1. x + 1 = 2\n2. x + 1 + -1 * 2 = 0\n"
1.104 then () else
1.105 - raise error "FE-interface.sml: diff.behav. in mini-subpbl CompleteToSubpbl-1";
1.106 + error "FE-interface.sml: diff.behav. in mini-subpbl CompleteToSubpbl-1";
1.107
1.108 autoCalculate 1 (Step 1); (*proceeds only, of NOT 1 step before subplb*)
1.109 autoCalculate 1 CompleteToSubpbl;
1.110 @@ -570,7 +570,7 @@
1.111 val p = get_pos 1 1;
1.112 val (Form f, tac, asms) = pt_extract (pt, p);
1.113 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.114 - raise error "FE-interface.sml: diff.behav. in mini-subpbl CompleteToSubpbl 1";
1.115 + error "FE-interface.sml: diff.behav. in mini-subpbl CompleteToSubpbl 1";
1.116
1.117
1.118
1.119 @@ -777,7 +777,7 @@
1.120 val p = get_pos 1 1;
1.121 val (Form f, tac, asms) = pt_extract (pt, p);
1.122 if term2str f = "[x = -1, x = -3]" andalso p = ([], Res) then () else
1.123 - raise error "FE-interface.sml: diff.behav. in tryMatchProblem, tryRefine";
1.124 + error "FE-interface.sml: diff.behav. in tryMatchProblem, tryRefine";
1.125
1.126 (*------------^^^-inserted-----------------------------------------------*)
1.127 (*WN050904 the fetchProposedTactic's below may not have worked like that
1.128 @@ -800,7 +800,7 @@
1.129 val p = get_pos 1 1;
1.130 val (Form f, tac, asms) = pt_extract (pt, p);
1.131 if term2str f = "[x = -1, x = -3]" andalso p = ([], Res) then () else
1.132 - raise error "FE-interface.sml: diff.behav. in tryMatchProblem, tryRefine";
1.133 + error "FE-interface.sml: diff.behav. in tryMatchProblem, tryRefine";
1.134
1.135
1.136 "--------- modifyCalcHead, resetCalcHead, modelProblem ------------";
1.137 @@ -939,7 +939,7 @@
1.138 val p = get_pos 1 1;
1.139 val (Form f, tac, asms) = pt_extract (pt, p);
1.140 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.141 - raise error "FE-interface.sml: diff.behav. in from pbl-hierarchy";
1.142 + error "FE-interface.sml: diff.behav. in from pbl-hierarchy";
1.143
1.144
1.145
1.146 @@ -957,7 +957,7 @@
1.147 val p = get_pos 1 1;
1.148 val (Form f, tac, asms) = pt_extract (pt, p);
1.149 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.150 - raise error "FE-interface.sml: diff.behav. in algebra system";
1.151 + error "FE-interface.sml: diff.behav. in algebra system";
1.152
1.153
1.154
1.155 @@ -1098,7 +1098,7 @@
1.156 val p = get_pos 1 1;
1.157 val (Form f, tac, asms) = pt_extract (pt, p);
1.158 if term2str f = "[x = 1]" andalso p = ([], Res) then () else
1.159 - raise error "FE-interface.sml: diff.behav. in combinations of steps";
1.160 + error "FE-interface.sml: diff.behav. in combinations of steps";
1.161
1.162
1.163 "--------- appendFormula label{SOLVE:MANUAL:FORMULA:enter} right--";
1.164 @@ -1124,7 +1124,7 @@
1.165 val p = get_pos 1 1;
1.166 val (Form f, tac, asms) = pt_extract (pt, p);
1.167 if term2str f = "-1 + x = 0" andalso p = ([2], Res) then () else
1.168 - raise error "FE-interface.sml: diff.behav. in FORMULA:enter} right";
1.169 + error "FE-interface.sml: diff.behav. in FORMULA:enter} right";
1.170
1.171 "--------- appendFormula label{SOLVE:MANUAL:FORMULA:enter} other--";
1.172 "--------- appendFormula label{SOLVE:MANUAL:FORMULA:enter} other--";
1.173 @@ -1149,7 +1149,7 @@
1.174 val p = get_pos 1 1;
1.175 val (Form f, tac, asms) = pt_extract (pt, p);
1.176 if term2str f = "x - 1 = 0" andalso p = ([2], Res) then () else
1.177 - raise error "FE-interface.sml: diff.behav. in FORMULA:enter} other";
1.178 + error "FE-interface.sml: diff.behav. in FORMULA:enter} other";
1.179
1.180 "--------- appendFormula label{SOLVE:MANUAL:FORMULA:enter} oth 2--";
1.181 "--------- appendFormula label{SOLVE:MANUAL:FORMULA:enter} oth 2--";
1.182 @@ -1175,7 +1175,7 @@
1.183 val p = get_pos 1 1;
1.184 val (Form f, tac, asms) = pt_extract (pt, p);
1.185 if term2str f = "x = 1" andalso p = ([3,2], Res) then () else
1.186 - raise error "FE-interface.sml: diff.behav. in FORMULA:enter} oth 2";
1.187 + error "FE-interface.sml: diff.behav. in FORMULA:enter} oth 2";
1.188
1.189
1.190 "--------- appendFormula label{SOLVE:MANUAL:FORMULA:enter} NOTok--";
1.191 @@ -1199,7 +1199,7 @@
1.192 val p = get_pos 1 1;
1.193 val (Form f, tac, asms) = pt_extract (pt, p);
1.194 if term2str f = "x + 1 + -1 * 2 = 0" andalso p = ([1], Res) then () else
1.195 - raise error "FE-interface.sml: diff.behav. in FORMULA:enter} NOTok";
1.196 + error "FE-interface.sml: diff.behav. in FORMULA:enter} NOTok";
1.197
1.198
1.199 "--------- replaceFormula {SOLVE:MANUAL:FORMULA:replace} right----";
1.200 @@ -1222,11 +1222,11 @@
1.201 val p = get_pos 1 1;
1.202 val (Form f, tac, asms) = pt_extract (pt, p);
1.203 if term2str f = "-1 + x = 0" andalso p = ([2], Res) then () else
1.204 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} right 1";
1.205 + error "FE-interface.sml: diff.behav. in FORMULA:replace} right 1";
1.206 if map fst (get_interval ([2],Res) ([],Res) 9999 pt) =
1.207 [([2], Res), ([3], Pbl), ([3, 1], Frm), ([3, 1], Res), ([3, 2], Res),
1.208 ([3], Res), ([4], Res), ([], Res)] then () (*nothing deleted!*) else
1.209 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} right 2";
1.210 + error "FE-interface.sml: diff.behav. in FORMULA:replace} right 2";
1.211
1.212 (*WN050211 replaceFormula didn't work on second ctree: thus now tested...*)
1.213 CalcTree
1.214 @@ -1245,11 +1245,11 @@
1.215 val p = get_pos 2 1;
1.216 val (Form f, tac, asms) = pt_extract (pt, p);
1.217 if term2str f = "-1 + x = 0" andalso p = ([2], Res) then () else
1.218 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} right 1";
1.219 + error "FE-interface.sml: diff.behav. in FORMULA:replace} right 1";
1.220 if map fst (get_interval ([2],Res) ([],Res) 9999 pt) =
1.221 [([2], Res), ([3], Pbl), ([3, 1], Frm), ([3, 1], Res), ([3, 2], Res),
1.222 ([3], Res), ([4], Res), ([], Res)] then () (*nothing deleted!*) else
1.223 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} right 2b";
1.224 + error "FE-interface.sml: diff.behav. in FORMULA:replace} right 2b";
1.225
1.226 "--------- replaceFormula {SOLVE:MANUAL:FORMULA:replace} other----";
1.227 "--------- replaceFormula {SOLVE:MANUAL:FORMULA:replace} other----";
1.228 @@ -1274,7 +1274,7 @@
1.229 val p = get_pos 1 1;
1.230 val (Form f, tac, asms) = pt_extract (pt, p);
1.231 if term2str f = "x - 1 = 0" andalso p = ([2], Res) then () else
1.232 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} other 1";
1.233 + error "FE-interface.sml: diff.behav. in FORMULA:replace} other 1";
1.234 (* for getting the list in whole length ...
1.235 print_depth 99;map fst (get_interval ([1],Res) ([],Res) 9999 pt);print_depth 3;
1.236 *)
1.237 @@ -1284,7 +1284,7 @@
1.238 ([2, 8], Res), ([2, 9], Res), ([2], Res)
1.239 (*WN060727 {cutlevup->test_trans} removed: ,
1.240 ([], Res)(*dropped, if test_trans doesnt stop at PblNd*)*)] then () else
1.241 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} other 2";
1.242 + error "FE-interface.sml: diff.behav. in FORMULA:replace} other 2";
1.243
1.244
1.245
1.246 @@ -1314,12 +1314,12 @@
1.247 [([1], Res), ([2], Res), ([3], Pbl), ([3, 1], Frm), ([3, 1], Res),
1.248 ([3, 2, 1], Frm), ([3, 2, 1], Res), ([3, 2, 2], Res),
1.249 ([3,2],Res)] then () else
1.250 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} oth2 1";
1.251 + error "FE-interface.sml: diff.behav. in FORMULA:replace} oth2 1";
1.252
1.253 val p = get_pos 1 1;
1.254 val (Form f, tac, asms) = pt_extract (pt, p);
1.255 if term2str f = "x = 1" andalso p = ([3,2], Res) then () else
1.256 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} oth2 2";
1.257 + error "FE-interface.sml: diff.behav. in FORMULA:replace} oth2 2";
1.258
1.259
1.260
1.261 @@ -1344,6 +1344,6 @@
1.262 val p = get_pos 1 1;
1.263 val (Form f, tac, asms) = pt_extract (pt, p);
1.264 if term2str f = "-1 + x = 0" andalso p = ([2], Res) then () else
1.265 - raise error "FE-interface.sml: diff.behav. in FORMULA:replace} NOTok";
1.266 + error "FE-interface.sml: diff.behav. in FORMULA:replace} NOTok";
1.267
1.268