-
Notifications
You must be signed in to change notification settings - Fork 244
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Allow resolved types in constructors (#7223)
- Loading branch information
Showing
6 changed files
with
78 additions
and
34 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
6 changes: 6 additions & 0 deletions
6
test_programs/compile_success_empty/resolved_type_in_constructor/Nargo.toml
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,6 @@ | ||
[package] | ||
name = "resolved_type_in_constructor" | ||
type = "bin" | ||
authors = [""] | ||
|
||
[dependencies] |
10 changes: 10 additions & 0 deletions
10
test_programs/compile_success_empty/resolved_type_in_constructor/src/main.nr
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 @@ | ||
fn main() { | ||
let _ = my_macro!(); | ||
} | ||
|
||
comptime fn my_macro() -> Quoted { | ||
let typ = quote { Foo }.as_type(); | ||
quote [$typ {}] | ||
} | ||
|
||
struct Foo {} |
6d319af
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark 'Test Suite Duration'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
1.20
.noir-lang_noir_string_search_
1
s0
s+∞
AztecProtocol_aztec-packages_noir-projects_noir-protocol-circuits_crates_parity-lib
3
s2
s1.50
This comment was automatically generated by workflow using github-action-benchmark.
CC: @TomAFrench
6d319af
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark 'Test Suite Duration'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
1.20
.noir-lang_eddsa_
2
s1
s2
AztecProtocol_aztec-packages_noir-projects_noir-protocol-circuits_crates_parity-lib
3
s2
s1.50
This comment was automatically generated by workflow using github-action-benchmark.
CC: @TomAFrench