-
Notifications
You must be signed in to change notification settings - Fork 100
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
correcting tests for issue #1179 - handling TypeCheckExpr
- Loading branch information
Showing
5 changed files
with
21 additions
and
19 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
8 changes: 0 additions & 8 deletions
8
src/test/resources/testData/annotation.semantic/AssignIntWithIntTypeCheckedToFloat.hx
This file was deleted.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
src/test/resources/testData/annotation.semantic/AssignWithTypeChecker.hx
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,10 @@ | ||
// This is a negative test; an error should NOT occur. | ||
package; | ||
class Test { | ||
public function new() { | ||
// The following is OK because an Int unifies with a Float | ||
var f:Float = (10:Int); | ||
// compiler error Float should be Int | ||
var <error descr="Incompatible type: Float should be Int">i:Int = (10:Float)</error>; | ||
} | ||
} |
8 changes: 0 additions & 8 deletions
8
src/test/resources/testData/annotation.semantic/InitializeIntWithIntTypeCheckedToFloat.hx
This file was deleted.
Oops, something went wrong.
9 changes: 9 additions & 0 deletions
9
src/test/resources/testData/annotation.semantic/InitializeIntWithTypeChecked.hx
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; | ||
class Test { | ||
public function new() { | ||
// The following is OK because an Int unifies with a Float | ||
var f:Float = (10:Int); | ||
// compiler error Float should be Int | ||
var <error descr="Incompatible type: Float should be Int">i:Int = (10:Float)</error>; | ||
} | ||
} |