From cbc98fa0c0cf4e5c7874602af47a0b0a21287c08 Mon Sep 17 00:00:00 2001 From: Mustdzyl Date: Tue, 25 Aug 2026 21:11:59 +0200 Subject: [PATCH] docs: fix stack comments in counter.masm get_item returns a word and set_item returns the previous value, so the documented stack effects in counter.masm were inaccurate. The other account modules in this repo already document these correctly. --- masm/accounts/counter.masm | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/masm/accounts/counter.masm b/masm/accounts/counter.masm index 8ac3bbc5..64fbf051 100644 --- a/masm/accounts/counter.masm +++ b/masm/accounts/counter.masm @@ -6,27 +6,27 @@ use miden::core::sys const COUNTER_SLOT = word("miden::tutorials::counter") #! Inputs: [] -#! Outputs: [count] +#! Outputs: [COUNT] pub proc get_count push.COUNTER_SLOT[0..2] exec.active_account::get_item - # => [count] + # => [COUNT] exec.sys::truncate_stack - # => [count] + # => [COUNT] end #! Inputs: [] -#! Outputs: [] +#! Outputs: [OLD_COUNT] pub proc increment_count push.COUNTER_SLOT[0..2] exec.active_account::get_item - # => [count] + # => [COUNT] add.1 - # => [count+1] + # => [COUNT+1] push.COUNTER_SLOT[0..2] exec.native_account::set_item - # => [] + # => [OLD_COUNT] exec.sys::truncate_stack - # => [] + # => [OLD_COUNT] end