Skip to content

clang-format sorts includes even in files where it should be disabled completely #27416

Closed as duplicate of#34447
@llvmbot

Description

@llvmbot
Bugzilla Link 27042
Version 11.0
OS All
Reporter LLVM Bugzilla Contributor
CC @mydeveloperday,@ptomato

Extended Description

I have the following settings for third-party code:


DisableFormat: true
...

clang-format 3.8.0 ignores this option and still sorts includes, although it's expected to be disabled completely and that it won't change files with the above settings.

Now I have to explicitly disable sorting to workaround this issue.


DisableFormat: true
SortIncludes: false
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions