Skip to content

extraneous spaces in multi-word function not stripped #188

@RuijieYu

Description

@RuijieYu

Describe the bug

A clear and concise description of what the bug is.

Given that "error make" is a multi-word function:

error make {msg: "hello"}

Steps To Reproduce

Steps to reproduce the behavior:

  1. Make a file as above, format it using nufmt

Expected behavior

Expect to remove the one extra space in "error make".

Environment

  • nufmt commit: latest main at d7e75a5

Please run rustc --version and paste the result.

[user@system:~]$ rustc --version
rustc 1.94.0 (4a4ef493e 2026-03-02)

Notify maintainers

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions