Enable runnable (WASM) examples for language.variables section#5455
Merged
Conversation
jordikroon
reviewed
Apr 2, 2026
Review amends: "\n" => PHP_EOL
jordikroon
reviewed
May 5, 2026
| <example> | ||
| <title>Valid variable names</title> | ||
| <programlisting role="php"> | ||
| <programlisting role="php" annotations="non-interactive"> |
Member
There was a problem hiding this comment.
Is there a specific reason why this is marked as non-interactive? To me a valid example seems more useful than examples that generate a syntax error.
Contributor
Author
There was a problem hiding this comment.
The example is demonstrating valid variable names. At least half the example gives no useful output and I thought adding extra output here might dilute the purpose of the example.
jordikroon
requested changes
May 5, 2026
jordikroon
approved these changes
May 7, 2026
lacatoire
added a commit
to lacatoire/doc-fr
that referenced
this pull request
May 8, 2026
PR upstream: php/doc-en#5455 Commit: 64007e9f6b23f70d8874be11c4eb9d45556b742f Closes php#2815
This was referenced May 8, 2026
lacatoire
added a commit
to php/doc-fr
that referenced
this pull request
May 8, 2026
PR upstream: php/doc-en#5455 Commit: 64007e9f6b23f70d8874be11c4eb9d45556b742f Closes #2815
PhilDaiguille
pushed a commit
to php/doc-es
that referenced
this pull request
May 9, 2026
PR upstream: php/doc-en#5455 Commit: 64007e9f6b23f70d8874be11c4eb9d45556b742f Closes #576
jordikroon
pushed a commit
to Narkunan/doc-en
that referenced
this pull request
May 17, 2026
* Enable runnable (WASM) examples for language.variables section
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related: #4799
Line endings,
var_dump()or function calls have been added as appropriate to actually run the code and provide useful output.Some example output code was rearranged so the WASM output replaces it as expected.
Additional changes:
?>where not requiredI'm wondering if there are some alternative examples of invalid assignment that aren't just outright (and "unrelated") syntax errors.