-
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.
- Loading branch information
1 parent
514b214
commit b168f4a
Showing
6 changed files
with
214 additions
and
16 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
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
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
26 changes: 25 additions & 1 deletion
26
packages/safe-ds-lang/tests/resources/typing/expressions/operations/logical/main.sdsdev
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,17 +1,41 @@ | ||
package tests.typing.operations.logical | ||
|
||
pipeline myPipeline { | ||
@Pure fun cell() -> r: Cell<Number> | ||
|
||
pipeline constantOperands { | ||
// $TEST$ serialization literal<true> | ||
val conjunction = »true and true«; | ||
// $TEST$ serialization literal<true> | ||
val disjunction = »true or true«; | ||
// $TEST$ serialization literal<false> | ||
val negation = »not true«; | ||
} | ||
|
||
pipeline invalidOperands { | ||
// $TEST$ serialization Boolean | ||
val conjunctionInvalid = »1 and 1«; | ||
// $TEST$ serialization Boolean | ||
val disjunctionInvalid = »1.0 or 1.0«; | ||
// $TEST$ serialization Boolean | ||
val negationInvalid = »not "true"«; | ||
} | ||
|
||
pipeline cellOperands { | ||
// $TEST$ serialization Cell<Boolean> | ||
val conjunctionBooleanCell = »true and cell()«; | ||
// $TEST$ serialization Cell<Boolean> | ||
val disjunctionBooleanCell = »true or cell()«; | ||
|
||
// $TEST$ serialization Cell<Boolean> | ||
val conjunctionCellBoolean = »cell() and true«; | ||
// $TEST$ serialization Cell<Boolean> | ||
val disjunctionCellBoolean = »cell() or true«; | ||
|
||
// $TEST$ serialization Cell<Boolean> | ||
val conjunctionCellCell = »cell() and cell()«; | ||
// $TEST$ serialization Cell<Boolean> | ||
val disjunctionCellCell = »cell() or cell()«; | ||
|
||
// $TEST$ serialization Cell<Boolean> | ||
val negationCell = »not cell()«; | ||
} |