[ https://issues.apache.org/jira/browse/GROOVY-9154?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Paul King closed GROOVY-9154. ----------------------------- > JSR308 info incomplete in bytecode > ---------------------------------- > > Key: GROOVY-9154 > URL: https://issues.apache.org/jira/browse/GROOVY-9154 > Project: Groovy > Issue Type: Bug > Reporter: Paul King > Priority: Major > Labels: annotations > Fix For: 5.0.0-alpha-3 > > > For this Java code: > {code} > import net.jqwik.api.ForAll; > import net.jqwik.api.Property; > import net.jqwik.api.constraints.IntRange; > import java.util.List; > public class Jsr308J { > @Property > public boolean sizeZeroOrPositive( > @ForAll List<@IntRange(min=0, max=10) Integer> items > ) { > return items.size() >= 0; > } > } > {code} > bytecode for method contains this info: > {noformat} > RuntimeVisibleAnnotations: > 0: #22() > RuntimeVisibleTypeAnnotations: > 0: #24(#25=I#26,#27=I#28): METHOD_FORMAL_PARAMETER, param_index=0, > location=[TYPE_ARGUMENT(0)] > RuntimeVisibleParameterAnnotations: > parameter 0: > 0: #30() > {noformat} > For this Groovy code, > {code} > //@Grab('net.jqwik:jqwik:1.1.4') > import groovy.transform.CompileStatic > import net.jqwik.api.ForAll > import net.jqwik.api.Property > import net.jqwik.api.constraints.IntRange; > @CompileStatic > class Jsr308 { > @Property > boolean 'size zero or positive'( > @ForAll List<@IntRange(min=0, max=10) Integer> items > ) { > items.size() >= 0 > } > } > {code} > Respective bytecode info is: > {noformat} > RuntimeVisibleAnnotations: > 0: #31() > RuntimeVisibleParameterAnnotations: > parameter 0: > 0: #32() > {noformat} > It is missing the {{RuntimeVisibleTypeAnnotations}} information. -- This message was sent by Atlassian Jira (v8.20.10#820010)