Skip to content

Document get_error_handler(), get_exception_handler() #4567

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

Merged
merged 3 commits into from
Apr 21, 2025

Conversation

arnaud-lb
Copy link
Member

<refentry xml:id="function.get-error-handler" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>get_error_handler</refname>
<refpurpose>Gets the user-defined error handler function</refpurpose>
Copy link
Member Author

Choose a reason for hiding this comment

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

Using the same terminology as in

<refpurpose>Sets a user-defined error handler function</refpurpose>

@philip
Copy link
Member

philip commented Mar 28, 2025

LGTM! One potential improvement is to add an alternative for the pre-8.5 world as an example.

@arnaud-lb
Copy link
Member Author

@philip I've added a note, inspired from the one in https://www.php.net/array_key_first

&reftitle.examples;
<para>
<example>
<title><function>get_error_handler</function></title>
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<title><function>get_error_handler</function></title>
<title><function>get_error_handler</function> example</title>

Same bellow :)

@arnaud-lb arnaud-lb merged commit 4a6671f into php:master Apr 21, 2025
2 checks passed
Copy link
Member

@Girgias Girgias left a comment

Choose a reason for hiding this comment

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

Minor nit I spotted that should be done in a follow-up PR

Comment on lines +37 to +39
&reftitle.examples;
<para>
<example>
Copy link
Member

Choose a reason for hiding this comment

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

Minor nit, there is no need for the wrapping <para> tags around the example

Comment on lines +90 to +92
&reftitle.seealso;
<para>
<simplelist>
Copy link
Member

Choose a reason for hiding this comment

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

Ditto no need for the wrapping para tag here

Comment on lines +37 to +39
&reftitle.examples;
<para>
<example>
Copy link
Member

Choose a reason for hiding this comment

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

Ditto

Comment on lines +63 to +68
&reftitle.notes;
<tip>
<simpara>
Prior to PHP 8.5.0, this functionality can be provided by the following
polyfill:
</simpara>
Copy link
Member

Choose a reason for hiding this comment

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

Indent is off

Comment on lines +90 to +93
&reftitle.seealso;
<para>
<simplelist>
<member><function>set_exception_handler</function></member>
Copy link
Member

Choose a reason for hiding this comment

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

Ditto

Girgias pushed a commit that referenced this pull request May 20, 2025
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.

4 participants