light updates
This commit is contained in:
parent
50b16309a5
commit
db60214fac
|
@ -9,8 +9,7 @@ edition = "2021"
|
||||||
crate-type = ["cdylib", "rlib"]
|
crate-type = ["cdylib", "rlib"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
ariadne = { git = "https://github.com/zesterer/ariadne" }
|
chumsky = "0.10.1"
|
||||||
chumsky = { git = "https://github.com/zesterer/chumsky", features = ["label"] }
|
|
||||||
imbl = "3.0.0"
|
imbl = "3.0.0"
|
||||||
ran = "2.0.1"
|
ran = "2.0.1"
|
||||||
num-derive = "0.4.2"
|
num-derive = "0.4.2"
|
||||||
|
|
Binary file not shown.
|
@ -1,6 +1,6 @@
|
||||||
// use crate::process::{LErr, Trace};
|
// use crate::process::{LErr, Trace};
|
||||||
use crate::validator::VErr;
|
use crate::validator::VErr;
|
||||||
use ariadne::{sources, Color, Label, Report, ReportKind};
|
// use ariadne::{sources, Color, Label, Report, ReportKind};
|
||||||
|
|
||||||
// pub fn report_panic(err: LErr) {
|
// pub fn report_panic(err: LErr) {
|
||||||
// let mut srcs = HashSet::new();
|
// let mut srcs = HashSet::new();
|
||||||
|
@ -41,12 +41,15 @@ use ariadne::{sources, Color, Label, Report, ReportKind};
|
||||||
// }
|
// }
|
||||||
|
|
||||||
pub fn report_invalidation(errs: Vec<VErr>) {
|
pub fn report_invalidation(errs: Vec<VErr>) {
|
||||||
|
// for err in errs {
|
||||||
|
// Report::build(ReportKind::Error, (err.input, err.span.into_range()))
|
||||||
|
// .with_message(err.msg.to_string())
|
||||||
|
// .with_label(Label::new((err.input, err.span.into_range())).with_color(Color::Cyan))
|
||||||
|
// .finish()
|
||||||
|
// .print(sources(vec![(err.input, err.src)]))
|
||||||
|
// .unwrap();
|
||||||
|
// }
|
||||||
for err in errs {
|
for err in errs {
|
||||||
Report::build(ReportKind::Error, (err.input, err.span.into_range()))
|
println!("{}", err.msg)
|
||||||
.with_message(err.msg.to_string())
|
|
||||||
.with_label(Label::new((err.input, err.span.into_range())).with_color(Color::Cyan))
|
|
||||||
.finish()
|
|
||||||
.print(sources(vec![(err.input, err.src)]))
|
|
||||||
.unwrap();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user