Skip to content

Commit 76d5e6b

Browse files
authored
Merge pull request #608 from ratmice/lexflags_hidden
make `LexFlags` hidden or `pub(crate)` when necessary
2 parents 93ccab2 + 2dc1ade commit 76d5e6b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lrlex/src/lib/lexer.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ impl From<&LexFlags> for Header<Location> {
171171
}
172172

173173
/// LexFlags with flags set to default values.
174+
#[doc(hidden)]
174175
pub const DEFAULT_LEX_FLAGS: LexFlags = LexFlags {
175176
allow_wholeline_comments: Some(false),
176177
dot_matches_new_line: Some(true),
@@ -186,6 +187,7 @@ pub const DEFAULT_LEX_FLAGS: LexFlags = LexFlags {
186187
nest_limit: None,
187188
};
188189

190+
#[doc(hidden)]
189191
/// LexFlags with all of the values `None`.
190192
pub const UNSPECIFIED_LEX_FLAGS: LexFlags = LexFlags {
191193
allow_wholeline_comments: None,
@@ -672,7 +674,7 @@ where
672674

673675
/// Returns the final `LexFlags` used for this lex source
674676
/// after all forced and default flags have been resolved.
675-
pub fn lex_flags(&self) -> Option<&LexFlags> {
677+
pub(crate) fn lex_flags(&self) -> Option<&LexFlags> {
676678
Some(&self.lex_flags)
677679
}
678680
}

0 commit comments

Comments
 (0)