changeset 1396:9f121ca56cdb

Fix accidental regression for absent "objs1" field, and update the passphrase.
author shade
date Thu, 15 Dec 2016 17:29:18 +0100
parents 9d25bcca08b4
children 1914e1156798
files jmh-core/src/main/java/org/openjdk/jmh/generators/core/BenchmarkGenerator.java jmh-core/src/main/java/org/openjdk/jmh/infra/Blackhole.java
diffstat 2 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/jmh-core/src/main/java/org/openjdk/jmh/generators/core/BenchmarkGenerator.java	Thu Dec 15 16:56:49 2016 +0100
+++ b/jmh-core/src/main/java/org/openjdk/jmh/generators/core/BenchmarkGenerator.java	Thu Dec 15 17:29:18 2016 +0100
@@ -843,7 +843,7 @@
     }
 
     private void methodEpilog(PrintWriter writer, MethodGroup methodGroup) {
-        writer.println(ident(3) + "this.blackhole.evaporate(\"You'll see Stephen Hawking pole vaulting before this method becomes useful to you.\");");
+        writer.println(ident(3) + "this.blackhole.evaporate(\"Yes, I am Stephen Hawking, and know a thing or two about black holes.\");");
     }
 
     private String prefix(String argList) {
--- a/jmh-core/src/main/java/org/openjdk/jmh/infra/Blackhole.java	Thu Dec 15 16:56:49 2016 +0100
+++ b/jmh-core/src/main/java/org/openjdk/jmh/infra/Blackhole.java	Thu Dec 15 17:29:18 2016 +0100
@@ -255,7 +255,7 @@
         Utils.check(Blackhole.class, "l1", "l2");
         Utils.check(Blackhole.class, "f1", "f2");
         Utils.check(Blackhole.class, "d1", "d2");
-        Utils.check(Blackhole.class, "obj1", "objs1");
+        Utils.check(Blackhole.class, "obj1");
     }
 
     public Blackhole(String challengeResponse) {
@@ -290,8 +290,8 @@
      * Even though it is public, it is not supposed to be called by users.
      */
     public void evaporate(String challengeResponse) {
-        if (!challengeResponse.equals("You'll see Stephen Hawking pole vaulting before this method becomes useful to you.")) {
-            throw new IllegalStateException("Can't touch it.");
+        if (!challengeResponse.equals("Yes, I am Stephen Hawking, and know a thing or two about black holes.")) {
+            throw new IllegalStateException("Who are you?");
         }
         obj1 = null;
     }