mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-03 08:34:33 +00:00
Enumerate severity on problem variants
This commit is contained in:
parent
0a4ec1958b
commit
e438fbf37c
9 changed files with 92 additions and 74 deletions
|
@ -1,6 +1,7 @@
|
|||
use roc_module::ident::Ident;
|
||||
use roc_module::ident::{Lowercase, ModuleName, TagName, Uppercase};
|
||||
use roc_module::symbol::{Interns, ModuleId, PQModuleName, PackageQualified, Symbol};
|
||||
use roc_problem::Severity;
|
||||
use roc_region::all::LineColumnRegion;
|
||||
use std::fmt;
|
||||
use std::path::{Path, PathBuf};
|
||||
|
@ -99,18 +100,6 @@ pub fn pretty_header_with_path(title: &str, path: &Path) -> String {
|
|||
header
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
|
||||
pub enum Severity {
|
||||
/// This will cause a runtime error if some code get srun
|
||||
/// (e.g. type mismatch, naming error)
|
||||
RuntimeError,
|
||||
|
||||
/// This will never cause the code to misbehave,
|
||||
/// but should be cleaned up
|
||||
/// (e.g. unused def, unused import)
|
||||
Warning,
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
pub enum RenderTarget {
|
||||
ColorTerminal,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue