mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-04 20:28:02 +00:00
formatting & clippy
This commit is contained in:
parent
adc97a0099
commit
6a47a99114
2 changed files with 13 additions and 5 deletions
|
@ -8,8 +8,10 @@ use roc_load::MonomorphizedModule;
|
|||
use roc_mono::ir::OptLevel;
|
||||
use roc_repl_eval::gen::Problems;
|
||||
use roc_repl_ui::repl_state::{ReplAction, ReplState};
|
||||
use roc_repl_ui::{is_incomplete, format_output, CONT_PROMPT, PROMPT, SHORT_INSTRUCTIONS, TIPS, WELCOME_MESSAGE};
|
||||
use roc_reporting::report::{DEFAULT_PALETTE, ANSI_STYLE_CODES};
|
||||
use roc_repl_ui::{
|
||||
format_output, is_incomplete, CONT_PROMPT, PROMPT, SHORT_INSTRUCTIONS, TIPS, WELCOME_MESSAGE,
|
||||
};
|
||||
use roc_reporting::report::{ANSI_STYLE_CODES, DEFAULT_PALETTE};
|
||||
use roc_target::TargetInfo;
|
||||
use rustyline::highlight::{Highlighter, PromptInfo};
|
||||
use rustyline::validate::{self, ValidationContext, ValidationResult, Validator};
|
||||
|
@ -103,7 +105,13 @@ pub fn evaluate(
|
|||
dimensions: Option<(usize, usize)>,
|
||||
) -> String {
|
||||
let opt_output = opt_mono.and_then(|mono| eval_llvm(mono, target, OptLevel::Normal));
|
||||
format_output(ANSI_STYLE_CODES, opt_output, problems, opt_var_name, dimensions)
|
||||
format_output(
|
||||
ANSI_STYLE_CODES,
|
||||
opt_output,
|
||||
problems,
|
||||
opt_var_name,
|
||||
dimensions,
|
||||
)
|
||||
}
|
||||
|
||||
#[derive(Default)]
|
||||
|
|
|
@ -151,7 +151,7 @@ fn complete(input: &str, state: &mut ReplState, expected_start: &str, expected_e
|
|||
);
|
||||
}
|
||||
_ => {
|
||||
assert!(false, "Unexpected action: {:?}", action);
|
||||
panic!("Unexpected action: {:?}", action);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -190,7 +190,7 @@ fn error(input: &str, state: &mut ReplState, expected_step_result: String) {
|
|||
assert_eq!(expected_step_result, escaped);
|
||||
}
|
||||
_ => {
|
||||
assert!(false, "Unexpected action: {:?}", action);
|
||||
panic!("Unexpected action: {:?}", action);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue