-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: enhance runtime type cast and check for lambda arguments and re…
…turn values (#1529) Signed-off-by: peefy <[email protected]>
- Loading branch information
Showing
9 changed files
with
132 additions
and
21 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
11 changes: 11 additions & 0 deletions
11
test/grammar/schema/type_annotation/type_annotation_schema_2/main.k
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,11 @@ | ||
schema ProviderFamily: | ||
version: str | ||
marketplace: bool = True | ||
|
||
providerFamily = lambda family: ProviderFamily -> ProviderFamily { | ||
family | ||
} | ||
|
||
v = providerFamily({ | ||
version: "1.6.0" | ||
}) |
3 changes: 3 additions & 0 deletions
3
test/grammar/schema/type_annotation/type_annotation_schema_2/stdout.golden
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,3 @@ | ||
v: | ||
version: '1.6.0' | ||
marketplace: true |
11 changes: 11 additions & 0 deletions
11
test/grammar/schema/type_annotation/type_annotation_schema_3/main.k
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,11 @@ | ||
schema ProviderFamily: | ||
version: str | ||
marketplace: bool = True | ||
|
||
providerFamily = lambda -> ProviderFamily { | ||
{ | ||
version: "1.6.0" | ||
} | ||
} | ||
|
||
v = providerFamily() |
3 changes: 3 additions & 0 deletions
3
test/grammar/schema/type_annotation/type_annotation_schema_3/stdout.golden
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,3 @@ | ||
v: | ||
version: '1.6.0' | ||
marketplace: true |