diff --git a/src/lib.rs b/src/lib.rs index af026a1..fbad7fb 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,7 +1,7 @@ //! `kdl` is a "document-oriented" parser and API for the [KDL Document //! Language](https://kdl.dev), a node-based, human-friendly configuration and //! serialization format. -//! +//! //! Unlike serde-based implementations, this crate preserves formatting when //! editing, as well as when inserting or changing values with custom //! formatting. This is most useful when working with human-maintained KDL diff --git a/src/v2_parser.rs b/src/v2_parser.rs index 01f35ef..6f3a347 100644 --- a/src/v2_parser.rs +++ b/src/v2_parser.rs @@ -866,7 +866,7 @@ fn badval_ty_char(input: &mut Input<'_>) -> PResult<()> { /// `line-space := newline | ws | single-line-comment` fn line_space(input: &mut Input<'_>) -> PResult<()> { - alt((newline, ws, single_line_comment)).parse_next(input) + alt((node_space, newline, single_line_comment)).parse_next(input) } /// `node-space := ws* escline ws* | ws+`