diff --git a/solidity_contracts/src/L1L2Messaging/MessageConsumerTest.sol b/solidity_contracts/src/L1L2Messaging/MessageConsumerTest.sol index 3f6289878..55ee13d0f 100644 --- a/solidity_contracts/src/L1L2Messaging/MessageConsumerTest.sol +++ b/solidity_contracts/src/L1L2Messaging/MessageConsumerTest.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.0; -import "starknet/IStarknetMessaging.sol"; +import "../starknet/IStarknetMessaging.sol"; // Define some custom error as an example. // It saves a lot's of space to use those custom error instead of strings. diff --git a/solidity_contracts/src/L1L2Messaging/StarknetMessagingLocal.sol b/solidity_contracts/src/L1L2Messaging/StarknetMessagingLocal.sol index 51f929f18..1e5718f92 100644 --- a/solidity_contracts/src/L1L2Messaging/StarknetMessagingLocal.sol +++ b/solidity_contracts/src/L1L2Messaging/StarknetMessagingLocal.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: Apache-2.0. pragma solidity ^0.8.0; -import "starknet/StarknetMessaging.sol"; +import "../starknet/StarknetMessaging.sol"; /** @notice Interface related to local messaging for Starknet. diff --git a/lib/starknet/IStarknetMessaging.sol b/solidity_contracts/src/starknet/IStarknetMessaging.sol similarity index 100% rename from lib/starknet/IStarknetMessaging.sol rename to solidity_contracts/src/starknet/IStarknetMessaging.sol diff --git a/lib/starknet/IStarknetMessagingEvents.sol b/solidity_contracts/src/starknet/IStarknetMessagingEvents.sol similarity index 100% rename from lib/starknet/IStarknetMessagingEvents.sol rename to solidity_contracts/src/starknet/IStarknetMessagingEvents.sol diff --git a/lib/starknet/NamedStorage.sol b/solidity_contracts/src/starknet/NamedStorage.sol similarity index 100% rename from lib/starknet/NamedStorage.sol rename to solidity_contracts/src/starknet/NamedStorage.sol diff --git a/lib/starknet/StarknetMessaging.sol b/solidity_contracts/src/starknet/StarknetMessaging.sol similarity index 100% rename from lib/starknet/StarknetMessaging.sol rename to solidity_contracts/src/starknet/StarknetMessaging.sol diff --git a/src/kakarot/precompiles/kakarot_precompiles.cairo b/src/kakarot/precompiles/kakarot_precompiles.cairo index ace48a7f9..536df56f2 100644 --- a/src/kakarot/precompiles/kakarot_precompiles.cairo +++ b/src/kakarot/precompiles/kakarot_precompiles.cairo @@ -3,7 +3,6 @@ from starkware.cairo.common.cairo_builtins import HashBuiltin, BitwiseBuiltin from starkware.cairo.common.math_cmp import is_le from starkware.cairo.common.alloc import alloc -from starkware.cairo.common.bool import TRUE, FALSE from starkware.starknet.common.syscalls import call_contract, library_call from starkware.starknet.common.messages import send_message_to_l1 @@ -91,7 +90,7 @@ namespace KakarotPrecompiles { } let (revert_reason_len, revert_reason) = Errors.invalidCairoSelector(); - return (revert_reason_len, revert_reason, CAIRO_PRECOMPILE_GAS, 1); + return (revert_reason_len, revert_reason, CAIRO_PRECOMPILE_GAS, Errors.EXCEPTIONAL_HALT); } func cairo_message{ @@ -108,7 +107,7 @@ namespace KakarotPrecompiles { let is_input_invalid = is_le(input_len, 95); if (is_input_invalid != 0) { let (revert_reason_len, revert_reason) = Errors.outOfBoundsRead(); - return (revert_reason_len, revert_reason, CAIRO_MESSAGE_GAS, TRUE); + return (revert_reason_len, revert_reason, CAIRO_MESSAGE_GAS, Errors.EXCEPTIONAL_HALT); } // Input is formatted as: @@ -130,6 +129,6 @@ namespace KakarotPrecompiles { send_message_to_l1(target_address, data_words_len, data); let (output) = alloc(); - return (0, output, CAIRO_PRECOMPILE_GAS, FALSE); + return (0, output, CAIRO_PRECOMPILE_GAS, Errors.EXCEPTIONAL_HALT); } }