test/Tools/isac/ProgLang/tools.sml
author Walther Neuper <neuper@ist.tugraz.at>
Tue, 28 Sep 2010 09:06:56 +0200
branchisac-update-Isa09-2
changeset 38031 460c24a6a6ba
parent 37960 ec20007095f2
child 42145 43e7e9f835b1
permissions -rw-r--r--
tuned error and writeln

# raise error --> error
# writeln in atomtyp, atomty, atomt and xmlsrc
     1 (* tests on Tools
     2    author: Walther Neuper
     3    WN071229,
     4    (c) due to copyright terms
     5 
     6 use"../smltest/Scripts/tools.sml";
     7 use"tools.sml";
     8 *)
     9 val thy = Real.thy;
    10 
    11 "-----------------------------------------------------------------";
    12 "table of contents -----------------------------------------------";
    13 "-----------------------------------------------------------------";
    14 "----------- fun matchsub ----------------------------------------";
    15 "-----------------------------------------------------------------";
    16 "-----------------------------------------------------------------";
    17 "-----------------------------------------------------------------";
    18 
    19 
    20 "----------- fun matchsub ----------------------------------------";
    21 "----------- fun matchsub ----------------------------------------";
    22 "----------- fun matchsub ----------------------------------------";
    23 if matchsub thy (str2term "(a + (b + c))") (str2term "?x + (?y + ?z)")
    24 then () else error "tools.sml matchsub a + (b + c)";
    25 
    26 if matchsub thy (str2term "(a + (b + c)) + d") (str2term "?x + (?y + ?z)")
    27 then () else error "tools.sml matchsub (a + (b + c)) + d";