RFR: 8273234: extended 'for' with expression of type tvar causes the compiler to crash

Vicente Romero vromero at openjdk.java.net
Thu Sep 2 04:25:44 UTC 2021


Please review this one liner patch that is fixing a crash in the compiler. Method `Attr::visitForeachLoop` is doing a lookup for method `iterator` without making sure that the `site` where the method is being looked for is not a type variable.

TIA

-------------

Commit messages:
 - 8273234: extended 'for' with expression of type tvar causes the compiler to crash

Changes: https://git.openjdk.java.net/jdk/pull/5346/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=5346&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8273234
  Stats: 50 lines in 2 files changed: 49 ins; 0 del; 1 mod
  Patch: https://git.openjdk.java.net/jdk/pull/5346.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/5346/head:pull/5346

PR: https://git.openjdk.java.net/jdk/pull/5346


More information about the compiler-dev mailing list