Skip to content

Commit

Permalink
updated snap
Browse files Browse the repository at this point in the history
  • Loading branch information
benesjan committed Dec 8, 2023
1 parent 655920b commit b60e7fa
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions yarn-project/noir-compiler/src/__snapshots__/index.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -240,17 +240,21 @@ exports[`noir-compiler using wasm binary generates Aztec.nr external interface 1
use dep::std;
use dep::aztec::context::{ PrivateContext, PublicContext };
use dep::protocol_types::constants::RETURN_VALUES_LENGTH;
use dep::protocol_types::{
address::AztecAddress,
abis::function_selector::FunctionSelector,
constants::RETURN_VALUES_LENGTH,
};
// Interface for calling TestContract functions from a private context
struct TestContractPrivateContextInterface {
address: Field,
address: AztecAddress,
}
impl TestContractPrivateContextInterface {
pub fn at(address: Field) -> Self {
pub fn at(address: AztecAddress) -> Self {
Self {
address,
}
Expand All @@ -262,7 +266,7 @@ impl TestContractPrivateContextInterface {
) {
let mut serialized_args = [0; 0];
context.call_public_function(self.address, 0x46be982e, serialized_args)
context.call_public_function(self.address, FunctionSelector::from_field(0x46be982e), serialized_args)
}
}
Expand All @@ -272,11 +276,11 @@ impl TestContractPrivateContextInterface {
// Interface for calling TestContract functions from a public context
struct TestContractPublicContextInterface {
address: Field,
address: AztecAddress,
}
impl TestContractPublicContextInterface {
pub fn at(address: Field) -> Self {
pub fn at(address: AztecAddress) -> Self {
Self {
address,
}
Expand All @@ -288,7 +292,7 @@ impl TestContractPublicContextInterface {
) -> [Field; RETURN_VALUES_LENGTH] {
let mut serialized_args = [0; 0];
context.call_public_function(self.address, 0x46be982e, serialized_args)
context.call_public_function(self.address, FunctionSelector::from_field(0x46be982e), serialized_args)
}
}
Expand Down Expand Up @@ -316,6 +320,7 @@ import {
EthAddressLike,
FieldLike,
Fr,
FunctionSelectorLike,
Point,
PublicKey,
Wallet,
Expand Down

0 comments on commit b60e7fa

Please sign in to comment.