Skip to content

clang-format: Behavior changes between 16.0 and 17.0 #73584

@LinZhihao-723

Description

@LinZhihao-723

Hi, when I update the clang-format from v16.0 to v17.0, the behavior of the following code block changes:
Before (16.0):

    PyObjectPtr<PyObject> const readinto_method_obj{
            PyObject_GetAttrString(input_stream, "readinto")};

After (17.0):

    PyObjectPtr<PyObject> const readinto_method_obj{PyObject_GetAttrString(input_stream, "readinto")
    };

Is this an expected behavior? Is there any new settings I need to update to keep the old behavior, or at least sth like:

    PyObjectPtr<PyObject> const readinto_method_obj{
            PyObject_GetAttrString(input_stream, "readinto")
    };

Here is my clang-format config file: https://github.com/y-scope/clp-ffi-py/blob/main/.clang-format
Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions