HomePhabricator

Add a method to get the indentation for an XHPASTNode

Description

Add a method to get the indentation for an XHPASTNode

Summary: Add a getIndentation() method to XHPASTNode. This method returns the whitespace that was used to indent the node. This is useful for linter rules which enforce various alignment-related nitpicks, such as D11504: Add a linter rule for PHP indentation and D12296: Improve array comma rule.

Test Plan: See D12296.

Reviewers: Blessed Reviewers, epriestley

Reviewed By: Blessed Reviewers, epriestley

Subscribers: Korvin, epriestley

Differential Revision: https://secure.phabricator.com/D12295

Details

Provenance
joshuaspenceAuthored on
joshuaspencePushed on Apr 6 2015, 9:44 PM
Reviewer
Blessed Reviewers
Differential Revision
D12295: Add a method to get the indentation for an XHPASTNode
Parents
rPHU20aa8245ef50: Update script for compatibility with PHP CompatInfo v4.0.0
Branches
Unknown
Tags
Unknown