You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TypeReference.of("int") fails because a dot is expected in the type name.
begin 0, end -1, length 3
java.lang.StringIndexOutOfBoundsException: begin 0, end -1, length 3
at java.base/java.lang.String.checkBoundsBeginEnd(String.java:4601)
at java.base/java.lang.String.substring(String.java:2704)
at org.springframework.aot.hint.SimpleTypeReference.createTypeReference(SimpleTypeReference.java:60)
at org.springframework.aot.hint.SimpleTypeReference.of(SimpleTypeReference.java:48)
at org.springframework.aot.hint.TypeReference.of(TypeReference.java:75)
The text was updated successfully, but these errors were encountered:
Ignoring the exception, this is the expected behaviour. Fully qualified name is expected as an input here so it should be TypeReference.of("java.lang.int").
snicoll
changed the title
Fix TypeReference#of for primitive types
Throw a meaningful exception if a TypeReference does not use a fully qualified name
Mar 22, 2022
TypeReference.of("int")
fails because a dot is expected in the type name.The text was updated successfully, but these errors were encountered: