diff options
author | dos-reis <gdr@axiomatics.org> | 2011-12-10 20:13:39 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2011-12-10 20:13:39 +0000 |
commit | 367602f23aeedbfae9887771527d72a860b4bc3f (patch) | |
tree | 2d1be3b3b69e6a6cf5bbfd17ce4ec7d364c13c9e /src | |
parent | 49fc7b2f58f56ea7c9aa8169be3dfcc22b818be2 (diff) | |
download | open-axiom-367602f23aeedbfae9887771527d72a860b4bc3f.tar.gz |
* interp/g-opt.boot (optSeq): Remove seqToCOND as now redundant
with packWhen!.
Diffstat (limited to 'src')
-rw-r--r-- | src/ChangeLog | 5 | ||||
-rw-r--r-- | src/interp/g-opt.boot | 9 |
2 files changed, 6 insertions, 8 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 143fe6af..137bcb48 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,10 @@ 2011-12-10 Gabriel Dos Reis <gdr@cs.tamu.edu> + * interp/g-opt.boot (optSeq): Remove seqToCOND as now redundant + with packWhen!. + +2011-12-10 Gabriel Dos Reis <gdr@cs.tamu.edu> + * boot/parser.boot (bpArgtypeList): Accept mapping types. * boot/ast.boot (bfType): New. * boot/translator.boot (genDeclaration): Use it. diff --git a/src/interp/g-opt.boot b/src/interp/g-opt.boot index 1ba56076..a16041a3 100644 --- a/src/interp/g-opt.boot +++ b/src/interp/g-opt.boot @@ -555,7 +555,7 @@ replaceableTemporary?(g,x) == or/[jumpTarget?(g,x') for x' in x] optSeq ['%seq,:l] == - tryToRemoveSeq seqToCOND getRidOfTemps splicePROGN l where + tryToRemoveSeq ['%seq,:getRidOfTemps splicePROGN l] where splicePROGN l == atomic? l => l l is [["PROGN",:stmts],:l'] => [:stmts,:l'] @@ -565,13 +565,6 @@ optSeq ['%seq,:l] == l is [["%LET",g,x],:r] and replaceableTemporary?(g,r) => getRidOfTemps substitute(x,g,r) [first l,:getRidOfTemps rest l] - seqToCOND l == - transform:= [[a,b] for x in l while (x is ['%when,[a,['%exit,b]]])] - before:= take(#transform,l) - aft:= after(l,before) - null before => ['%seq,:aft] - null aft => ['%when,:transform,'(%otherwise (conderr))] - optCond ['%when,:transform,['%otherwise,optSeq ['%seq,:aft]]] tryToRemoveSeq l == l is ['%seq,[op,a]] and op in '(%exit RETURN %leave %return) => a l |