summaryrefslogtreecommitdiffstats
path: root/vendor/pest_meta/src/validator.rs
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/pest_meta/src/validator.rs')
-rw-r--r--vendor/pest_meta/src/validator.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/vendor/pest_meta/src/validator.rs b/vendor/pest_meta/src/validator.rs
index cfc445f0e..d9c2ed3c5 100644
--- a/vendor/pest_meta/src/validator.rs
+++ b/vendor/pest_meta/src/validator.rs
@@ -81,7 +81,9 @@ pub fn validate_pairs(pairs: Pairs<'_, Rule>) -> Result<Vec<&str>, Vec<Error<Rul
let definitions: Vec<_> = pairs
.clone()
.filter(|pair| pair.as_rule() == Rule::grammar_rule)
- .map(|pair| pair.into_inner().next().unwrap().as_span())
+ .map(|pair| pair.into_inner().next().unwrap())
+ .filter(|pair| pair.as_rule() != Rule::line_doc)
+ .map(|pair| pair.as_span())
.collect();
let called_rules: Vec<_> = pairs