File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11// Tests that adding an @SameLen annotation to a primitive type is still
22// an error.
33
4+ // All the errors in this test case are disabled. They were issued when `@SameLen` was restricted
5+ // to arrays and CharSequence, but @SameLen can be written on an arbitrary user-defined type:
6+ // https://checkerframework.org/manual/#index-annotating-fixed-size .
7+
48import org .checkerframework .checker .index .qual .SameLen ;
59
610public class SameLenIrrelevant {
7- // :: error: (anno.on.irrelevant)
11+ // NO :: error: (anno.on.irrelevant)
812 public void test (@ SameLen ("#2" ) int x , int y ) {
913 // do nothing
1014 }
1115
12- // :: error: (anno.on.irrelevant)
16+ // NO :: error: (anno.on.irrelevant)
1317 public void test (@ SameLen ("#2" ) double x , double y ) {
1418 // do nothing
1519 }
1620
17- // :: error: (anno.on.irrelevant)
21+ // NO :: error: (anno.on.irrelevant)
1822 public void test (@ SameLen ("#2" ) char x , char y ) {
1923 // do nothing
2024 }
You can’t perform that action at this time.
0 commit comments