Page MenuHomePhorge

Linter XHPAST: fix nonsense ArcanistDoubleQuoteXHPASTLinterRule when no double quote is involved
Open, WishlistPublic

Description

For example this line will cause this lint error:

protected function canEditInlineComment(
    PhabricatorUser $viewer,
    PhabricatorInlineComment $inline) {

    // ↓ ↓ ↓ ↓ ↓ ↓ ↓
    assert($inline instanceof DifferentialInlineComment);

}

The above generates:

Lint: Unnecessary Double Quotes
String does not require double quotes. For consistency, prefer single quotes.

To reproduce, clone this:

https://we.phorge.it/D25753?id=2289

arc patch --diff 2289

and run arc lint but with XHPAST installed.