OpenJDK / jdk / jdk
changeset 59863:ba81cfc89de8
8233014: Enable ShowCodeDetailsInExceptionMessages by default.
Reviewed-by: coleenp, stuefe, dholmes
author | goetz |
---|---|
date | Thu, 18 Jun 2020 22:03:18 +0200 |
parents | c5904de55565 |
children | 6132f62c131d |
files | src/hotspot/share/runtime/globals.hpp test/hotspot/jtreg/runtime/exceptionMsgs/NullPointerException/SuppressMessagesTest.java test/hotspot/jtreg/vmTestbase/jit/t/t104/t104.gold test/langtools/jdk/jshell/ToolSimpleTest.java |
diffstat | 4 files changed, 8 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/src/hotspot/share/runtime/globals.hpp Thu Jun 18 17:32:57 2020 -0700 +++ b/src/hotspot/share/runtime/globals.hpp Thu Jun 18 22:03:18 2020 +0200 @@ -617,7 +617,7 @@ product(bool, OmitStackTraceInFastThrow, true, \ "Omit backtraces for some 'hot' exceptions in optimized code") \ \ - manageable(bool, ShowCodeDetailsInExceptionMessages, false, \ + manageable(bool, ShowCodeDetailsInExceptionMessages, true, \ "Show exception messages from RuntimeExceptions that contain " \ "snippets of the failing code. Disable this to improve privacy.") \ \
--- a/test/hotspot/jtreg/runtime/exceptionMsgs/NullPointerException/SuppressMessagesTest.java Thu Jun 18 17:32:57 2020 -0700 +++ b/test/hotspot/jtreg/runtime/exceptionMsgs/NullPointerException/SuppressMessagesTest.java Thu Jun 18 22:03:18 2020 +0200 @@ -1,6 +1,6 @@ /* - * Copyright (c) 2019, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2019 SAP SE. All rights reserved. + * Copyright (c) 2019, 2020, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2019, 2020 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,12 +24,12 @@ /** * @test - * @summary Test that the default of flag ShowCodeDetailsInExceptionMessages is 'false', - * i.e., make sure the VM does not print the message on default. + * @summary Test that the default of flag ShowCodeDetailsInExceptionMessages is 'true', + * i.e., make sure the VM does print the message by default. * @bug 8218628 * @library /test/lib * @compile -g SuppressMessagesTest.java - * @run main/othervm SuppressMessagesTest noMessage + * @run main/othervm SuppressMessagesTest printMessage */ /** * @test
--- a/test/hotspot/jtreg/vmTestbase/jit/t/t104/t104.gold Thu Jun 18 17:32:57 2020 -0700 +++ b/test/hotspot/jtreg/vmTestbase/jit/t/t104/t104.gold Thu Jun 18 22:03:18 2020 +0200 @@ -1,2 +1,2 @@ Exception thrown. -java.lang.NullPointerException +java.lang.NullPointerException: Cannot enter synchronized block because "<local1>" is null
--- a/test/langtools/jdk/jshell/ToolSimpleTest.java Thu Jun 18 17:32:57 2020 -0700 +++ b/test/langtools/jdk/jshell/ToolSimpleTest.java Thu Jun 18 22:03:18 2020 +0200 @@ -132,7 +132,7 @@ + "| Caused by: java.io.IOException: bar\n" + "| at n (#2:1)\n" + "| ...\n" - + "| Caused by: java.lang.NullPointerException\n" + + "| Caused by: java.lang.NullPointerException: Cannot invoke \"String.toString()\" because \"null\" is null\n" + "| at p (#1:1)\n" + "| ..."), (a) -> assertCommand(a, "/drop p",