Skip to content

Handling of trailing tabs in comments not idempotent #422

Description

@Eckaaaaaat

When formatting the following code

class Foo {
  void f() {
    int x = 0; // comment<TAB><TAB><TAB>
    return;
  }
}

where <TAB> represents ASCII 0x09 character the formatter removes the last tab character.
Thus when you apply the formatter again, it also removes the last tab.
Expected behavior would be either all trailing tabs removed or kept.

As Unicode reader discards last character if it is a whitespace preseving tabs would be difficult.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions