From 64603653f82082431941cb29ad317b669822f28e Mon Sep 17 00:00:00 2001 From: Simon Ochsenreither Date: Fri, 22 Nov 2013 20:02:08 +0100 Subject: SI-7999 s.u.c.NonFatal: StackOverflowError is fatal As demonstrated in https://groups.google.com/d/topic/scala-language/eC9dqTTBYHg, SOEs should be considered fatal, because all popular JVM implementations seem to run into inconsistent state (ignoring finally blocks leading to not running monitorExit, leading to locks not being unlocked, ...) if one just pushes them enough. --- test/files/jvm/non-fatal-tests.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/files/jvm/non-fatal-tests.scala b/test/files/jvm/non-fatal-tests.scala index 791b1d3100..1ff7ee516e 100644 --- a/test/files/jvm/non-fatal-tests.scala +++ b/test/files/jvm/non-fatal-tests.scala @@ -4,8 +4,7 @@ trait NonFatalTests { //NonFatals val nonFatals: Seq[Throwable] = - Seq(new StackOverflowError, - new RuntimeException, + Seq(new RuntimeException, new Exception, new Throwable, new NotImplementedError) @@ -13,6 +12,7 @@ trait NonFatalTests { //Fatals val fatals: Seq[Throwable] = Seq(new InterruptedException, + new StackOverflowError, new OutOfMemoryError, new LinkageError, new VirtualMachineError {}, -- cgit v1.2.3