Merge branch 'kn/userdiff-php'
The userdiff pattern for .php has been updated. * kn/userdiff-php: userdiff: support new keywords in PHP hunk header t4018: add missing test cases for PHP
This commit is contained in:
commit
d3f0938973
4
t/t4018/php-abstract-class
Normal file
4
t/t4018/php-abstract-class
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
abstract class RIGHT
|
||||||
|
{
|
||||||
|
const FOO = 'ChangeMe';
|
||||||
|
}
|
4
t/t4018/php-class
Normal file
4
t/t4018/php-class
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
class RIGHT
|
||||||
|
{
|
||||||
|
const FOO = 'ChangeMe';
|
||||||
|
}
|
4
t/t4018/php-final-class
Normal file
4
t/t4018/php-final-class
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
final class RIGHT
|
||||||
|
{
|
||||||
|
const FOO = 'ChangeMe';
|
||||||
|
}
|
4
t/t4018/php-function
Normal file
4
t/t4018/php-function
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
function RIGHT()
|
||||||
|
{
|
||||||
|
return 'ChangeMe';
|
||||||
|
}
|
4
t/t4018/php-interface
Normal file
4
t/t4018/php-interface
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
interface RIGHT
|
||||||
|
{
|
||||||
|
public function foo($ChangeMe);
|
||||||
|
}
|
7
t/t4018/php-method
Normal file
7
t/t4018/php-method
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
class Klass
|
||||||
|
{
|
||||||
|
public static function RIGHT()
|
||||||
|
{
|
||||||
|
return 'ChangeMe';
|
||||||
|
}
|
||||||
|
}
|
7
t/t4018/php-trait
Normal file
7
t/t4018/php-trait
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
trait RIGHT
|
||||||
|
{
|
||||||
|
public function foo($ChangeMe)
|
||||||
|
{
|
||||||
|
return 'foo';
|
||||||
|
}
|
||||||
|
}
|
@ -114,7 +114,7 @@ PATTERNS("perl",
|
|||||||
"|<<|<>|<=>|>>"),
|
"|<<|<>|<=>|>>"),
|
||||||
PATTERNS("php",
|
PATTERNS("php",
|
||||||
"^[\t ]*(((public|protected|private|static)[\t ]+)*function.*)$\n"
|
"^[\t ]*(((public|protected|private|static)[\t ]+)*function.*)$\n"
|
||||||
"^[\t ]*(class.*)$",
|
"^[\t ]*((((final|abstract)[\t ]+)?class|interface|trait).*)$",
|
||||||
/* -- */
|
/* -- */
|
||||||
"[a-zA-Z_][a-zA-Z0-9_]*"
|
"[a-zA-Z_][a-zA-Z0-9_]*"
|
||||||
"|[-+0-9.e]+|0[xXbB]?[0-9a-fA-F]+"
|
"|[-+0-9.e]+|0[xXbB]?[0-9a-fA-F]+"
|
||||||
|
Loading…
Reference in New Issue
Block a user