-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
RA22-015: Fix resolution of calls to non statically resolvable fns
- Loading branch information
1 parent
da65c32
commit f8264d9
Showing
4 changed files
with
48 additions
and
0 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
4 changes: 4 additions & 0 deletions
4
testsuite/tests/contrib/lkt_semantic/call_non_static_decl/test.lkt
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,4 @@ | ||
# Call a non static declaration | ||
|
||
val a: (Int) -> Int = null | ||
val b: Int = a(12) |
26 changes: 26 additions & 0 deletions
26
testsuite/tests/contrib/lkt_semantic/call_non_static_decl/test.out
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,26 @@ | ||
Resolving test.lkt | ||
================== | ||
Id <RefId "Int" test.lkt:3:9-3:12> | ||
references <StructDecl prelude: "Int"> | ||
|
||
Id <RefId "Int" test.lkt:3:17-3:20> | ||
references <StructDecl prelude: "Int"> | ||
|
||
Expr <NullLit test.lkt:3:23-3:27> | ||
has type <FunctionType prelude: "(Int) -> Int"> | ||
|
||
Id <RefId "Int" test.lkt:4:8-4:11> | ||
references <StructDecl prelude: "Int"> | ||
|
||
Id <RefId "a" test.lkt:4:14-4:15> | ||
references <ValDecl "a" test.lkt:3:1-3:27> | ||
|
||
Expr <RefId "a" test.lkt:4:14-4:15> | ||
has type <FunctionType prelude: "(Int) -> Int"> | ||
|
||
Expr <NumLit test.lkt:4:16-4:18> | ||
has type <StructDecl prelude: "Int"> | ||
|
||
Expr <CallExpr test.lkt:4:14-4:19> | ||
has type <StructDecl prelude: "Int"> | ||
|
1 change: 1 addition & 0 deletions
1
testsuite/tests/contrib/lkt_semantic/call_non_static_decl/test.yaml
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 @@ | ||
driver: lkt |