Signed-off-by: xermicus <bigcyrill@hotmail.com>
This commit is contained in:
xermicus
2025-09-18 14:40:00 +02:00
parent a5fbd545c5
commit b0ad55715f
8 changed files with 96 additions and 57 deletions
+2
View File
@@ -7,3 +7,5 @@ repository.workspace = true
authors.workspace = true
description = "revive compiler rust backend runtime library"
[dependencies]
alloy-core = { workspace = true, default-features = false }
-1
View File
@@ -1 +0,0 @@
//! The revive Rust backend contract runtime library configuration.
@@ -0,0 +1,4 @@
//! The revive Rust backend contract runtime library configuration.
/// The Ethereum Virtual Machine word size in bytes.
pub const EVM_WORD_SIZE_BYTES: usize = 32;
+2 -13
View File
@@ -2,16 +2,5 @@
#![no_std]
pub const EVM_WORD_SIZE_BYTES: usize = 32;
/// The emulated linear EVM heap memory size.
pub const MEMORY_SIZE: usize = 1024 * 64;
/// The emulated linear EVM heap memory size.
pub const MEMORY: [u8; MEMORY_SIZE] = [0; MEMORY_SIZE];
pub struct Function<const VARIABLES: usize> {
pub variables: [u8; VARIABLES],
}
impl<const VARIABLES: usize> Function<VARIABLES> {}
pub mod configuration;
pub mod memory;
+13
View File
@@ -0,0 +1,13 @@
//! The revive Rust backend contract runtime emulated linear EVM heap memory.
/// The emulated linear EVM heap memory size.
pub const MEMORY_SIZE: usize = 1024 * 64;
/// The emulated linear EVM heap memory size.
pub const MEMORY: [u8; MEMORY_SIZE] = [0; MEMORY_SIZE];
pub struct Function<const VARIABLES: usize> {
pub variables: [u8; VARIABLES],
}
impl<const VARIABLES: usize> Function<VARIABLES> {}