blob: 03f453a6ef21b0f3937ec4690624bce77faf9f7b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
use crate::{SourceFile, validation, AstNode};
fn check_file_invariants(file: &SourceFile) {
let root = file.syntax();
validation::validate_block_structure(root);
let _ = file.errors();
}
pub fn check_parser(text: &str) {
let file = SourceFile::parse(text);
check_file_invariants(&file);
}
|