File tree 2 files changed +9
-9
lines changed
2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -19,25 +19,25 @@ use thiserror::Error;
19
19
pub use crate :: front:: wgsl:: error:: ParseError ;
20
20
use crate :: front:: wgsl:: lower:: Lowerer ;
21
21
use crate :: Scalar ;
22
- pub use parse:: ParserOptions ;
22
+ pub use parse:: Options ;
23
23
24
24
pub use crate :: front:: wgsl:: parse:: directive:: language_extension:: {
25
25
ImplementedLanguageExtension , LanguageExtension , UnimplementedLanguageExtension ,
26
26
} ;
27
27
28
28
pub struct Frontend {
29
29
parser : Parser ,
30
- options : ParserOptions ,
30
+ options : Options ,
31
31
}
32
32
33
33
impl Frontend {
34
34
pub const fn new ( ) -> Self {
35
35
Self {
36
36
parser : Parser :: new ( ) ,
37
- options : ParserOptions :: new ( ) ,
37
+ options : Options :: new ( ) ,
38
38
}
39
39
}
40
- pub const fn new_with_options ( options : ParserOptions ) -> Self {
40
+ pub const fn new_with_options ( options : Options ) -> Self {
41
41
Self {
42
42
parser : Parser :: new ( ) ,
43
43
options,
Original file line number Diff line number Diff line change @@ -262,15 +262,15 @@ impl<'a> BindingParser<'a> {
262
262
}
263
263
264
264
/// Configuration for the whole parser run.
265
- pub struct ParserOptions {
265
+ pub struct Options {
266
266
/// Controls whether the parser should parse comments.
267
267
pub parse_comments : bool ,
268
268
}
269
269
270
- impl ParserOptions {
271
- /// Creates a new `ParserOptions` with default settings .
270
+ impl Options {
271
+ /// Creates a new `ParserOptions` without comments parsing .
272
272
pub const fn new ( ) -> Self {
273
- ParserOptions {
273
+ Options {
274
274
parse_comments : false ,
275
275
}
276
276
}
@@ -2842,7 +2842,7 @@ impl Parser {
2842
2842
pub fn parse < ' a > (
2843
2843
& mut self ,
2844
2844
source : & ' a str ,
2845
- options : & ParserOptions ,
2845
+ options : & Options ,
2846
2846
) -> Result < ast:: TranslationUnit < ' a > , Error < ' a > > {
2847
2847
self . reset ( ) ;
2848
2848
You can’t perform that action at this time.
0 commit comments