diff options
| author | Caleb White <cdwhite3@pm.me> | 2024-03-16 19:50:13 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-16 20:50:13 -0400 |
| commit | 143ca5ce17ae21233101246b5785b90d53aa8329 (patch) | |
| tree | 3508a12c877818427060c9ae219bd1195454e465 /tests/indent/php/issue-4848.php | |
| parent | feat(hyprlang): add bash injections (diff) | |
| download | nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.tar nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.tar.gz nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.tar.bz2 nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.tar.lz nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.tar.xz nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.tar.zst nvim-treesitter-143ca5ce17ae21233101246b5785b90d53aa8329.zip | |
feat(php): improve indents in return statements & chained methods
Diffstat (limited to 'tests/indent/php/issue-4848.php')
| -rw-r--r-- | tests/indent/php/issue-4848.php | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/tests/indent/php/issue-4848.php b/tests/indent/php/issue-4848.php new file mode 100644 index 000000000..8d112ea14 --- /dev/null +++ b/tests/indent/php/issue-4848.php @@ -0,0 +1,66 @@ +<?php + +if ( +) { +} + +return ( +); + +return true + ; + +return fn () => ( +); + +return fn ( +) => ( +); + +return function ( +) { +}; + +return function () { +}; + +return match ( +) { +}; + +return match () { +}; + +return new class +{ + public function up() + { + } + + public function down( + ) { + } +}; + +$this->foo() + ->bar( + ) + ->baz(); + +$this->get() + ->each(function () { + }) + ->each( + function ( + ) { + }, + ); + +return $this->get() + ->each(function () { + }) + ->each( + function ( + ) { + }, + ); |
