summaryrefslogtreecommitdiffstats
path: root/tests/012/quine.tl
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2021-01-20 18:59:57 -0800
committerKaz Kylheku <kaz@kylheku.com>2021-01-20 18:59:57 -0800
commitd30af5639c1a3a27452a7cd63c6f91201eac687b (patch)
tree9923feff7556bb6aa28e43e610d5bfa1c58c975e /tests/012/quine.tl
parentac1405bd21d70414ea508e60f1542b4a5551f016 (diff)
downloadtxr-d30af5639c1a3a27452a7cd63c6f91201eac687b.tar.gz
txr-d30af5639c1a3a27452a7cd63c6f91201eac687b.tar.bz2
txr-d30af5639c1a3a27452a7cd63c6f91201eac687b.zip
match-case: eliminate useless initial flag test.
* share/txr/stdlib/match.tl (match-case): The first case should not test the flag variable, the variable is false. This compiles to a useless if instruction and unreachable code. I tried writing a peephole rule against that instruction sequence in an experimental peephole optimizer, but across the entire code, it only matched in code in compiler.tl arising out of match-case, so it is better to squash this at the source. I won't commit the peephole optimizer until it comes up with something that isn't better fixed elsewhere.
Diffstat (limited to 'tests/012/quine.tl')
0 files changed, 0 insertions, 0 deletions