Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify the output of example code #2679

Merged
merged 3 commits into from
Aug 14, 2023
Merged

Conversation

onuryilmazer
Copy link
Contributor

Accessing undefined variables generate an E_WARNING since PHP 8 (and will result in error exceptions being thrown in PHP 9).

Accessing undefined variables generate an E_WARNING since PHP 8 (and will result in error exceptions being thrown in PHP 9).
@@ -265,7 +265,8 @@ test();
</informalexample>

<simpara>
This script will not produce any output because the echo statement
As of PHP 8, this script will generate an undefined variable warning and will not produce
any output if the display_errors directive is set to hide warnings, because the echo statement
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While at it could you add a link to the display_error INI setting.

Also, this code would have emitted a notice in PHP 7, they were just not displayed by default.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

language/variables.xml Outdated Show resolved Hide resolved
@Girgias Girgias merged commit 00e8d1f into php:master Aug 14, 2023
2 checks passed
@Girgias
Copy link
Member

Girgias commented Aug 14, 2023

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants