Skip to content

Commit a225580

Browse files
zahashvldm
authored andcommitted
default impl for Parser (#51)
1 parent 54c5baf commit a225580

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/parser/mod.rs

+8
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,14 @@ pub struct Parser<C> {
2525
config: ParserConfig<C>,
2626
}
2727

28+
impl Default for Parser<Infallible> {
29+
fn default() -> Self {
30+
Self {
31+
config: ParserConfig::default(),
32+
}
33+
}
34+
}
35+
2836
impl<C: CustomNode + std::fmt::Debug> Parser<C> {
2937
/// Create a new parser with the given [`ParserConfig`].
3038
pub fn new(config: ParserConfig<C>) -> Self {

0 commit comments

Comments
 (0)