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
When using an @OrderNonDet collection as a String in String concatenation, it should be treated as a @NonDet String because the order of the contents are not known. However, the checker tries to give the String type @OrderNonDet, which generates the warning that @OrderNonDet can't be written on such a type (String). This is shown in this class
.java:6: error: [ordernondet.on.noncollection.and.nonarray] @OrderNonDet annotation is invalid for non-collections and non-arrays
String s = "literal" + set;
^
Either set's toString return type should be used instead of set's type here for the String, or primitive operations like addition should change @OrderNonDet to @NonDet automatically, instead of issuing an error.
The text was updated successfully, but these errors were encountered:
When using an
@OrderNonDet
collection as a String in String concatenation, it should be treated as a@NonDet
String because the order of the contents are not known. However, the checker tries to give the String type@OrderNonDet
, which generates the warning that@OrderNonDet
can't be written on such a type (String
). This is shown in this classEither
set
'stoString
return type should be used instead ofset
's type here for the String, or primitive operations like addition should change@OrderNonDet
to@NonDet
automatically, instead of issuing an error.The text was updated successfully, but these errors were encountered: