@@ -31,7 +31,7 @@ pub trait DeclarationParser<'i> {
3131 /// Parse the value of a declaration with the given `name`.
3232 ///
3333 /// Return the finished representation for the declaration
34- /// as returned by `DeclarationListParser ::next`,
34+ /// as returned by `RuleBodyParser ::next`,
3535 /// or an `Err(..)` to ignore the entire declaration as invalid.
3636 ///
3737 /// Declaration name matching should be case-insensitive in the ASCII range.
@@ -63,7 +63,7 @@ pub trait DeclarationParser<'i> {
6363///
6464/// Default implementations that reject all at-rules are provided,
6565/// so that `impl AtRuleParser<(), ()> for ... {}` can be used
66- /// for using `DeclarationListParser ` to parse a declarations list with only qualified rules.
66+ /// for using `RuleBodyParser ` to parse a declarations list with only qualified rules.
6767pub trait AtRuleParser < ' i > {
6868 /// The intermediate representation of prelude of an at-rule.
6969 type Prelude ;
@@ -121,7 +121,7 @@ pub trait AtRuleParser<'i> {
121121 /// The location passed in is source location of the start of the prelude.
122122 ///
123123 /// Return the finished representation of the at-rule
124- /// as returned by `RuleListParser ::next` or `DeclarationListParser ::next`,
124+ /// as returned by `StyleSheetParser ::next` or `RuleBodyParser ::next`,
125125 /// or an `Err(..)` to ignore the entire at-rule as invalid.
126126 ///
127127 /// This is only called when `parse_prelude` returned `WithBlock`, and a block
@@ -146,7 +146,7 @@ pub trait AtRuleParser<'i> {
146146///
147147/// Default implementations that reject all qualified rules are provided, so that
148148/// `impl QualifiedRuleParser<(), ()> for ... {}` can be used for example for using
149- /// `RuleListParser ` to parse a rule list with only at-rules (such as inside
149+ /// `StyleSheetParser ` to parse a rule list with only at-rules (such as inside
150150/// `@font-feature-values`).
151151pub trait QualifiedRuleParser < ' i > {
152152 /// The intermediate representation of a qualified rule prelude.
@@ -179,7 +179,7 @@ pub trait QualifiedRuleParser<'i> {
179179 /// The location passed in is source location of the start of the prelude.
180180 ///
181181 /// Return the finished representation of the qualified rule
182- /// as returned by `RuleListParser ::next`,
182+ /// as returned by `StyleSheetParser ::next`,
183183 /// or an `Err(..)` to ignore the entire at-rule as invalid.
184184 fn parse_block < ' t > (
185185 & mut self ,
@@ -197,7 +197,7 @@ pub trait QualifiedRuleParser<'i> {
197197pub struct RuleBodyParser < ' i , ' t , ' a , P , I , E > {
198198 /// The input given to the parser.
199199 pub input : & ' a mut Parser < ' i , ' t > ,
200- /// The parser given to `DeclarationListParser ::new`
200+ /// The parser given to `RuleBodyParser ::new`
201201 pub parser : & ' a mut P ,
202202
203203 _phantom : std:: marker:: PhantomData < ( I , E ) > ,
@@ -218,7 +218,7 @@ pub trait RuleBodyItemParser<'i, DeclOrRule, Error: 'i>:
218218}
219219
220220impl < ' i , ' t , ' a , P , I , E > RuleBodyParser < ' i , ' t , ' a , P , I , E > {
221- /// Create a new `DeclarationListParser ` for the given `input` and `parser`.
221+ /// Create a new `RuleBodyParser ` for the given `input` and `parser`.
222222 ///
223223 /// Note that all CSS declaration lists can on principle contain at-rules.
224224 /// Even if no such valid at-rule exists (yet),
@@ -230,7 +230,7 @@ impl<'i, 't, 'a, P, I, E> RuleBodyParser<'i, 't, 'a, P, I, E> {
230230 /// since `AtRuleParser` provides default implementations of its methods.
231231 ///
232232 /// The return type for finished declarations and at-rules also needs to be the same,
233- /// since `<DeclarationListParser as Iterator>::next` can return either.
233+ /// since `<RuleBodyParser as Iterator>::next` can return either.
234234 /// It could be a custom enum.
235235 pub fn new ( input : & ' a mut Parser < ' i , ' t > , parser : & ' a mut P ) -> Self {
236236 Self {
@@ -339,7 +339,7 @@ where
339339 /// implementations of their methods.
340340 ///
341341 /// The return type for finished qualified rules and at-rules also needs to be the same,
342- /// since `<RuleListParser as Iterator>::next` can return either. It could be a custom enum.
342+ /// since `<StyleSheetParser as Iterator>::next` can return either. It could be a custom enum.
343343 pub fn new ( input : & ' a mut Parser < ' i , ' t > , parser : & ' a mut P ) -> Self {
344344 Self {
345345 input,
@@ -349,7 +349,7 @@ where
349349 }
350350}
351351
352- /// `RuleListParser ` is an iterator that yields `Ok(_)` for a rule or an `Err(..)` for an invalid one.
352+ /// `StyleSheetParser ` is an iterator that yields `Ok(_)` for a rule or an `Err(..)` for an invalid one.
353353impl < ' i , R , P , E : ' i > Iterator for StyleSheetParser < ' i , ' _ , ' _ , P >
354354where
355355 P : QualifiedRuleParser < ' i , QualifiedRule = R , Error = E >
0 commit comments