Error Messaging Redesign
This commit contains the following: * New data types to support full tracebacks * New traceback data type used across stl and ast * Updates to tests * fixes for error messaging in sym and some stl functions
This commit is contained in:
parent
91ad4eed12
commit
789349df48
24 changed files with 837 additions and 374 deletions
|
|
@ -163,8 +163,8 @@ mod bool_lib_tests {
|
|||
eval(&doc_tree, &mut syms).unwrap();
|
||||
if let Err(s) = eval(&change_tree, &mut syms) {
|
||||
assert_eq!(
|
||||
s,
|
||||
"error in call to toggle: can only toggle a boolean".to_string()
|
||||
s.0.first().unwrap().message,
|
||||
"can only toggle a boolean".to_string()
|
||||
);
|
||||
let intermediate = *eval(&check_tree, &mut syms).unwrap();
|
||||
if let Ctr::Seg(ref s) = intermediate {
|
||||
|
|
@ -196,8 +196,8 @@ mod bool_lib_tests {
|
|||
eval(&doc_tree, &mut syms).unwrap();
|
||||
if let Err(s) = eval(&change_tree, &mut syms) {
|
||||
assert_eq!(
|
||||
s,
|
||||
"error in call to toggle: cannot toggle a function".to_string()
|
||||
s.0.first().unwrap().message,
|
||||
"cannot toggle a function".to_string()
|
||||
);
|
||||
if let Ctr::String(ref s) = *eval(&check_tree, &mut syms).unwrap() {
|
||||
assert_eq!(*s, "1".to_string());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue