projectlombok / lombok

Very spicy additions to the Java programming language.
https://projectlombok.org/
Other
12.83k stars 2.37k forks source link

[BUG] Javac crash when compiling class #2845

Open xxDark opened 3 years ago

xxDark commented 3 years ago

Describe the bug Javac crash when compiling class

To Reproduce Attempting to compile the following code results in a crash:

  private static Class<?> unmaskOwner(Object handle) {
    if (handle instanceof Class) {
      return (Class<?>) handle;
    }
    return handle.getClass();
  }

Expected behavior No javac crash

Version info):

https://paste.implario.dev/acadojijuc.java

xxDark commented 3 years ago

Update: that seems like a generics issue, not sure what is causing it in the first place.

Rawi01 commented 3 years ago

There are three other issues (#2420, #2833, #2839) with a similar stacktrace. Can you share a full example to verify if the issue is the same and also fixed by #2840?