diff options
author | Alan Donovan <adonovan@google.com> | 2013-02-21 12:48:38 -0500 |
---|---|---|
committer | Alan Donovan <adonovan@google.com> | 2013-02-21 12:48:38 -0500 |
commit | aa5aaabb0d18d21d97e9c98d7dfde4899a498335 (patch) | |
tree | f73106a0e13ea4ab7f6e94345185104cc29d771a /test/recover.go | |
parent | df93283d5694814efc97efd2132da11722d11523 (diff) | |
download | go-aa5aaabb0d18d21d97e9c98d7dfde4899a498335.tar.gz go-aa5aaabb0d18d21d97e9c98d7dfde4899a498335.zip |
exp/ssa/interp: (#6 of 5): test interpretation of SSA form of $GOROOT/test/*.go.
The interpreter's os.Exit now triggers a special panic rather
than kill the test process. (It's semantically dubious, since
it will run deferred routines.) Interpret now returns its
exit code rather than calling os.Exit.
Also:
- disabled parts of a few $GOROOT/tests via os.Getenv("GOSSAINTERP").
- remove unnecessary 'slots' param to external functions; they
are never closures.
Most of the tests are disabled until go/types supports shifts.
They can be reenabled if you patch this workaround:
https://golang.org/cl/7312068
R=iant, bradfitz
CC=golang-dev, gri
https://golang.org/cl/7313062
Diffstat (limited to 'test/recover.go')
-rw-r--r-- | test/recover.go | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/test/recover.go b/test/recover.go index eea655ec57..7c27d7c4d6 100644 --- a/test/recover.go +++ b/test/recover.go @@ -8,15 +8,21 @@ package main -import "runtime" +import ( + "os" + "runtime" +) func main() { test1() test1WithClosures() test2() test3() - test4() - test5() + // exp/ssa/interp still has some bugs in recover(). + if os.Getenv("GOSSAINTERP") == "" { + test4() + test5() + } test6() test6WithClosures() test7() |