Add file name to error messages (#70) #155
No reviewers
Labels
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: M-Labs/nac3#155
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "ast_filename_location"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Add file name to error messages by adding file name to the AST.
Use
line .. column ..
format to the location inside the file.178a904c18
to9b3b47ce50
@ -65,3 +65,3 @@
);
let parser_result = parser::parse_program(&program).unwrap();
let parser_result = parser::parse_program(&program, format!("{}.py", demo_name).into()).unwrap();
nitpicking but it's using
demo_name + ".py"
above@ -101,3 +101,3 @@
exceptions::PyIOError::new_err(format!("failed to read input file: {}", e))
})?;
let parser_result = parser::parse_program(&source)
let parser_result = parser::parse_program(&source, source_file.into())
No more absolute path?
Ah,
__file__
is already absolute. OK.