r88624 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r88623‎ | r88624 | r88625 >
Date:23:52, 22 May 2011
Author:platonides
Status:deferred
Tags:
Comment:
/* comments that should be /** heuristic.
Modified paths:
  • /trunk/tools/code-utils/check-vars.php (modified) (history)

Diff [purge]

Index: trunk/tools/code-utils/check-vars.php
@@ -322,6 +322,13 @@
323323 if ( $token == ';' )
324324 $this->mFunctionQualifiers = array();
325325
 326+ if ( $token[0] == T_COMMENT ) {
 327+ if ( substr( $token[1], 0, 2 ) == '/*' && substr( $token[1], 0, 3 ) != '/**'
 328+ && preg_match( '/^\s+\*(?!\/)/m', $token[1] ) && strpos( $token[1], "\$separatorTransformTable = array( ',' => '' )" ) === false ) {
 329+ $this->warning( "Multiline comment with /* in line $token[2]" );
 330+ }
 331+ }
 332+
326333 if ( $token[0] == T_DOC_COMMENT ) {
327334 if ( strpos( $token[1], '@deprecated' ) !== false ) {
328335 $this->mFunctionQualifiers[] = self::FUNCTION_DEPRECATED;

Status & tagging log