Skip to content

Commit

Permalink
9396: Further cleaning up of function selector
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanmon committed Dec 5, 2024
1 parent d9ae743 commit 5959015
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -353,10 +353,6 @@ void AvmKernelTraceBuilder::op_sstore(uint32_t clk, uint32_t side_effect_counter
// dest.main_kernel_in_offset = SENDER_KERNEL_INPUTS_COL_OFFSET;
// dest.main_sel_q_kernel_lookup = 1;
// break;
// case KernelTraceOpType::FUNCTION_SELECTOR:
// dest.main_kernel_in_offset = FUNCTION_SELECTOR_KERNEL_INPUTS_COL_OFFSET;
// dest.main_sel_q_kernel_lookup = 1;
// break;
// case KernelTraceOpType::TRANSACTION_FEE:
// dest.main_kernel_in_offset = TRANSACTION_FEE_KERNEL_INPUTS_COL_OFFSET;
// dest.main_sel_q_kernel_lookup = 1;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ class AvmKernelTraceBuilder {
// IN
ADDRESS,
SENDER,
FUNCTION_SELECTOR,
TRANSACTION_FEE,
CHAIN_ID,
VERSION,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,14 @@ contract AvmTest {
get_contract_instance_initialization_hash_avm,
};
use dep::aztec::prelude::Map;
use dep::aztec::protocol_types::{
abis::function_selector::FunctionSelector, contract_class_id::ContractClassId,
storage::map::derive_storage_slot_in_map,
};
use dep::aztec::protocol_types::{
address::{AztecAddress, EthAddress},
point::Point,
scalar::Scalar,
};
use dep::aztec::protocol_types::constants::CONTRACT_INSTANCE_LENGTH;
use dep::aztec::protocol_types::{
contract_class_id::ContractClassId, storage::map::derive_storage_slot_in_map,
};
use dep::aztec::state_vars::PublicMutable;
use dep::compressed_string::CompressedString;
use std::embedded_curve_ops::{EmbeddedCurvePoint, multi_scalar_mul};
Expand Down Expand Up @@ -378,11 +376,6 @@ contract AvmTest {
context.msg_sender()
}

#[public]
fn get_function_selector() -> FunctionSelector {
context.selector()
}

#[public]
fn get_transaction_fee() -> Field {
context.transaction_fee()
Expand Down Expand Up @@ -434,14 +427,6 @@ contract AvmTest {
assert(timestamp == expected_timestamp, "timestamp does not match");
}

#[public]
fn check_selector() {
assert(
context.selector() == comptime { FunctionSelector::from_signature("check_selector()") },
"Unexpected selector!",
);
}

#[public]
fn get_args_hash(_a: u8, _fields: [Field; 3]) -> Field {
context.get_args_hash()
Expand Down Expand Up @@ -624,8 +609,6 @@ contract AvmTest {
let _ = get_address();
dep::aztec::oracle::debug_log::debug_log("get_sender");
let _ = get_sender();
dep::aztec::oracle::debug_log::debug_log("get_function_selector");
let _ = get_function_selector();
dep::aztec::oracle::debug_log::debug_log("get_transaction_fee");
let _ = get_transaction_fee();
dep::aztec::oracle::debug_log::debug_log("get_chain_id");
Expand Down

0 comments on commit 5959015

Please sign in to comment.