Open
Conversation
Author
|
I would like to note that since this is a new documentation the workflow run https://github.com/php/doc-en/actions/runs/14958493251/job/42050000015 is going to fail until the related pull request php/doc-base#246 is merged. |
|
Great👍 |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+11
to
+14
| <para> | ||
| This extension allows you to define and implement operator overloading for objects. | ||
| It is possible to define how an object reacts when an operator is used on it. | ||
| </para> |
Member
There was a problem hiding this comment.
Suggested change
| <para> | |
| This extension allows you to define and implement operator overloading for objects. | |
| It is possible to define how an object reacts when an operator is used on it. | |
| </para> | |
| <simpara> | |
| This extension defines and implements operator overloading for objects. | |
| It allows defining how an object reacts when an operator is used on it. | |
| </simpara> |
lacatoire
reviewed
Apr 21, 2026
| operator overloaded to allow repeating the string a certain number of times. | ||
| </para> | ||
| <section> | ||
| &reftitle.seealso; |
Member
There was a problem hiding this comment.
Suggested change
| &reftitle.seealso; |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+15
to
+19
| <para> | ||
| One example of this is creating a collection type object that has the addition | ||
| operator overloaded to allow adding elements to the collection or adding two | ||
| collections together. | ||
| </para> |
Member
There was a problem hiding this comment.
Suggested change
| <para> | |
| One example of this is creating a collection type object that has the addition | |
| operator overloaded to allow adding elements to the collection or adding two | |
| collections together. | |
| </para> | |
| <simpara> | |
| One example of this is creating a collection type object that has the addition | |
| operator overloaded to allow adding elements to the collection or adding two | |
| collections together. | |
| </simpara> |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+20
to
+23
| <para> | ||
| Another example is creating an enhanced string class that has the multiplication | ||
| operator overloaded to allow repeating the string a certain number of times. | ||
| </para> |
Member
There was a problem hiding this comment.
Suggested change
| <para> | |
| Another example is creating an enhanced string class that has the multiplication | |
| operator overloaded to allow repeating the string a certain number of times. | |
| </para> | |
| <simpara> | |
| Another example is creating an enhanced string class that has the multiplication | |
| operator overloaded to allow repeating the string a certain number of times. | |
| </simpara> |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+12
to
+14
| <para> | ||
| Windows users can download prebuilt release binaries from the <link xlink:href="&url.pecl.package;operator">PECL</link> website. | ||
| </para> |
Member
There was a problem hiding this comment.
Suggested change
| <para> | |
| Windows users can download prebuilt release binaries from the <link xlink:href="&url.pecl.package;operator">PECL</link> website. | |
| </para> | |
| <simpara> | |
| Windows users can download prebuilt release binaries from the <link xlink:href="&url.pecl.package;operator">PECL</link> website. | |
| </simpara> |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+15
to
+18
| <para> | ||
| operator releases are hosted by PECL and the source code by | ||
| <link xlink:href="&url.git.hub;jb-lopez/pecl-php-operator">github</link>. | ||
| </para> |
Member
There was a problem hiding this comment.
Suggested change
| <para> | |
| operator releases are hosted by PECL and the source code by | |
| <link xlink:href="&url.git.hub;jb-lopez/pecl-php-operator">github</link>. | |
| </para> | |
| <simpara> | |
| operator releases are hosted by PECL and the source code by | |
| <link xlink:href="&url.git.hub;jb-lopez/pecl-php-operator">github</link>. | |
| </simpara> |
lacatoire
reviewed
Apr 21, 2026
| <member><literal>$a::__is_smaller($b)</literal></member> | ||
| <member><literal>$a::__is_smaller_or_equal($b)</literal></member> | ||
| <member><literal>$a::__is_greater($b)</literal></member> | ||
| <member><literal>$a::__is_greater_or_equal($b)</literal></member> |
Member
There was a problem hiding this comment.
Suggested change
| <member><literal>$a::__is_greater_or_equal($b)</literal></member> | |
| <member><literal>$a::__is_greater_or_equal($b)</literal></member> | |
| <member><literal>$a::__spaceship($b)</literal></member> |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+32
to
37
| <para> | ||
| There is a PECL extension that allows for overloading of some operators for | ||
| objects. For more information, see the <link linkend="book.operator">Operator | ||
| Overloading for Objects</link> section. | ||
| </para> | ||
|
|
Member
There was a problem hiding this comment.
Suggested change
| <para> | |
| There is a PECL extension that allows for overloading of some operators for | |
| objects. For more information, see the <link linkend="book.operator">Operator | |
| Overloading for Objects</link> section. | |
| </para> | |
| <simpara> | |
| There is a PECL extension that allows for overloading of some operators for | |
| objects. For more information, see the <link linkend="book.operator">Operator | |
| Overloading for Objects</link> section. | |
| </simpara> | |
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+30
to
+32
| <member><literal>$a::__assign_and($b)</literal></member> | ||
| <member><literal>$a::__assign_or($b)</literal></member> | ||
| <member><literal>$a::__assign_xor($b)</literal></member> |
Member
There was a problem hiding this comment.
Suggested change
| <member><literal>$a::__assign_and($b)</literal></member> | |
| <member><literal>$a::__assign_or($b)</literal></member> | |
| <member><literal>$a::__assign_xor($b)</literal></member> | |
| <member><literal>$a::__assign_bw_and($b)</literal></member> | |
| <member><literal>$a::__assign_bw_or($b)</literal></member> | |
| <member><literal>$a::__assign_bw_xor($b)</literal></member> |
Member
There was a problem hiding this comment.
lacatoire
reviewed
Apr 21, 2026
Comment on lines
+45
to
+46
| <member><literal>$a::__bw_sl($b)</literal></member> | ||
| <member><literal>$a::__bw_sr($b)</literal></member> |
Member
There was a problem hiding this comment.
Suggested change
| <member><literal>$a::__bw_sl($b)</literal></member> | |
| <member><literal>$a::__bw_sr($b)</literal></member> | |
| <member><literal>$a::__sl($b)</literal></member> | |
| <member><literal>$a::__sr($b)</literal></member> |
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.
This pull request is to add the missing documentation for the PECL operator extension. I have taken over as the lead maintainer for that extension, but this is my first contribution to the PHP documentation so any feedback is welcome. There is a companion pull request to
doc-basethat goes with one and is required by this one. php/doc-base#246There appears to never have been any documentation for the PECL operator extension. For this pull request I've added the test class that ext/operator uses all of its overloading capabilities as a complete code sample.