47cffc5d2a
Flattens case structures as nyacc is giving consecutive cases as a nested block like: (case testA (case testB (case testC BODY))) We convert to: ((case testA (expr-stmt)) (case testB (expr-stmt)) (case testC BODY)) And then treat them as independent cases. For the fallthrough we just add a jump to each case's body right before its clause (each of the case blocks is responsible of adding its own jump to its body): // This doesn't have it because it's the first CASE1: testA CASE1_BODY: goto CASE2_BODY CASE2: testB CASE2_BODY: goto CASE3_BODY CASE3: testB CASE3_BODY: This enables complex fallthrough schemes comparing to what was done before. * module/mescc/compile.scm (ast->info)[switch]{flatten-cases}: New variable. (ast->info)[switch]{statements}: Use flatten-cases on it. (switch->expr): Remove unneeded matchers and add jumps to body. * build-aux/check-mescc.sh(xfail-tests): Remove lib/tests/scaffold/66-local-char-array.c. |
||
---|---|---|
.. | ||
bootstrap.sh.in | ||
build-guile.sh | ||
build-lib.sh | ||
build-mes.sh | ||
build-scaffold.sh | ||
build-source-lib.sh | ||
build.sh.in | ||
cc.sh | ||
cflags.sh | ||
check-boot.sh | ||
check-mes.sh | ||
check-mescc.sh | ||
check.sh.in | ||
config.make.in | ||
config.sh.in | ||
configure-lib.sh | ||
export.make | ||
gendocs.sh | ||
gitlog-to-changelog | ||
GNUmakefile.in | ||
indent.sh | ||
install.sh.in | ||
manifest.scm | ||
mes-snarf.scm | ||
pointer.sh | ||
pre-inst-env.in | ||
setup-mes.sh | ||
snarf.sh | ||
test-boot.sh | ||
test-c.sh | ||
test-driver | ||
test-suite.sh | ||
trace.sh | ||
uninstall.sh.in |