-
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.
feat: LCS returns
Any
or Any?
instead of $unknown
- Loading branch information
1 parent
bfaf3ce
commit 2f645c8
Showing
4 changed files
with
54 additions
and
32 deletions.
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
24 changes: 24 additions & 0 deletions
24
...s/safe-ds-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest
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 @@ | ||
package tests.typing.lowestCommonSupertype.unhandledType | ||
|
||
class C | ||
@Pure fun f() -> (r1: Int, r2: Int) | ||
|
||
segment mySegment() { | ||
// $TEST$ serialization List<Any> | ||
»[1, f]«; | ||
|
||
// $TEST$ serialization List<Any?> | ||
»[null, f]«; | ||
|
||
// $TEST$ serialization List<Any> | ||
»[1, C]«; | ||
|
||
// $TEST$ serialization List<Any?> | ||
»[null, C]«; | ||
|
||
// $TEST$ serialization List<Any> | ||
»[1, f()]«; | ||
|
||
// $TEST$ serialization List<Any?> | ||
»[null, f()]«; | ||
} |
23 changes: 0 additions & 23 deletions
23
...afe-ds-lang/tests/resources/typing/lowest common supertype/unknown supertype/main.sdstest
This file was deleted.
Oops, something went wrong.
9 changes: 9 additions & 0 deletions
9
...ges/safe-ds-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest
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,9 @@ | ||
package tests.typing.lowestCommonSupertype.unknownType | ||
|
||
segment mySegment() { | ||
// $TEST$ serialization List<Any?> | ||
»[1, unknown]«; | ||
|
||
// $TEST$ serialization List<Any?> | ||
»[null, unknown]«; | ||
} |