diff --git a/CHANGELOG.md b/CHANGELOG.md index e7c72ebe7e..ae9ee9ffec 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ #### Upcoming Changes +* feat: Make PublicInput fields public [#1474](https://github.com/lambdaclass/cairo-vm/pull/1474) + * chore: bump starknet-crypto to v0.6.1 [#1469](https://github.com/lambdaclass/cairo-vm/pull/1469) * feat: Implement the Serialize and Deserialize methods for the Program struct [#1458](https://github.com/lambdaclass/cairo-vm/pull/1458) diff --git a/vm/src/air_public_input.rs b/vm/src/air_public_input.rs index 3b909f0be5..24cd0f08af 100644 --- a/vm/src/air_public_input.rs +++ b/vm/src/air_public_input.rs @@ -16,10 +16,10 @@ use crate::{ #[derive(Serialize, Debug)] pub struct PublicMemoryEntry { - address: usize, + pub address: usize, #[serde(serialize_with = "mem_value_serde::serialize")] - value: Option, - page: usize, + pub value: Option, + pub page: usize, } mod mem_value_serde { @@ -39,9 +39,9 @@ mod mem_value_serde { } #[derive(Serialize, Debug)] -struct MemorySegmentAddresses { - begin_addr: usize, - stop_ptr: usize, +pub struct MemorySegmentAddresses { + pub begin_addr: usize, + pub stop_ptr: usize, } impl From<(usize, usize)> for MemorySegmentAddresses { @@ -56,12 +56,12 @@ impl From<(usize, usize)> for MemorySegmentAddresses { #[derive(Serialize, Debug)] pub struct PublicInput<'a> { - layout: &'a str, - rc_min: isize, - rc_max: isize, - n_steps: usize, - memory_segments: HashMap<&'a str, MemorySegmentAddresses>, - public_memory: Vec, + pub layout: &'a str, + pub rc_min: isize, + pub rc_max: isize, + pub n_steps: usize, + pub memory_segments: HashMap<&'a str, MemorySegmentAddresses>, + pub public_memory: Vec, #[serde(rename = "dynamic_params")] layout_params: Option<&'a CairoLayout>, }