diff --git a/circuits/cpp/src/aztec3/circuits/abis/private_circuit_public_inputs.hpp b/circuits/cpp/src/aztec3/circuits/abis/private_circuit_public_inputs.hpp index 7e7bff8cdd0..b216cd17529 100644 --- a/circuits/cpp/src/aztec3/circuits/abis/private_circuit_public_inputs.hpp +++ b/circuits/cpp/src/aztec3/circuits/abis/private_circuit_public_inputs.hpp @@ -274,9 +274,9 @@ template class OptionalPrivateCircuitPublicInputs { chain_id, version); - OptionalPrivateCircuitPublicInputs() = default; + OptionalPrivateCircuitPublicInputs() = default; - OptionalPrivateCircuitPublicInputs( + OptionalPrivateCircuitPublicInputs( std::optional> const& call_context, opt_fr const& args_hash, diff --git a/circuits/cpp/src/aztec3/circuits/abis/public_circuit_public_inputs.hpp b/circuits/cpp/src/aztec3/circuits/abis/public_circuit_public_inputs.hpp index 863292fd208..0784704c192 100644 --- a/circuits/cpp/src/aztec3/circuits/abis/public_circuit_public_inputs.hpp +++ b/circuits/cpp/src/aztec3/circuits/abis/public_circuit_public_inputs.hpp @@ -45,7 +45,7 @@ template struct PublicCircuitPublicInputs { HistoricBlockData historic_block_data{}; - address prover_address; + address prover_address{}; // for serialization, update with new fields MSGPACK_FIELDS(call_context, diff --git a/circuits/cpp/src/aztec3/circuits/abis/rollup/root/root_rollup_public_inputs.hpp b/circuits/cpp/src/aztec3/circuits/abis/rollup/root/root_rollup_public_inputs.hpp index a709b025c51..96603192162 100644 --- a/circuits/cpp/src/aztec3/circuits/abis/rollup/root/root_rollup_public_inputs.hpp +++ b/circuits/cpp/src/aztec3/circuits/abis/rollup/root/root_rollup_public_inputs.hpp @@ -18,39 +18,39 @@ template struct RootRollupPublicInputs { using AggregationObject = typename NCT::AggregationObject; // All below are shared between the base and merge rollups - AggregationObject end_aggregation_object; + AggregationObject end_aggregation_object{}; - GlobalVariables global_variables; + GlobalVariables global_variables{}; - AppendOnlyTreeSnapshot start_private_data_tree_snapshot; - AppendOnlyTreeSnapshot end_private_data_tree_snapshot; + AppendOnlyTreeSnapshot start_private_data_tree_snapshot{}; + AppendOnlyTreeSnapshot end_private_data_tree_snapshot{}; - AppendOnlyTreeSnapshot start_nullifier_tree_snapshot; - AppendOnlyTreeSnapshot end_nullifier_tree_snapshot; + AppendOnlyTreeSnapshot start_nullifier_tree_snapshot{}; + AppendOnlyTreeSnapshot end_nullifier_tree_snapshot{}; - AppendOnlyTreeSnapshot start_contract_tree_snapshot; - AppendOnlyTreeSnapshot end_contract_tree_snapshot; + AppendOnlyTreeSnapshot start_contract_tree_snapshot{}; + AppendOnlyTreeSnapshot end_contract_tree_snapshot{}; - fr start_public_data_tree_root; - fr end_public_data_tree_root; + fr start_public_data_tree_root{}; + fr end_public_data_tree_root{}; - AppendOnlyTreeSnapshot start_tree_of_historic_private_data_tree_roots_snapshot; - AppendOnlyTreeSnapshot end_tree_of_historic_private_data_tree_roots_snapshot; + AppendOnlyTreeSnapshot start_tree_of_historic_private_data_tree_roots_snapshot{}; + AppendOnlyTreeSnapshot end_tree_of_historic_private_data_tree_roots_snapshot{}; - AppendOnlyTreeSnapshot start_tree_of_historic_contract_tree_roots_snapshot; - AppendOnlyTreeSnapshot end_tree_of_historic_contract_tree_roots_snapshot; + AppendOnlyTreeSnapshot start_tree_of_historic_contract_tree_roots_snapshot{}; + AppendOnlyTreeSnapshot end_tree_of_historic_contract_tree_roots_snapshot{}; - AppendOnlyTreeSnapshot start_l1_to_l2_messages_tree_snapshot; - AppendOnlyTreeSnapshot end_l1_to_l2_messages_tree_snapshot; + AppendOnlyTreeSnapshot start_l1_to_l2_messages_tree_snapshot{}; + AppendOnlyTreeSnapshot end_l1_to_l2_messages_tree_snapshot{}; - AppendOnlyTreeSnapshot start_tree_of_historic_l1_to_l2_messages_tree_roots_snapshot; - AppendOnlyTreeSnapshot end_tree_of_historic_l1_to_l2_messages_tree_roots_snapshot; + AppendOnlyTreeSnapshot start_tree_of_historic_l1_to_l2_messages_tree_roots_snapshot{}; + AppendOnlyTreeSnapshot end_tree_of_historic_l1_to_l2_messages_tree_roots_snapshot{}; - AppendOnlyTreeSnapshot start_historic_blocks_tree_snapshot; - AppendOnlyTreeSnapshot end_historic_blocks_tree_snapshot; + AppendOnlyTreeSnapshot start_historic_blocks_tree_snapshot{}; + AppendOnlyTreeSnapshot end_historic_blocks_tree_snapshot{}; - std::array calldata_hash; - std::array l1_to_l2_messages_hash; + std::array calldata_hash{}; + std::array l1_to_l2_messages_hash{}; // For serialization, update with new fields MSGPACK_FIELDS(end_aggregation_object, diff --git a/circuits/cpp/src/aztec3/circuits/apps/function_execution_context.hpp b/circuits/cpp/src/aztec3/circuits/apps/function_execution_context.hpp index 766bb47cae9..ad1b597f4ba 100644 --- a/circuits/cpp/src/aztec3/circuits/apps/function_execution_context.hpp +++ b/circuits/cpp/src/aztec3/circuits/apps/function_execution_context.hpp @@ -70,7 +70,7 @@ template class FunctionExecutionContext { bool is_finalised = false; public: - FunctionExecutionContext(Builder& builder, OracleWrapperInterface& oracle) + FunctionExecutionContext(Builder& builder, OracleWrapperInterface& oracle) : builder(builder) , oracle(oracle) , private_circuit_public_inputs(OptionalPrivateCircuitPublicInputs::create()) @@ -332,4 +332,4 @@ template class FunctionExecutionContext { } }; -} // namespace aztec3::circuits::apps \ No newline at end of file +} // namespace aztec3::circuits::apps diff --git a/circuits/cpp/src/aztec3/circuits/hash.hpp b/circuits/cpp/src/aztec3/circuits/hash.hpp index 92f3c1a79f7..4c5141ddf91 100644 --- a/circuits/cpp/src/aztec3/circuits/hash.hpp +++ b/circuits/cpp/src/aztec3/circuits/hash.hpp @@ -442,9 +442,9 @@ template std::array accu // Generate a 512 bit input from right and left 256 bit hashes constexpr auto num_bytes = 2 * 32; std::array hash_input_bytes; - for (uint8_t i = 0; i < 4; i++) { + for (size_t i = 0; i < 4; i++) { auto half = hashes[i].to_buffer(); - for (uint8_t j = 0; j < 16; j++) { + for (size_t j = 0; j < 16; j++) { hash_input_bytes[i * 16 + j] = half[16 + j]; } }