-
Notifications
You must be signed in to change notification settings - Fork 741
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
Generate methodysnopses based on stubs for Zend functions and methods #168
Conversation
Thank you for working on this! Highly appreciated. |
596f150
to
4429d59
Compare
c915127
to
a736d10
Compare
3515890
to
120a569
Compare
I scrolled through this, and it looks good to me! Apart from the I think we might want to do a post-processing str_replace to preserve that newline before the final comment, to reduce the amount of spurious diff. |
I'll try to add this to the code. |
120a569
to
e503aa7
Compare
I'm afraid this is not that easy. Some pages do the opposite, and doesn't already have a newline before/after the root element tags, so if I tried Do you insist on this change, or is it ok if these documents are normalized to get rid of the whitespaces in question? |
The issue is mostly with translations, as spurious diffs still forces translations to update the EN-Revision tag. So the less the better IMHO EDIT: Just looked at the current diff, as it seems files already need to be updated the whitespace diffs can be ignored by translations |
Exactly! :) |
Is this one ready to go now? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pretty good job, @kocsismate! :)
Whether we want to merge as is – well, how thorough do we like to be right now? I left some comments for consideration.
<methodparam choice="opt"><type>int</type><parameter>severity</parameter><initializer><constant>E_ERROR</constant></initializer></methodparam> | ||
<methodparam choice="opt"><type class="union"><type>string</type><type>null</type></type><parameter>filename</parameter><initializer>&null;</initializer></methodparam> | ||
<methodparam choice="opt"><type class="union"><type>int</type><type>null</type></type><parameter>line</parameter><initializer>&null;</initializer></methodparam> | ||
<methodparam choice="opt"><type class="union"><type>Throwable</type><type>null</type></type><parameter>previous</parameter><initializer>&null;</initializer></methodparam> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assuming these 3 params have not been nullable before 8.0, this would need to be documented (maybe even separate sysnopses for PHP 7/8?).
e503aa7
to
f5d5ed2
Compare
Please, let's not do any changes, apart from the automated signature changes and anything that is required to keep it building properly (the constructorsynopsis change in this case). We'll get completely bogged down otherwise. |
f5d5ed2
to
9ef09de
Compare
@cmb69 Can you please add a label to this PR? Or alternatively, give me right to do so ^^ |
eae762c
to
65d8c72
Compare
I've just rebased to master, and added a few change log entries where doing so seemed necessary. I also noticed that the manual entries are yet to be added for |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally okay with this (and appreciate the effort!), but in a few spots the parameter names are changed. Some of these are clearly for the better, some are questionable or even for the worse. We should probably update the stubs to make the names match documentation in most cases since the docs were (presumably) written by someone who put editorial thought into the name.
@sgolemon Together with Nikita we made quite a lot of effort to improve parameter names. :) Which ones are you not satisfied with? Unless a parameter name is really broken, I don't think we can change them in the stubs because the arginfo structures are generated from the stubs, so we would introduce a BC break for named arguments. |
The one that stood out to me was
Argh... good point. Fine... Leave as-is then. :( |
65d8c72
to
26eb250
Compare
26eb250
to
fa7aabc
Compare
I know it's a large one.. But it would be very useful for users. Can you please review it, @cmb69 @kamil-tekiela ? |
Thanks everybody! |
No description provided.