diff --git a/language/operators/comparison.xml b/language/operators/comparison.xml index 4e89a9156d0f..a50981592ad5 100644 --- a/language/operators/comparison.xml +++ b/language/operators/comparison.xml @@ -486,7 +486,7 @@ echo 0 ?: 0 ?: 0 ?: 3, PHP_EOL; //3 // Example usage for: Null Coalesce Operator $action = $_POST['action'] ?? 'default'; -// The above is identical to this if/else statement +// The above is equivalent to this if/else statement if (isset($_POST['action'])) { $action = $_POST['action']; } else { @@ -500,11 +500,11 @@ if (isset($_POST['action'])) { expr2 if expr1 is &null;, and expr1 otherwise. - + In particular, this operator does not emit a notice or warning if the left-hand side - value does not exist, just like isset. This is especially - useful on array keys. - + is an undefined variable, array key or property, just like isset. + This is especially useful on array keys. + Please note that the null coalescing operator is an expression, and that it