-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding dictionary constructor to subsumption rule (#1998)
* adding constructors to subsumption rule * Add test * Modify test * Add dictionary constructor subtyping and adding a test for it * Update core/tests/integration/inputs/typecheck/dictionary_subtyping.ncl Co-authored-by: Yann Hamdaoui <yann.hamdaoui@gmail.com> * Modify subsumption function to clone less --------- Co-authored-by: Yann Hamdaoui <yann.hamdaoui@gmail.com>
- Loading branch information
Showing
2 changed files
with
73 additions
and
33 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
7 changes: 7 additions & 0 deletions
7
core/tests/integration/inputs/typecheck/dictionary_subtyping.ncl
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,7 @@ | ||
# test.type = 'pass' | ||
let test : _ = | ||
let test_func : {_ : {_ : Number}} -> {_ : {_ : Number}} = fun a => a in | ||
test_func {a = {foo = 5}} | ||
in | ||
true | ||
|