Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closing curlies are pulled up into comments #74

Open
cfuehrmann opened this issue Jul 10, 2024 · 0 comments
Open

Closing curlies are pulled up into comments #74

cfuehrmann opened this issue Jul 10, 2024 · 0 comments

Comments

@cfuehrmann
Copy link

Consider the following kdl snippet:

xkb {
    // You can set rules, model, layout, variant and options.
    // For more information, see xkeyboard-config(7).

    // For example:
    // layout "us,ru"
    layout "de"
    variant "nodeadkeys"
    // options "grp:win_space_toggle,compose:ralt,ctrl:nocaps"
}

Applying parse followed by fmt followed by to_string yields this broken snippet:

xkb {
    // You can set rules, model, layout, variant and options.
    // For more information, see xkeyboard-config(7).
    // For example:
    // layout "us,ru"
    layout "de"
    variant "nodeadkeys"
// options "grp:win_space_toggle,compose:ralt,ctrl:nocaps"}

Note how the bracket got pulled into the comment line. (Also, a horizontal line got deleted and an indentation is wrong.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant