repo stringlengths 7 63 | file_url stringlengths 81 284 | file_path stringlengths 5 200 | content stringlengths 0 32.8k | language stringclasses 1
value | license stringclasses 7
values | commit_sha stringlengths 40 40 | retrieved_at stringdate 2026-01-04 15:02:33 2026-01-05 05:24:06 | truncated bool 2
classes |
|---|---|---|---|---|---|---|---|---|
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/conditional/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/conditional/000.php | <?php
if (true) {
class A {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/readonly/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/readonly/001.php | <?php
final readonly class A {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/readonly/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/readonly/000.php | <?php
readonly class A {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/enum_with_string/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/enum_with_string/000.php | <?php
enum Suit: string
{
case Hearts = 'H';
case Diamonds;
case Clubs = 'C';
case Spades = 'S';
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/asymmetric_visibility/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/asymmetric_visibility/000.php | <?php
class Test
{
protected private(set) $a;
private public(set) $b;
protected(set) $c;
public function __construct(
protected private(set) $d,
private public(set) $e,
protected(set) $f,
) {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_promotion/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_promotion/000.php | <?php
class Point
{
public function __construct(
public float $x = 0.0,
protected array $y = [],
private string $z = 'hello',
public readonly int $a = 0,
public $h {
set => $value;
},
public $g = 1 {
get => 2;
},
final ... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/anonymous/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/anonymous/000.php | <?php
new class {
public function test() {}
};
new class extends A implements B, C {};
new class() {
public $foo;
};
new class($a, $b) extends A {
use T;
};
class A
{
public function test()
{
return new class($this) extends A {
const A = 'B';
};
}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/enum/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/enum/000.php | <?php
enum A
{
case class;
}
enum B implements Bar, Baz {}
enum C: int implements Bar
{
case Foo = 1;
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/class_position/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/class_position/001.php | <?php
if (1);
trait X {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/class_position/002.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/class_position/002.php | <?php
if (1);
interface X {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/class_position/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/class_position/000.php | <?php
if (1);
class C {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/typedConstants/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/typedConstants/000.php | <?php
class Test
{
const int X = 1;
private const string Y = 'a',
Z = 'b';
const array ARRAY = [];
const Foo|Bar|null FOO = null;
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/004.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/004.php | <?php class A { static function __Destruct() {} }
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/001.php | <?php class A { static function __destruct() {} }
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/002.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/002.php | <?php class A { static function __clone() {} }
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/003.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/003.php | <?php class A { static function __CONSTRUCT() {} }
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/000.php | <?php class A { static function __construct() {} }
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/005.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticMethod/005.php | <?php class A { static function __cLoNe() {} }
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/php4Style/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/php4Style/000.php | <?php
class A
{
var $foo;
function bar() {}
static abstract function baz() {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticType/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/staticType/000.php | <?php
class Test
{
public static function create(): static {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/implicitPublic/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/implicitPublic/000.php | <?php
abstract class A
{
var $a;
static $b;
abstract function c();
final function d() {}
static function e() {}
final static function f() {}
function g() {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_modifiers/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_modifiers/000.php | <?php
class Test
{
final public $prop;
abstract protected $prop;
readonly $prop;
private static $prop;
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/propertyTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/propertyTypes/000.php | <?php
class A
{
public string $a;
protected static D $b;
private ?float $c;
readonly static public ?int $d;
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/simple/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/simple/000.php | <?php
class A extends B implements C, D
{
const A = 'B',
C = 'D';
public $a = 'b',
$c = 'd';
protected $e;
private $f;
public function a() {}
public static function b($a) {}
final public function c(): B {}
protected function d() {}
private function e() {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/006.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/006.php | <?php class A implements self {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/013.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/013.php | <?php interface A extends PARENT {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/004.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/004.php | <?php class A extends PARENT {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/001.php | <?php class PARENT {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/009.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/009.php | <?php interface self {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/012.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/012.php | <?php interface A extends self {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/014.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/014.php | <?php interface A extends static {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/007.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/007.php | <?php class A implements PARENT {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/010.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/010.php | <?php interface PARENT {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/003.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/003.php | <?php class A extends self {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/008.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/008.php | <?php class A implements static {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/000.php | <?php class self {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/005.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/name/005.php | <?php class A extends static {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/001.php | <?php
class Test
{
public $prop {}
public function __construct(
public $prop2 {}
) {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/002.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/002.php | <?php
class Test
{
public $prop {
get() => 42;
}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/003.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/003.php | <?php
class Test
{
public $prop {
FOO => bar;
}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/property_hooks/000.php | <?php
class Test
{
public $prop {
get {
return 42;
}
set {
echo $value;
}
}
private $prop2 {
get => 42;
set => $value;
}
abstract $prop3 { &get; set; }
public $prop4 {
final get {
return 42;
}
... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/readonlyAnonyous/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/readonlyAnonyous/000.php | <?php
new readonly class {};
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/final/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/class/final/000.php | <?php
final class A {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/controlFlow/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/controlFlow/000.php | <?php
break;
break 2;
continue;
continue 2;
return;
return $a;
throw $e;
label:
goto label;
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/declare/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/declare/000.php | <?php
declare(X='Y');
declare(A='B',C='D') {
echo 'foo';
}
declare(A='B',C='D'):
enddeclare;
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/nullableTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/nullableTypes/000.php | <?php
function test(?Foo $bar, ?string $foo): ?Baz {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/returnTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/returnTypes/000.php | <?php
function test1() {}
function test2(): array {}
function test3(): callable {}
function test4(): Foo\Bar {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/readonlyFunction/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/readonlyFunction/000.php | <?php
function readonly() {}
readonly();
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/variadicDefaultValue/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/variadicDefaultValue/000.php | <?php
function foo(...$foo = []) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/disjointNormalFormTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/disjointNormalFormTypes/000.php | <?php
class Test
{
public (A&B)|(X&Y) $prop;
public readonly (A&B)|C $prop2;
}
function test((A&B)|(X&Y) $a): (A&B)|(X&Y) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/intersectionTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/intersectionTypes/000.php | <?php
class Test
{
public A&B $prop;
}
function test(A&B $a): A&B {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/variadic/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/variadic/000.php | <?php
function test($a, ...$b) {}
function test($a, &...$b) {}
function test($a, Type ...$b) {}
function test($a, Type &...$b) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/neverType/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/neverType/000.php | <?php
function test(): never {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/byRef/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/byRef/000.php | <?php
function a(&$b) {}
function &a($b) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/001.php | <?php
class Foo
{
function __construct(
$name,
$value,
) {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/002.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/002.php | <?php
fn(
$foo,
) => $bar;
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/000.php | <?php
function foo(
$bar,
) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/conditional/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/conditional/000.php | <?php
if (true) {
function A() {}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/004.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/004.php | <?php
function test(
bool $a1,
int $a2,
float $a3,
string $a4, // PHP 7.0
iterable $a5, // PHP 7.1
object $a6, // PHP 7.2
mixed $a7, // PHP 8.0
null $a8, // PHP 8.0
false $a9, // PHP 8.0
): void {} // PHP 7.1
function test2(): never {} // PHP 8.1
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/001.php | <?php
function test(
bool $a1,
int $a2,
float $a3,
string $a4, // PHP 7.0
iterable $a5, // PHP 7.1
object $a6, // PHP 7.2
mixed $a7, // PHP 8.0
null $a8, // PHP 8.0
false $a9, // PHP 8.0
): void {} // PHP 7.1
function test2(): never {} // PHP 8.1
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/002.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/002.php | <?php
function test(
bool $a1,
int $a2,
float $a3,
string $a4, // PHP 7.0
iterable $a5, // PHP 7.1
object $a6, // PHP 7.2
mixed $a7, // PHP 8.0
null $a8, // PHP 8.0
false $a9, // PHP 8.0
): void {} // PHP 7.1
function test2(): never {} // PHP 8.1
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/003.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/003.php | <?php
function test(
bool $a1,
int $a2,
float $a3,
string $a4, // PHP 7.0
iterable $a5, // PHP 7.1
object $a6, // PHP 7.2
mixed $a7, // PHP 8.0
null $a8, // PHP 8.0
false $a9, // PHP 8.0
): void {} // PHP 7.1
function test2(): never {} // PHP 8.1
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/000.php | <?php
function test(
bool $a1,
int $a2,
float $a3,
string $a4, // PHP 7.0
iterable $a5, // PHP 7.1
object $a6, // PHP 7.2
mixed $a7, // PHP 8.0
null $a8, // PHP 8.0
false $a9, // PHP 8.0
): void {} // PHP 7.1
function test2(): never {} // PHP 8.1
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/005.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeVersions/005.php | <?php
function test(
bool $a1,
int $a2,
float $a3,
string $a4, // PHP 7.0
iterable $a5, // PHP 7.1
object $a6, // PHP 7.2
mixed $a7, // PHP 8.0
null $a8, // PHP 8.0
false $a9, // PHP 8.0
): void {} // PHP 7.1
function test2(): never {} // PHP 8.1
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/specialVars/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/specialVars/000.php | <?php
function a()
{
global $a, ${'b'}, $$c;
static $c, $d = 'e';
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/defaultValues/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/defaultValues/000.php | <?php
function a(
$b = null,
$c = 'foo',
$d = A::B,
$f = +1,
$g = -1.0,
$h = array(),
$i = [],
$j = ['foo'],
$k = ['foo', 'bar' => 'baz']
) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/nullFalseTrueTypes/001.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/nullFalseTrueTypes/001.php | <?php
function test(): null {}
function test(): false {}
function test(): true {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/nullFalseTrueTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/nullFalseTrueTypes/000.php | <?php
function test(): null {}
function test(): false {}
function test(): true {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeDeclarations/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/typeDeclarations/000.php | <?php
function a($b, array $c, callable $d, E $f) {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/unionTypes/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/unionTypes/000.php | <?php
class Test
{
public A|iterable|null $prop;
}
function test(A|B $a): int|false {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/builtinTypeDeclarations/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/function/builtinTypeDeclarations/000.php | <?php
function test(bool $a, Int $b, FLOAT $c, StRiNg $d, iterable $e, object $f, mixed $g): void {}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/const/000.php | tests/fixtures/Formatter/out/01-default/3rdparty/php-parser/parser/stmt/const/000.php | <?php
const A = 0,
B = 1.0,
C = 'A',
D = E;
#[Example]
const WithOneAttribute = 1;
#[First]
#[Second]
const WithUngroupedAttriutes = 2;
#[First, Second]
const WithGroupAttributes = 3;
#[Example]
const ThisIsInvalid = 4,
AttributesOnMultipleConstants = 5;
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0069-ternary-coalesce.php | tests/fixtures/Formatter/in/issues/0069-ternary-coalesce.php | <?php
$threshold =
$this->UncertaintyThreshold === null
? null
: (is_array($this->UncertaintyThreshold)
? $this->UncertaintyThreshold[$algorithm] ?? null
: $this->UncertaintyThreshold);
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0060-no-blank-lines.php | tests/fixtures/Formatter/in/issues/0060-no-blank-lines.php | <?php
date_default_timezone_set("Relevant/Timezone");
global $bad_practice;
define('SOME_VAR', 42);
/**
* comment
*/
class SomeClass
{
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0195-nowdoc-with-space.php | tests/fixtures/Formatter/in/issues/0195-nowdoc-with-space.php | <?php
$str = sprintf(
<<< 'EOP'
Lorem ipsum... %1$s
EOP,
'You know'
);
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0136-improve-hanging-indentation.php | tests/fixtures/Formatter/in/issues/0136-improve-hanging-indentation.php | <?php
fn() =>
$foo
|| $bar; // Remove indentation here
$foo = bar('foo',
'bar') // Add indentation here
->baz()
->qux();
if (
$comments
&& ($prev = end($comments)) === $comment->Prev
&& $comment->line - $prev->line < 2
&& ($comment->Flags & TokenFlagMask::COMMENT_TYPE)
... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0009-align-split-assignments.php | tests/fixtures/Formatter/in/issues/0009-align-split-assignments.php | <?php
$alpha->bravo(fn($charlie) => [
'short_key' => 'value',
'very_long_key' => $charlie === SOME_CONST
? $delta : $echo,
'key' => 'value2'
]);
$foxtrot->golf(fn() => [
'key1' => $value1,
'key_two' => $value2
]);
$alpha->bravo(fn($charlie) => [
'short_key' => 'value',
'very_long_ke... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0142-increment-operator-spacing.php | tests/fixtures/Formatter/in/issues/0142-increment-operator-spacing.php | <?php
$foo->Bar++?',':'';
$foo->{'bar'}++?',':'';
Foo::$Bar++?',':'';
$foo['bar']++?',':'';
foo()++?',':'';
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0156-ternary-hanging-indent.php | tests/fixtures/Formatter/in/issues/0156-ternary-hanging-indent.php | <?php
uasort(
$members,
fn($a, $b) =>
($a->Line ?? \PHP_INT_MAX) <=> ($b->Line ?? \PHP_INT_MAX)
?: ($a->InheritedFrom[0] ?? '') <=> ($b->InheritedFrom[0] ?? '')
?: ($_a = $this->getInheritedMemberData($a, $factory))->Class->getFqcn() <=>
($_b = $this->getInherited... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0166-anonymous-functions.php | tests/fixtures/Formatter/in/issues/0166-anonymous-functions.php | <?php
function ($foo,
$bar,
$baz) use ($a,
$b,
$c) {};
// Added for completeness:
$foo = function ($bar //
) use ($baz,
$qux) {};
$foo = function ($bar
/* */) use ($baz,
$qux) {};
$foo = function ($bar,
$baz) //
use ($baz,
$qux) {};
$foo = [
10 =>
function ... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0012-else-if.php | tests/fixtures/Formatter/in/issues/0012-else-if.php | <?php
if ($a) {} else if ($b) {} else if ($c) {} else {
}
if ($a) {} else
if ($b) {} else
if ($c) {}
if ($a) { d(); } else if ($b) { e(); } else if ($c) { f(); } else {
g();
}
if ($a) d();
else if ($b) e();
else if ($c) f();
else g();
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0213-region-markers.php | tests/fixtures/Formatter/in/issues/0213-region-markers.php | <?php
return function (App $app) {
$app->add(SessionMiddleware::class);
#region Twig
// Create Twig
$twig = Twig::create(__DIR__ . '/../templates', ['cache' => false]);
// Add Twig-View Middleware
$app->add(TwigMiddleware::create($app, $twig));
#endregion Twig
};
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0087-preserve-escaped-carriage-returns.php | tests/fixtures/Formatter/in/issues/0087-preserve-escaped-carriage-returns.php | <?php
$string = "\rText after carriage return";
$string = "\rMultiline text after carriage return
";
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0099-enum-comment-indentation.php | tests/fixtures/Formatter/in/issues/0099-enum-comment-indentation.php | <?php
enum ExampleEnum {
/**
* Note.
*/
case Foo;
# Note.
case Bar;
// Note.
case Qux;
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0151-ternary-alignment-after-static.php | tests/fixtures/Formatter/in/issues/0151-ternary-alignment-after-static.php | <?php
$obj instanceof static
?true: false;
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/issues/0015-hanging-indentation.php | tests/fixtures/Formatter/in/issues/0015-hanging-indentation.php | <?php
class A
{
private $b;
protected function c()
{
return $this->b
?? ($this->b = implode(
':', ['a',
'b',
'c',
'd',
'e']
));
}
}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/class-comments-02.php | tests/fixtures/Formatter/in/standalone/class-comments-02.php | <?php
class foo
{
function baz()
{
quux();
} // baz
} // foo
// continuation
class bar
{
function baz()
{
quux();
} // baz
} // bar
// continuation
class qux {} // qux
// continuation
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/native-types-02.php | tests/fixtures/Formatter/in/standalone/native-types-02.php | <?php declare(strict_types=1);
class MyClass
{
public string|MyClass|null $Bar;
public const MY_CONSTANT = 'my constant';
public function MyMethod(
$mixed,
?int $nullableInt,
string $string,
MyClass $class,
?MyClass $nullableClass,
?MyClass &$nullableClassB... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/numbers-01.php | tests/fixtures/Formatter/in/standalone/numbers-01.php | <?php
123;
0123;
00123;
01;
012;
01234;
0x1a;
0X1A;
0x01a;
0x001a;
0x0;
0x00;
0x000;
0xf;
0xfe;
0xfed;
0xfedc;
0xfedcb;
0xfedcba;
0xfedcba9;
0xfedcba98;
0xfedcba987;
0xfedcba9876;
0xfedcba98765;
0xfedcba987654;
0xfedcba9876543;
0xfedcba98765432;
0xfedcba987654321;
0xfedcba9876543210;
0x0_0;
0x0_f;
0xf_e;
0xf_ed;
0xf_ed... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/lists-01.php | tests/fixtures/Formatter/in/standalone/lists-01.php | <?php
use Foo\{Bar,
Baz, Qux};
use Foo2\{Bar as Bar2,
Baz as Baz2};
use Foo3\Bar as Bar3,
Foo3\Baz as Baz3,
Foo3\Qux as Qux3;
use function Foo\BarF,
Foo\BazF,
Foo\QuxF;
use const Foo\BarC, Foo\BazC,
Foo\QuxC;
const FOO = 1,
BAR = 2, BAZ = 4;
class Foo implements Bar3,
Baz3, Qux3
{
use... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/control-structure-expressions.php | tests/fixtures/Formatter/in/standalone/control-structure-expressions.php | <?php
if ($foo) {
baz();
} elseif ($qux) {
quux();
}
if ($foo ||
$bar) {
baz();
} elseif ($foo &&
$qux) {
quux();
}
switch ($foo) {
default:
baz();
break;
}
switch ($foo ||
$bar) {
default:
baz();
break;
}
while ($foo) {
baz();
}
while ... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/functions-anonymous-02.php | tests/fixtures/Formatter/in/standalone/functions-anonymous-02.php | <?php
function()
{
return;
};
function&()
{
return;
};
function(MyClass|string|null $foo,
$bar,
$baz)
{
return;
};
function&(MyClass|string|null $foo,
$bar,
$baz)
{
return;
};
fn&() =>
null;
$foo = function()
{
return;
};
$foo = function&()
{
return;
};
$foo = fn&() =>
nu... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/boolean-expressions.php | tests/fixtures/Formatter/in/standalone/boolean-expressions.php | <?php
$a = $b
| $c | $d;
$a = $b
| $c & $d | $e;
$a = $b
& $c | $d & $e;
$a = $b ||
$c || $d;
$a = $b ||
$c && $d || $e;
$a = $b &&
$c || $d && $e;
foo(bar() ||
qux() || quux());
foo(bar() ||
qux() && quux() || quuux());
foo(bar() &&
qux() || quux() && quuux());
foo(bar() &... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/chains-02.php | tests/fixtures/Formatter/in/standalone/chains-02.php | <?php
$foo = "B{$A}R"::${baz()}()
->qux()
->quux();
$foo = "B{$A}R"::${baz()}()
->qux();
$foo = "B${A}R"::${baz()}()
->qux()
->quux();
$foo = "B${A}R"::${baz()}()
->qux();
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/class-comments-01.php | tests/fixtures/Formatter/in/standalone/class-comments-01.php | <?php
class foo
{
function baz()
{
quux();
} // baz
} // foo
class bar
{
function baz()
{
quux();
} // baz
} // bar
class qux {} // qux
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/property-hooks-rfc.php | tests/fixtures/Formatter/in/standalone/property-hooks-rfc.php | <?php
// -- Example #4
class User
{
public string $name {
set {
if (strlen($value) === 0) {
throw new ValueError("Name must be non-empty");
}
$this->name = $value;
}
}
public function __construct(string $name) {
$this->name = $n... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/native-types-01.php | tests/fixtures/Formatter/in/standalone/native-types-01.php | <?php declare(strict_types=1);
class MyClass
{
public MyClass $Foo;
public ?int $Bar;
public const MY_CONSTANT = 'my constant';
public function MyMethod(
$mixed,
?int $nullableInt,
string $string,
MyClass $class,
?MyClass $nullableClass,
?MyClass &$null... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/void-cast.php | tests/fixtures/Formatter/in/standalone/void-cast.php | <?php
(void)foo();
( VOID ) bar();
(void)$foo or $bar;
for((void)foo();$bar;(void)$baz){}
| php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/class-anonymous-attributes-01.php | tests/fixtures/Formatter/in/standalone/class-anonymous-attributes-01.php | <?php
$a = new #[ AttrA ] class extends B implements C,D,E
{
};
$a = new #[ AttrB(true) ] #[ AttrC(101,Types::ANON_CLASS) ] #[ AttrD() ] class extends B implements C,
D,
E
{
};
$a = new #[ AttrE ] class extends B implements C,D,E
{
#[ AttrF(true) ] #[ AttrG(102,Types::FUNC) ] function f(string $h,int $i,$j) {
}
#[ A... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
lkrms/pretty-php | https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/in/standalone/functions-anonymous-01.php | tests/fixtures/Formatter/in/standalone/functions-anonymous-01.php | <?php
function()
{
return;
};
function&()
{
return;
};
function(?string $foo,
$bar,
$baz)
{
return;
};
function&(?string $foo,
$bar,
$baz)
{
return;
};
fn&() =>
null;
$foo = function()
{
return;
};
$foo = function&()
{
return;
};
$foo = fn&() =>
null;
fn(?string $foo,
... | php | MIT | 5d244a4b7a9b484581edbb5df596a4e76ba17fa6 | 2026-01-05T04:31:39.990954Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.