From 618200dc4288f6ff4ee7919084034673d96b490e Mon Sep 17 00:00:00 2001 From: John Breaux Date: Thu, 1 Feb 2024 12:00:55 -0600 Subject: [PATCH] msp430-asm: Make UI a little bet prettier --- msp430-asm/src/main.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/msp430-asm/src/main.rs b/msp430-asm/src/main.rs index 910892e..2a6fefa 100644 --- a/msp430-asm/src/main.rs +++ b/msp430-asm/src/main.rs @@ -58,12 +58,12 @@ mod args { } mod repl { - //! The REPL reads a line, parses it, evaluates the line, and prints, in a loop + //! The REPL reads, evaluates, and prints in a loop use super::*; use msp430_asm::cursor::*; use std::io::{stderr, Write}; - /// Prints the line number + /// Formats the line number macro linenr($n: expr) { format_args!("{:4}: ", $n) } @@ -97,13 +97,13 @@ mod repl { line.clear(); printfl!("{}", linenr!(linenr)); } - println!("{}", fg!(Gray, "[EOF]")); + println!("{}", fg!(DarkGray, "[EOF]")); Ok(()) } /// Rewrites the line in OK format, with a green linenr fn format_ok(line: &str, linenr: i32) { - println!("{}{}{}", previous!(1), fg!(Green, "{:4}", linenr!(linenr)), line.trim_end(),); + println!("{}{}{}", previous!(1), fg!(Lime, "{:4}", linenr!(linenr)), line.trim_end(),); } /// Pretty-prints a line error