~jpl8/piet_interpreter

6223546a893feae0868551bffeb9b1c310e23b6d — jpl 2 years ago d2cbee3 main
Fix outnum to only emit a single byte.
1 files changed, 1 insertions(+), 6 deletions(-)

M src/interpreter/rules.rs
M src/interpreter/rules.rs => src/interpreter/rules.rs +1 -6
@@ 381,12 381,7 @@ pub fn do_op(
                    if interpreter.debug() {
                        eprintln!("Executed: OutNum({})", val);
                    }
                    let bytes = if cfg!(target_endian = "big") {
                        val.to_be_bytes()
                    } else {
                        val.to_le_bytes()
                    };
                    handle.write_all(&bytes)?;
                    handle.write_all(&[val as u8])?;
                }
                Ok(())
            }