-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New test case: iface-with-default-func
- Loading branch information
1 parent
452dcbb
commit a39a8d8
Showing
3 changed files
with
26 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v3.5.1 | ||
v3.5.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
public class main { | ||
|
||
public static void main(String[] args) { | ||
int result = -1; | ||
var bc = new BronzeClass(); | ||
result = bc.returnAnInt(); | ||
assert (result == 42); | ||
result = bc.bcReturnAnInt(); | ||
assert (result == 42); | ||
} | ||
|
||
} | ||
|
||
interface BronzeFace { | ||
default int returnAnInt() { | ||
return 42; | ||
} | ||
} | ||
|
||
class BronzeClass implements BronzeFace { | ||
int bcReturnAnInt() { | ||
return returnAnInt(); | ||
} | ||
} |