403Webshell
Server IP : 54.233.248.239  /  Your IP : 172.28.20.13
Web Server : Apache
System : Linux ip-172-28-29-189 6.5.0-1014-aws #14~22.04.1-Ubuntu SMP Thu Feb 15 15:27:06 UTC 2024 x86_64
User : www-data ( 33)
PHP Version : 7.2.34-43+ubuntu22.04.1+deb.sury.org+1
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/vinumday2_0/vendor/nikic/php-parser/test/code/formatPreservation/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/vinumday2_0/vendor/nikic/php-parser/test/code/formatPreservation/fixup.test
Fixup for precedence and some special syntax
-----
<?php
$a ** $b  *  $c;
$a  +  $b * $c;
$a * $b  +  $c;
$a  ?  $b  :  $c;
($a ** $b)  *  $c;
( $a ** $b )  *  $c;
!$a = $b;
-----
// Parens necessary
$stmts[0]->expr->left = new Expr\BinaryOp\Plus(new Expr\Variable('a'), new Expr\Variable('b'));
// The parens here are "correct", because add is left assoc
$stmts[1]->expr->right = new Expr\BinaryOp\Plus(new Expr\Variable('b'), new Expr\Variable('c'));
// No parens necessary
$stmts[2]->expr->left = new Expr\BinaryOp\Plus(new Expr\Variable('a'), new Expr\Variable('b'));
// Parens for RHS not strictly necessary due to assign speciality
$stmts[3]->expr->cond = new Expr\Assign(new Expr\Variable('a'), new Expr\Variable('b'));
$stmts[3]->expr->if = new Expr\Assign(new Expr\Variable('a'), new Expr\Variable('b'));
$stmts[3]->expr->else = new Expr\Assign(new Expr\Variable('a'), new Expr\Variable('b'));
// Already has parens
$stmts[4]->expr->left = new Expr\BinaryOp\Plus(new Expr\Variable('a'), new Expr\Variable('b'));
$stmts[5]->expr->left = new Expr\BinaryOp\Plus(new Expr\Variable('a'), new Expr\Variable('b'));
-----
<?php
($a + $b)  *  $c;
$a  +  ($b + $c);
$a + $b  +  $c;
($a = $b)  ?  $a = $b  :  ($a = $b);
($a + $b)  *  $c;
( $a + $b )  *  $c;
!$a = $b;
-----
<?php
foo ();
foo ();
$foo -> bar;
$foo -> bar;
$foo -> bar;
$foo -> bar;
$foo -> bar;
self :: $foo;
self :: $foo;
-----
$stmts[0]->expr->name = new Expr\Variable('a');
$stmts[1]->expr->name = new Expr\BinaryOp\Concat(new Expr\Variable('a'), new Expr\Variable('b'));
$stmts[2]->expr->var = new Expr\Variable('bar');
$stmts[3]->expr->var = new Expr\BinaryOp\Concat(new Expr\Variable('a'), new Expr\Variable('b'));
$stmts[4]->expr->name = new Node\Identifier('foo');
// In this case the braces are not strictly necessary. However, on PHP 5 they may be required
// depending on where the property fetch node itself occurs.
$stmts[5]->expr->name = new Expr\Variable('bar');
$stmts[6]->expr->name = new Expr\BinaryOp\Concat(new Expr\Variable('a'), new Expr\Variable('b'));
$stmts[7]->expr->name = new Node\VarLikeIdentifier('bar');
$stmts[8]->expr->name = new Expr\BinaryOp\Concat(new Expr\Variable('a'), new Expr\Variable('b'));
-----
<?php
$a ();
($a . $b) ();
$bar -> bar;
($a . $b) -> bar;
$foo -> foo;
$foo -> {$bar};
$foo -> {$a . $b};
self :: $bar;
self :: ${$a . $b};

Youez - 2016 - github.com/yon3zu
LinuXploit