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

@Delegate on static inner class does not work in JDK 9 #1398

Open
schauder opened this issue May 22, 2017 · 0 comments
Open

@Delegate on static inner class does not work in JDK 9 #1398

schauder opened this issue May 22, 2017 · 0 comments

Comments

@schauder
Copy link

This code

public class Host {

    static class StaticDelegate implements Consumer<String> {

    	@Delegate private Consumer<String> delegate;
    }
}

when compiled with JDK9 produces the compile error:

StaticDelegate is not abstract and does not override abstract method accept(String) in Consumer
static class StaticDelegate implements Consumer<String>

I tried it with the 1.16.16 release and the current edge release.

For a complete example including shell script and maven build file, see https://github.com/schauder/spring-data-from-java-9/blob/master/lombok/src/main/java/de/schauderhaft/jdk9/lombok/Host.java

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