From 95d82a91c20778e9bb5c013fb482e195d280c531 Mon Sep 17 00:00:00 2001 From: Camden Dixie O'Brien Date: Sat, 28 Feb 2026 13:10:05 +0000 Subject: [PATCH] Indent loops, ifs etc --- wipforth.wat | 50 +++++++++++++++++++++++++------------------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/wipforth.wat b/wipforth.wat index 996050a..6c7d2fc 100644 --- a/wipforth.wat +++ b/wipforth.wat @@ -586,13 +586,13 @@ (func $key (local $head i32) ;; Wait for RXBUF to be non-empty loop $wait - global.get $RXHEAD - i32.atomic.load8_u - local.tee $head - global.get $RXTAIL - i32.atomic.load8_u - i32.eq - br_if $wait + global.get $RXHEAD + i32.atomic.load8_u + local.tee $head + global.get $RXTAIL + i32.atomic.load8_u + i32.eq + br_if $wait end ;; Read byte at head position @@ -616,18 +616,18 @@ (func $emit (local $tail i32) (local $next i32) ;; Wait for TXBUF to be non-full loop $wait - global.get $TXTAIL - i32.atomic.load8_u - local.tee $tail - i32.const 1 - i32.add - i32.const 0x1f - i32.and - local.tee $next - global.get $TXHEAD - i32.atomic.load8_u - i32.eq - br_if $wait + global.get $TXTAIL + i32.atomic.load8_u + local.tee $tail + i32.const 1 + i32.add + i32.const 0x1f + i32.and + local.tee $next + global.get $TXHEAD + i32.atomic.load8_u + i32.eq + br_if $wait end ;; Write byte at tail position @@ -657,10 +657,10 @@ (func $zbranch call $pop if (result i32) - i32.const 4 + i32.const 4 else - global.get $ip - i32.load + global.get $ip + i32.load end global.get $ip i32.add @@ -1685,9 +1685,9 @@ (func $trampoline loop $loop - global.get $fn - call_indirect (type $codeword) - br $loop + global.get $fn + call_indirect (type $codeword) + br $loop end) (func (export "reset")