Merge pull request #65 from wendajiang/typo

fix: typo
This commit is contained in:
dalance 2022-10-19 16:41:15 +09:00 committed by GitHub
commit 6c28a6157d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 2 deletions

2
.gitignore vendored
View File

@ -2,3 +2,5 @@
*/target */target
**/*.rs.bk **/*.rs.bk
Cargo.lock Cargo.lock
.idea
.vscode

View File

@ -17,7 +17,7 @@ fn main() {
let result = parse_sv(&path, &defines, &includes, false, false); let result = parse_sv(&path, &defines, &includes, false, false);
if let Ok((syntax_tree, _)) = result { if let Ok((syntax_tree, _)) = result {
// &SyntexTree is iterable // &SyntaxTree is iterable
for node in &syntax_tree { for node in &syntax_tree {
// The type of each node is RefNode // The type of each node is RefNode
match node { match node {

View File

@ -93,7 +93,7 @@ fn main() {
print_parse_error(&origin_path, &origin_pos); print_parse_error(&origin_path, &origin_pos);
} }
x => { x => {
println!("parse failed: {:?} ({})", path, x); println!("parse failed: {:?} ({:?})", path, x);
let mut err = x.source(); let mut err = x.source();
while let Some(x) = err { while let Some(x) = err {
println!(" Caused by {}", x); println!(" Caused by {}", x);