changeset 56891:96ad823df459 pattern-runtime

Temporary testing support for RecordTest
author briangoetz
date Fri, 21 Jun 2019 13:26:49 -0400
parents f83e03003147
children 512622f4dd81
files test/jdk/java/lang/lang-runtime/PatternHandleTest.java
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/test/jdk/java/lang/lang-runtime/PatternHandleTest.java	Fri Jun 21 10:34:47 2019 -0400
+++ b/test/jdk/java/lang/lang-runtime/PatternHandleTest.java	Fri Jun 21 13:26:49 2019 -0400
@@ -118,6 +118,10 @@
         Object carrier;
         try {
             TryMatchInvoker inv = invokers.get(e.descriptor().returnType());
+            // @@@ temporary hack until we break out the assert-match machinery
+            if (inv == null)
+                inv = (MethodHandle mh, Object x) -> mh.invoke(x);
+            // @@@ end temporary hack
             carrier = inv.tryMatch(e.tryMatch(), target);
         }
         catch (Throwable t) {