mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 14:54:52 +02:00
8223553: Fix code constructs that do not compile with the Eclipse Java Compiler
Reviewed-by: smarks, dfuchs
This commit is contained in:
parent
4dd6b687ef
commit
fd67f8ee69
3 changed files with 17 additions and 11 deletions
|
@ -4980,8 +4980,10 @@ assertEquals("boojum", (String) catTrace.invokeExact("boo", "jum"));
|
|||
|
||||
// Step 1C: determine loop return type.
|
||||
// Step 1D: check other types.
|
||||
final Class<?> loopReturnType = fini.stream().filter(Objects::nonNull).map(MethodHandle::type).
|
||||
map(MethodType::returnType).findFirst().orElse(void.class);
|
||||
// local variable required here; see JDK-8223553
|
||||
Stream<Class<?>> cstream = fini.stream().filter(Objects::nonNull).map(MethodHandle::type)
|
||||
.map(MethodType::returnType);
|
||||
final Class<?> loopReturnType = cstream.findFirst().orElse(void.class);
|
||||
loopChecks1cd(pred, fini, loopReturnType);
|
||||
|
||||
// Step 2: determine parameter lists.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue