-
Notifications
You must be signed in to change notification settings - Fork 7
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
Showing
8 changed files
with
95 additions
and
7 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
sub Main() | ||
dim a as Map from Number to Number | ||
a(5) = 10 | ||
a(6) = 11 | ||
dim b as Map from Number to Number | ||
b(6) = 11 | ||
b(5) = 10 | ||
dim c as Map from Number to Number | ||
c(50) = 100 | ||
if a = a then print "a = a" | ||
if a = b then print "a = b" | ||
if a = c then print "a = c" | ||
end sub | ||
|
||
--output-- | ||
a = a | ||
a = b |
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,12 @@ | ||
sub Main() | ||
dim a as Map from Number to Number | ||
dim b as Map from Number to Number | ||
if a > b then print "wrong" | ||
end sub | ||
|
||
--output-- | ||
Compiler error | ||
kTypeMismatch | ||
Main | ||
4:10 | ||
The ">" operator does not support the type "Map from Number to Number". |
12 changes: 12 additions & 0 deletions
12
src/test/programs/maps/map_comparison_greater_than_equals.bas
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,12 @@ | ||
sub Main() | ||
dim a as Map from Number to Number | ||
dim b as Map from Number to Number | ||
if a >= b then print "wrong" | ||
end sub | ||
|
||
--output-- | ||
Compiler error | ||
kTypeMismatch | ||
Main | ||
4:10 | ||
The ">=" operator does not support the type "Map from Number to Number". |
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,12 @@ | ||
sub Main() | ||
dim a as Map from Number to Number | ||
dim b as Map from Number to Number | ||
if a < b then print "wrong" | ||
end sub | ||
|
||
--output-- | ||
Compiler error | ||
kTypeMismatch | ||
Main | ||
4:10 | ||
The "<" operator does not support the type "Map from Number to Number". |
12 changes: 12 additions & 0 deletions
12
src/test/programs/maps/map_comparison_less_than_equals.bas
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,12 @@ | ||
sub Main() | ||
dim a as Map from Number to Number | ||
dim b as Map from Number to Number | ||
if a <= b then print "wrong" | ||
end sub | ||
|
||
--output-- | ||
Compiler error | ||
kTypeMismatch | ||
Main | ||
4:10 | ||
The "<=" operator does not support the type "Map from Number to Number". |
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,15 @@ | ||
sub Main() | ||
dim a as Map from Number to Number | ||
a(5) = 10 | ||
a(6) = 11 | ||
dim b as Map from Number to Number | ||
b(6) = 11 | ||
b(5) = 10 | ||
dim c as Map from Number to Number | ||
c(50) = 100 | ||
if a <> b then print "a <> b" | ||
if a <> c then print "a <> c" | ||
end sub | ||
|
||
--output-- | ||
a <> c |