Skip to content

[clang-format] Changed formatting of trailing return type between version 18 and 19 #110911

@carlosgalvezp

Description

@carlosgalvezp

Hi!

We are testing bumping our clang-format installation from version 18 to 19, and notice a fair amount of churn, without changing the config file. In particular, this type of code:

auto foo(Type a, 
         Type b) -> std::enable_if<....>
{}

Gets transformed into:

auto foo(Type a, Type b) 
    -> std::enable_if<...>
{}

Do you know if there's a newly added option that controls this behavior, or what could be the reason for this change?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    clang-formatquestionA question, not bug report. Check out https://llvm.org/docs/GettingInvolved.html instead!

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions