@PER-CS1.0.test-in.php 753 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?
  2. namespace Vendor\Package;
  3. use const BAR;
  4. use function foo;
  5. use \FooInterfaceA, FooInterfaceB;
  6. use \BarClass as Bar;
  7. use OtherVendor\OtherPackage\BazClass;
  8. class Foo extends Bar implements FooInterfaceA{
  9. var $aaa = 1, $bbb = 2;
  10. public function sampleFunction($a, $arg1, $arg2, $arg3, $foo, $b = null)
  11. {
  12. if ($a === $b) {
  13. bar();
  14. } else if ($a > $b) {
  15. $foo->bar($arg1);
  16. } else {
  17. BazClass::bar($arg2, $arg3);
  18. }
  19. STATIC::baz();
  20. }
  21. use FooTrait, BarTrait;
  22. static public final function bar() {
  23. // method body
  24. }
  25. }
  26. class Aaa implements
  27. Bbb, Ccc,
  28. Ddd
  29. {
  30. }
  31. $a = new Foo;
  32. $b = (boolean) 1;
  33. $c = true ? (INT) '1' : 2;
  34. ?>