diff options
author | bd-912 <bdunahu@colostate.edu> | 2024-05-12 13:30:35 -0600 |
---|---|---|
committer | bd-912 <bdunahu@colostate.edu> | 2024-05-12 13:30:35 -0600 |
commit | e5709fbc956d3395e7b401fd5198524e02542e81 (patch) | |
tree | ca528882e64927f2eeda4a2ac6756059c156e4e1 /output/negative/DumbBracketSend-error.java | |
parent | 42a95045240803c8ce2f3af9b63ab5a10c07ce0c (diff) |
Make (classinstance).send typecheck in HeatVisitor
Diffstat (limited to 'output/negative/DumbBracketSend-error.java')
-rw-r--r-- | output/negative/DumbBracketSend-error.java | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/output/negative/DumbBracketSend-error.java b/output/negative/DumbBracketSend-error.java new file mode 100644 index 0000000..263f66f --- /dev/null +++ b/output/negative/DumbBracketSend-error.java @@ -0,0 +1,22 @@ +class ex19 { + public static void main(String[] a){ + System.out.println(new Test().start()); + } +} + +class Test { + + Test test; + int[] i; + + public int start() { + i = new int[10]; + test = (i).next(); + return 0; + } + + public Test next() { + System.out.println(1); + return test; + } +} |