Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Annotated nested classes inside records are not indexed #84

Open
hoat4 opened this issue Nov 15, 2024 · 0 comments
Open

Annotated nested classes inside records are not indexed #84

hoat4 opened this issue Nov 15, 2024 · 0 comments

Comments

@hoat4
Copy link

hoat4 commented Nov 15, 2024

Example:

package classindexbug;

public class T1 {

    @Ann
    public static class ClassInsideT1 {
    }
}
package classindexbug;

public record T2() {

    @Ann
    public static class ClassInsideT2 {
    }
}
package classindexbug;

import org.atteo.classindex.IndexAnnotated;
import java.lang.annotation.Target;
import static java.lang.annotation.ElementType.TYPE;

@IndexAnnotated
@Target(TYPE)
public @interface Ann {
}

The result in META-INF/annotations/classindexbug.Ann:

classindexbug.T1$ClassInsideT1

So T2$ClassInsideT2 is missing. The only difference between it and T1$ClassInsideT1 is that T2$ClassInsideT2 is declared in a record type.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant