Bug #19699 [Csd]: Generic.Files.LineLength giving false positives when tab-width is used

From: Date: Mon, 12 Nov 2012 11:31:57 +0000
Subject: Bug #19699 [Csd]: Generic.Files.LineLength giving false positives when tab-width is used
References: 1  Groups: php.pear.bugs 
Request: Send a blank email to pear-bugs+get-9331@lists.php.net to get a copy of this message
Edit report at https://pear.php.net/bugs/bug.php?id=19699&edit=1 ID: 19699 Updated by: pear@kennel17.co.uk Reported By: pear at kennel17 dot co dot uk Summary: Generic.Files.LineLength giving false positives when tab-width is used Status: Closed Type: Bug Package: PHP_CodeSniffer Operating System: All Package Version: 1.4.2 PHP Version: Irrelevant Assigned To: squiz Roadmap Versions: New Comment: Oh well - fair enough. Thanks for the fix. Previous Comments: ------------------------------------------------------------------------ [2012-11-11 23:59:38] squiz I dont have the ability to test things that vary the command line settings yet. It is a limitation in my testing system. ------------------------------------------------------------------------ [2012-11-11 23:11:17] happydog PS - Might it be worth adding my test case to your unit tests? ------------------------------------------------------------------------ [2012-11-11 23:08:57] happydog Fantastic - once again impressed by the speed of resolution! Plus - it's always good to see a bugfix that involves code being removed, rather than added. :-) ------------------------------------------------------------------------ [2012-11-11 22:17:26] squiz -Status: Assigned +Status: Closed Thanks for the detailed test case and output. It made testing very easy. The problem was with PHP_CodeSniffer's conversion of tabs to spaces for calculating column numbers. I've committed a fix to the github repo: https://github.com/squizlabs/PHP_CodeSniffer/commit/dcf61b5f3feb677f190f5b0bbea c246533045c3b ------------------------------------------------------------------------ [2012-11-11 22:15:06] squiz -Summary: Generic.Files.LineLength giving false positives. +Summary: Generic.Files.LineLength giving false positives when tab-width is used ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://pear.php.net/bugs/bug.php?id=19699 -- Edit this bug report at https://pear.php.net/bugs/bug.php?id=19699&edit=1

« previous php.pear.bugs (#9331) next »