Closed as not planned
Description
Description
The following code:
var_dump(- '3');
$v = 'x';
var_dump(- $v);
var_dump(- 'x');
it seems the exception message does not expect unary operator, as for 1 + 'x'
it makes much more sense and the operator is displayed correctly
Resulted in this output:
int(-3)
Fatal error: Uncaught TypeError: Unsupported operand types: string * int in /in/tokuW:5
Stack trace:
#0 {main}
thrown in /in/tokuW on line 5
But I expected this output instead:
int(-3)
1x meaningful exception (or 2x warning)
PHP Version
PHP 8.0+
Operating System
any