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/03-tab/3rdparty/php-parser/parser/stmt/class/property_hooks/000.php
tests/fixtures/Formatter/out/03-tab/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; } set (string $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/03-tab/3rdparty/php-parser/parser/stmt/class/readonlyAnonyous/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/class/final/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/controlFlow/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/declare/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/nullableTypes/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/returnTypes/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/readonlyFunction/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/variadicDefaultValue/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/disjointNormalFormTypes/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/intersectionTypes/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/variadic/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/neverType/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/byRef/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/001.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/002.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/parameters_trailing_comma/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/conditional/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeVersions/004.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeVersions/001.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeVersions/002.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeVersions/003.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeVersions/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeVersions/005.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/specialVars/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/defaultValues/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/nullFalseTrueTypes/001.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/nullFalseTrueTypes/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/typeDeclarations/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/unionTypes/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/function/builtinTypeDeclarations/000.php
tests/fixtures/Formatter/out/03-tab/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/03-tab/3rdparty/php-parser/parser/stmt/const/000.php
tests/fixtures/Formatter/out/03-tab/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/out/04-psr12/issues/0069-ternary-coalesce.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0060-no-blank-lines.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0195-nowdoc-with-space.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0136-improve-hanging-indentation.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0009-align-split-assignments.php
tests/fixtures/Formatter/out/04-psr12/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', ...
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/04-psr12/issues/0142-increment-operator-spacing.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0156-ternary-hanging-indent.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0166-anonymous-functions.php
tests/fixtures/Formatter/out/04-psr12/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 ) {...
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/04-psr12/issues/0012-else-if.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0213-region-markers.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0087-preserve-escaped-carriage-returns.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0099-enum-comment-indentation.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0151-ternary-alignment-after-static.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/issues/0015-hanging-indentation.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/standalone/class-comments-02.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/standalone/native-types-02.php
tests/fixtures/Formatter/out/04-psr12/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 &$nullableClass...
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/04-psr12/standalone/numbers-01.php
tests/fixtures/Formatter/out/04-psr12/standalone/numbers-01.php
<?php 123; 0123; 0123; 01; 012; 01234; 0x1A; 0x1A; 0x1A; 0x1A; 0x0; 0x0; 0x0; 0xF; 0xFE; 0xFED; 0xFEDC; 0xFEDCB; 0xFEDCBA; 0xFEDCBA9; 0xFEDCBA98; 0xFEDCBA987; 0xFEDCBA9876; 0xFEDCBA98765; 0xFEDCBA987654; 0xFEDCBA9876543; 0xFEDCBA98765432; 0xFEDCBA987654321; 0xFEDCBA9876543210; 0x0; 0xF; 0xFE; 0xFED; 0xFEDC; 0x000F_EDCB...
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/04-psr12/standalone/lists-01.php
tests/fixtures/Formatter/out/04-psr12/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 ...
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/04-psr12/standalone/control-structure-expressions.php
tests/fixtures/Formatter/out/04-psr12/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(); } ...
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/04-psr12/standalone/functions-anonymous-02.php
tests/fixtures/Formatter/out/04-psr12/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...
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/04-psr12/standalone/boolean-expressions.php
tests/fixtures/Formatter/out/04-psr12/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() ...
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/04-psr12/standalone/chains-02.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/standalone/class-comments-01.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/standalone/property-hooks-rfc.php
tests/fixtures/Formatter/out/04-psr12/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 =...
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/04-psr12/standalone/native-types-01.php
tests/fixtures/Formatter/out/04-psr12/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 &$nul...
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/04-psr12/standalone/void-cast.php
tests/fixtures/Formatter/out/04-psr12/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/out/04-psr12/standalone/class-anonymous-attributes-01.php
tests/fixtures/Formatter/out/04-psr12/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)] #...
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/04-psr12/standalone/functions-anonymous-01.php
tests/fixtures/Formatter/out/04-psr12/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...
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/04-psr12/standalone/static-variables.php
tests/fixtures/Formatter/out/04-psr12/standalone/static-variables.php
<?php function foo() { static $bar = 0; function () use (&$bar) { $bar++; }; static $baz = 0; #[Attr()] function () use (&$baz) { $baz++; }; static $qux = 0; new class($qux) { function __construct(&$qux) { $qux++; } }; stat...
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/04-psr12/standalone/class-anonymous-attributes-02.php
tests/fixtures/Formatter/out/04-psr12/standalone/class-anonymous-attributes-02.php
<?php new #[AttrA] class extends B implements C, D, E {}; new #[AttrB(true)] #[AttrC(101, Types::ANON_CLASS)] #[AttrD()] class extends B implements C, D, E {}; new #[AttrE] class extends B implements C, D, E { #[AttrF(true)] #[AttrG(102, Typ...
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/04-psr12/standalone/numbers-02.php
tests/fixtures/Formatter/out/04-psr12/standalone/numbers-02.php
<?php 0123; 0123; 0123; 0123; 01234567; 012345670;
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/04-psr12/standalone/declare-statements.php
tests/fixtures/Formatter/out/04-psr12/standalone/declare-statements.php
<?php declare(ticks=1); declare(ticks=1); // declare(ticks=1); // declare(ticks=1) { // } declare(ticks=1); declare(ticks=1); // declare(ticks=1); declare(ticks=1); declare(ticks=1) { // } declare(ticks=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/04-psr12/standalone/embedded-docblocks-02.php
tests/fixtures/Formatter/out/04-psr12/standalone/embedded-docblocks-02.php
<?php $foo = $bar /* * comment */ || $baz; if ( $foo /* * comment */ || $bar ) { } function baz( /* * comment */ $foo, /* * comment */ $bar /* * comment */ ) {} class Foo { /* * comment */ use 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/04-psr12/standalone/class-anonymous-01.php
tests/fixtures/Formatter/out/04-psr12/standalone/class-anonymous-01.php
<?php $a = new class extends B implements C, D, E {}; $a = new class extends B implements C, D, E {}; $a = new class extends B implements C, D, E { function f(string $h, int $i, $j) {} function g($k) {} function z() {} }; $a = new class extends B implements C, D, E { functi...
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/04-psr12/standalone/match-01.php
tests/fixtures/Formatter/out/04-psr12/standalone/match-01.php
<?php $result = match (true) { str_contains($text, 'Welcome') || str_contains($text, 'Hello'), str_contains($text, 'Hi') || str_contains($text, "G'day") => 'en', str_contains($text, 'Bienvenue') || str_contains($text, 'Bonjour') => 'fr' }; $result = match (true) { $senior, $age >=...
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/04-psr12/standalone/chains-01.php
tests/fixtures/Formatter/out/04-psr12/standalone/chains-01.php
<?php $foo = bar() ->baz() ->qux(); $foo = bar() ->baz(); $foo = b() ->baz() ->qux(); $foo = b() ->baz(); $foo = b() ->baz() ->qux(); $foo = bar() ->${'baz'}() ->${'qux'}(); $foo = bar() ->${'baz'}(); $_foo = bar() ->${baz()}() ->qux() ->quux(); $_foo = 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/04-psr12/standalone/functions-anonymous-04.php
tests/fixtures/Formatter/out/04-psr12/standalone/functions-anonymous-04.php
<?php function () { return; }; function &() { return; }; function ( (Countable&ArrayAccess)|MyClass|string|null $foo, $bar, $baz ) { return; }; function &( (Countable&ArrayAccess)|MyClass|string|null $foo, $bar, $baz ) { return; }; fn&() => null; $foo = function () { retu...
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/04-psr12/standalone/functions-anonymous-03.php
tests/fixtures/Formatter/out/04-psr12/standalone/functions-anonymous-03.php
<?php function () { return; }; function &() { return; }; function ( MyClass|string|null $foo, Countable&ArrayAccess $bar, $baz ) { return; }; function &( MyClass|string|null $foo, Countable&ArrayAccess $bar, $baz ) { return; }; fn&() => null; $foo = function () { 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/out/04-psr12/standalone/native-types-04.php
tests/fixtures/Formatter/out/04-psr12/standalone/native-types-04.php
<?php declare(strict_types=1); class MyClass { public (Countable&ArrayAccess)|MyClass|string|null $Foo; public string|MyClass|(Countable&ArrayAccess)|null $Bar; public const MY_CONSTANT = 'my constant'; public function MyMethod( $mixed, ?int $nullableInt, string $string, ...
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/04-psr12/standalone/class-attributes-01.php
tests/fixtures/Formatter/out/04-psr12/standalone/class-attributes-01.php
<?php #[AttrA] class A1 extends B implements C, D, E {} #[AttrB(true)] #[AttrC(101, Types::ANON_CLASS)] #[AttrD()] class A2 extends B implements C, D, E {} #[AttrE] class A3 extends B implements C, D, E { #[AttrF(true)] #[AttrG(102, Types::FUNC)] function f(string $h, int $i, $j) {} #[At...
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/04-psr12/standalone/embedded-docblocks-01.php
tests/fixtures/Formatter/out/04-psr12/standalone/embedded-docblocks-01.php
<?php $foo = $bar /** comment */ || $baz; if ( $foo /** comment */ || $bar ) { } function baz( /** comment */ $foo, /** comment */ $bar /** * comment */ ) {} class Foo { /** comment */ use Bar; } $foo = $bar /** * line 1 * line 2 */ |...
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/04-psr12/standalone/native-types-03.php
tests/fixtures/Formatter/out/04-psr12/standalone/native-types-03.php
<?php declare(strict_types=1); class MyClass { public Countable&ArrayAccess $Foo; public string|MyClass|null $Bar; public const MY_CONSTANT = 'my constant'; public function MyMethod( $mixed, ?int $nullableInt, string $string, Countable&ArrayAccess $intersection, ...
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/04-psr12/standalone/class-comments-03.php
tests/fixtures/Formatter/out/04-psr12/standalone/class-comments-03.php
<?php class foo {} class bar {} class baz {} /** * comment */ class foo { function baz() {} } /** * comment */ class bar { function baz() {} } /** * comment */ class qux {} // qux // continuation /** * comment */ class foo { function baz() {} } // foo // not a continuation /** * comment */...
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/04-psr12/3rdparty/utf-8.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/utf-8.php
<?php $ascii = "\0\x01\x02\x03\x04\x05\x06\x07\x08\t\n\v\f\r\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\e\x1c\x1d\x1e\x1f"; $blank = "\u{00A0}\u{2000}\u{2001}\u{2002}\u{2003}\u{2004}\u{2005}\u{2006}\u{2007}\u{2008}\u{2009}\u{200A}\u{202F}\u{205F}\u{3000}"; $bom = "\u{FEFF}"; $ignorable = "\u{00AD}\u{202A}\u{20...
php
MIT
5d244a4b7a9b484581edbb5df596a4e76ba17fa6
2026-01-05T04:31:39.990954Z
true
lkrms/pretty-php
https://github.com/lkrms/pretty-php/blob/5d244a4b7a9b484581edbb5df596a4e76ba17fa6/tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/other-changes/001.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/other-changes/001.php
<?php var_dump('@');
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/04-psr12/3rdparty/php-doc/appendices/migration71/other-changes/000.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/other-changes/000.php
<?php '1b' + 'something';
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/006.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/006.php
<?php $data = [ ['id' => 1, 'name' => 'Tom'], ['id' => 2, 'name' => 'Fred'], ]; // list() style list('id' => $id1, 'name' => $name1) = $data[0]; // [] style ['id' => $id1, 'name' => $name1] = $data[0]; // list() style foreach ($data as list('id' => $id, 'name' => $name)) { // logic here with $id and $nam...
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/004.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/004.php
<?php function iterator(iterable $iter) { foreach ($iter as $val) { // } }
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/001.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/001.php
<?php function swap(&$left, &$right): void { if ($left === $right) { return; } $tmp = $left; $left = $right; $right = $tmp; } $a = 1; $b = 2; var_dump(swap($a, $b), $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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/002.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/002.php
<?php $data = [ [1, 'Tom'], [2, 'Fred'], ]; // list() style list($id1, $name1) = $data[0]; // [] style [$id1, $name1] = $data[0]; // list() style foreach ($data as list($id, $name)) { // logic here with $id and $name } // [] style foreach ($data as [$id, $name]) { // logic here with $id and $name }
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/009.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/009.php
<?php class Test { public function exposeFunction() { return Closure::fromCallable([$this, 'privateFunction']); } private function privateFunction($param) { var_dump($param); } } $privFunc = (new Test)->exposeFunction(); $privFunc('some 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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/007.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/007.php
<?php var_dump('abcdef'[-2]); var_dump(strpos('aabbcc', 'b', -3));
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/010.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/010.php
<?php pcntl_async_signals(true); // turn on async signals pcntl_signal(SIGHUP, function ($sig) { echo "SIGHUP\n"; }); posix_kill(posix_getpid(), SIGHUP);
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/003.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/003.php
<?php class ConstDemo { const PUBLIC_CONST_A = 1; public const PUBLIC_CONST_B = 2; protected const PROTECTED_CONST = 3; private const PRIVATE_CONST = 4; }
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/008.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/008.php
<?php $string = 'bar'; echo "The last character of '$string' is '$string[-1]'.\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/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/000.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/000.php
<?php function testReturnA(): ?string { return 'elePHPant'; } var_dump(testReturnA()); function testReturnB(): ?string { return null; } var_dump(testReturnB()); function test(?string $name) { var_dump($name); } test('elePHPant'); test(null); test();
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/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/005.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/new-features/005.php
<?php try { // some code } catch (FirstException | SecondException $e) { // handle first and second exceptions }
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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/006.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/006.php
<?php var_dump(json_decode(json_encode(['' => 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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/004.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/004.php
<?php new DateTime() == new DateTime(); ?>
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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/001.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/001.php
<?php (function () { $func = 'func_num_args'; $func(); })();
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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/002.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/002.php
<?php $a = ''; $a[10] = 'foo'; var_dump($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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/003.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/003.php
<?php $array = []; $array['a'] = &$array['b']; $array['b'] = 1; var_dump($array); ?>
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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/000.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/000.php
<?php function test($param) {} test();
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/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/005.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration71/incompatible/005.php
<?php $f = function () use ($_SERVER) {}; $f = function () use ($this) {}; $f = function ($param) use ($param) {};
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/04-psr12/3rdparty/php-doc/appendices/migration72/deprecated/000.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration72/deprecated/000.php
<?php var_dump(NONEXISTENT); /* * Output: * Warning: Use of undefined constant NONEXISTENT - assumed 'NONEXISTENT' (this will throw an Error in a future version of PHP) in %s on line %d * string(11) "NONEXISTENT" */
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/04-psr12/3rdparty/php-doc/appendices/migration72/new-features/004.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration72/new-features/004.php
<?php use Foo\Bar\{ 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/04-psr12/3rdparty/php-doc/appendices/migration72/new-features/001.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration72/new-features/001.php
<?php abstract class A { abstract function test(string $s); } abstract class B extends A { // overridden - still maintaining contravariance for parameters and covariance for return abstract function test($s): int; }
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/04-psr12/3rdparty/php-doc/appendices/migration72/new-features/002.php
tests/fixtures/Formatter/out/04-psr12/3rdparty/php-doc/appendices/migration72/new-features/002.php
<?php $db->quote('über', PDO::PARAM_STR | PDO::PARAM_STR_NATL);
php
MIT
5d244a4b7a9b484581edbb5df596a4e76ba17fa6
2026-01-05T04:31:39.990954Z
false