Skip to content

TLint and Pint disagree on empty constructor line length #189

@chrispmcgee

Description

@chrispmcgee

We have a line in our code that is 114 characters long:

    public function __construct(public readonly Load $load, public readonly ?LoadSubscriber $subscriber = null) {}

When we run Duster (duster fix), TLint automatically changes it to put the braces on separate lines (with 111 characters on the first line now):

    public function __construct(public readonly Load $load, public readonly ?LoadSubscriber $subscriber = null)
    {
    }

Later in the Duster process, when Pint reviews the files, it reverts it to a single line.

We have many other single-line constructors like the one above, but they don't change with Duster, so I can only assume that TLint and Pint disagree on line lengths for empty constructors like that. Is there a way to customize Duster so it won't keep doing this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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