-
Notifications
You must be signed in to change notification settings - Fork 495
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4a674b5
commit 42020d5
Showing
16 changed files
with
340 additions
and
120 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,3 +15,4 @@ use range::RangeOp; | |
|
||
mod function; | ||
pub use function::FnOnce; | ||
pub use function::Fn; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -272,12 +272,13 @@ blk0 (root): | |
Statements: | ||
(v0: core::felt252) <- 8 | ||
(v1: {[email protected]:3:13: 3:16}) <- struct_construct(v0{`x`}) | ||
(v2: core::felt252) <- 2 | ||
(v3: (core::felt252,)) <- struct_construct(v2{`2`}) | ||
(v4: core::felt252) <- Generated core::ops::function::FnOnce::<{[email protected]:3:13: 3:16}, (core::felt252,)>::call(v1{`c`}, v3{`c(2)`}) | ||
(v5: core::felt252) <- core::Felt252Add::add(v4{`y`}, v0{`x`}) | ||
(v2: {[email protected]:3:13: 3:16}, v3: @{[email protected]:3:13: 3:16}) <- snapshot(v1{`c`}) | ||
(v4: core::felt252) <- 2 | ||
(v5: (core::felt252,)) <- struct_construct(v4{`2`}) | ||
(v6: core::felt252) <- Generated core::ops::function::Fn::<{[email protected]:3:13: 3:16}, (core::felt252,)>::call(v3{`c`}, v5{`c(2)`}) | ||
(v7: core::felt252) <- core::Felt252Add::add(v6{`y`}, v0{`x`}) | ||
End: | ||
Return(v5) | ||
Return(v7) | ||
|
||
//! > ========================================================================== | ||
|
||
|
@@ -314,15 +315,16 @@ Statements: | |
(v3: core::array::Array::<core::felt252>, v2: ()) <- core::array::ArrayImpl::<core::felt252>::append(v0{`__array_builder_macro_result__`}, v1{`99_felt252`}) | ||
(v4: core::array::Array::<core::felt252>, v5: @core::array::Array::<core::felt252>) <- snapshot(v3{`x`}) | ||
(v6: {[email protected]:3:13: 3:16}) <- struct_construct(v5{`|a| { (@x).len() * (a + 3) }`}) | ||
(v7: core::integer::u32) <- 2 | ||
(v8: (core::integer::u32,)) <- struct_construct(v7{`2`}) | ||
(v9: core::integer::u32) <- Generated core::ops::function::FnOnce::<{[email protected]:3:13: 3:16}, (core::integer::u32,)>::call(v6{`c`}, v8{`c(2)`}) | ||
(v10: core::array::Array::<core::felt252>, v11: @core::array::Array::<core::felt252>) <- snapshot(v4{`x`}) | ||
(v12: core::integer::u32) <- 0 | ||
(v13: @core::felt252) <- core::ops::index::DeprecatedIndexViewImpl::<core::array::Array::<core::felt252>, core::integer::u32, @core::felt252, core::array::ArrayIndex::<core::felt252>>::index(v11{`x`}, v12{`0`}) | ||
(v14: core::felt252) <- desnap(v13{`0`}) | ||
(v7: {[email protected]:3:13: 3:16}, v8: @{[email protected]:3:13: 3:16}) <- snapshot(v6{`c`}) | ||
(v9: core::integer::u32) <- 2 | ||
(v10: (core::integer::u32,)) <- struct_construct(v9{`2`}) | ||
(v11: core::integer::u32) <- Generated core::ops::function::Fn::<{[email protected]:3:13: 3:16}, (core::integer::u32,)>::call(v8{`c`}, v10{`c(2)`}) | ||
(v12: core::array::Array::<core::felt252>, v13: @core::array::Array::<core::felt252>) <- snapshot(v4{`x`}) | ||
(v14: core::integer::u32) <- 0 | ||
(v15: @core::felt252) <- core::ops::index::DeprecatedIndexViewImpl::<core::array::Array::<core::felt252>, core::integer::u32, @core::felt252, core::array::ArrayIndex::<core::felt252>>::index(v13{`x`}, v14{`0`}) | ||
(v16: core::felt252) <- desnap(v15{`0`}) | ||
End: | ||
Return(v14) | ||
Return(v16) | ||
|
||
//! > ========================================================================== | ||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -277,23 +277,25 @@ End: | |
Return() | ||
|
||
|
||
Generated core::ops::function::FnOnce::call lowering for source location: | ||
Generated core::ops::function::Fn::call lowering for source location: | ||
let c = || a; | ||
^^ | ||
|
||
Parameters: v0: {[email protected]:6:14: 6:16}, v1: () | ||
Parameters: v0: @{[email protected]:6:14: 6:16}, v2: () | ||
blk0 (root): | ||
Statements: | ||
(v2: core::integer::u32) <- struct_destructure(v0) | ||
() <- struct_destructure(v1) | ||
(v1: {[email protected]:6:14: 6:16}) <- desnap(v0) | ||
(v3: core::integer::u32) <- struct_destructure(v1) | ||
() <- struct_destructure(v2) | ||
End: | ||
Return(v2) | ||
Return(v3) | ||
|
||
|
||
Final lowering: | ||
Parameters: v0: {[email protected]:6:14: 6:16}, v1: () | ||
Parameters: v0: @{[email protected]:6:14: 6:16}, v1: () | ||
blk0 (root): | ||
Statements: | ||
(v2: core::integer::u32) <- struct_destructure(v0) | ||
(v2: {[email protected]:6:14: 6:16}) <- desnap(v0) | ||
(v3: core::integer::u32) <- struct_destructure(v2) | ||
End: | ||
Return(v2) | ||
Return(v3) |
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
Oops, something went wrong.