Print parse errors with codespan-reporting
This commit is contained in:
parent
2f6911eeca
commit
badc0d7a9f
5 changed files with 150 additions and 36 deletions
|
|
@ -357,3 +357,14 @@ pub struct File {
|
|||
pub contents: String,
|
||||
pub commands: Vec<Command>,
|
||||
}
|
||||
|
||||
impl File {
|
||||
/// Create an empty dummy file. This file should only be used as a
|
||||
/// placeholder value.
|
||||
pub fn dummy() -> Self {
|
||||
Self {
|
||||
contents: String::new(),
|
||||
commands: vec![],
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue