You can’t insert @SuppresWarnings
on a return statement. In java 8 you can annotate only classes, methods/constructors, fields, parameters and (new in java 8) local variables.
So in your case java can’t parse what you have written. Move the @SuppressWarnings
at the method level.
1
solved Weird result from “@SuppressWarnings”