Jasig / jspc-maven-plugin

UNMAINTAINED Maven plugin that compiles JSPs
http://unmaintained.tech/
Apache License 2.0
24 stars 38 forks source link

Invoke static function on interface fails compilation #43

Closed ksmith97 closed 7 years ago

ksmith97 commented 7 years ago

The current version of tomcat-jasper in tomcat8 compiler is unable to deal with an invocation of a static function on an interface.
I tried bumping the version to 8.5.13 which is the latest but it still fails.

To enable it to work I had to bump tomcat-jasper up to 9.0.0.M19 which allowed compilation to complete successfully.

This may end up being documentation of a known issue more than something that can be fixed but I did note that none of the current compilers use 9.x so maybe planning an upgrade for sometime soon is a good idea.

It looks like at one point the jspc compiler may have accidentally supported this feature and then lost it so it may be that a lower jspc version also works since some of the older tomcat servers can render this properly.

Obviously if you are trying to match your tomcat version this isnt super helpful and the answer may be to refactor the code to not have static methods on interfaces.

ChristianMurphy commented 7 years ago

Thanks for the report @ksmith97! :clap: :+1: Would you be able to open a Pull Request to resolve this?

ksmith97 commented 7 years ago

@ChristianMurphy I don't think you can resolve this since the goal is to match tomcat to the compiler for most people and the available compilers for tomcat 8 appear to not have this capability. All you can really do is document it as an issue.

ChristianMurphy commented 7 years ago

All you can really do is document it as an issue.

Exactly, documenting this in the README would be a resolution. :scroll: It would also be good to file this upstream with Tomcat so it can get a code fix.

ksmith97 commented 7 years ago

So, I submitted https://github.com/Jasig/jspc-maven-plugin/pull/44 let me know if this is what you had in mind.

ChristianMurphy commented 7 years ago

addressed with #44