On Tue, Jun 18, 2013 at 1:23 PM, Jeff Welch <whatthej...@gmail.com> wrote:

> On Jun 18, 2013, at 1:13 PM, Sherif Ramadan <theanomaly...@gmail.com>
> wrote:
>
> On Mon, Jun 17, 2013 at 12:50 PM, Jeff Welch <whatthej...@gmail.com>wrote:
>
>> On Sun, Jun 16, 2013 at 6:51 PM, Jeff Welch <whatthej...@gmail.com>wrote:
>>
>>> On Sun, Jun 16, 2013 at 10:57 AM, Jeff Welch <whatthej...@gmail.com>wrote:
>>>
>>>> On Sun, Jun 16, 2013 at 4:36 AM, Sherif Ramadan <
>>>> theanomaly...@gmail.com> wrote:
>>>>
>>>>>
>>>>> On Sun, Jun 16, 2013 at 3:40 AM, Jeff Welch <whatthej...@gmail.com>wrote:
>>>>>
>>>>>> Hi, all :)
>>>>>>
>>>>>> My name is Jeff Welch and I'm one of the maintainers of the PHPUnit
>>>>>> project. While investigating a PHPUnit issue (
>>>>>> https://github.com/sebastianbergmann/phpunit-mock-objects/issues/130)
>>>>>> this past friday, I noticed that the PHP documentation is missing the
>>>>>> static modifier for a number of methods. I've created a patch (
>>>>>> https://gist.github.com/whatthejeff/5790970) that adds the missing
>>>>>> modifier for the following methods:
>>>>>>
>>>>>>  * `MessageFormatter::create`
>>>>>>  * `MessageFormatter::formatMessage`
>>>>>>  * `MessageFormatter::parseMessage`
>>>>>>  * `mysqli::poll`
>>>>>>  * `Phar::apiVersion`
>>>>>>  * `Phar::canCompress`
>>>>>>  * `Phar::canWrite`
>>>>>>  * `Phar::createDefaultStub`
>>>>>>  * `Phar::getSupportedCompression`
>>>>>>  * `Phar::getSupportedSignatures`
>>>>>>  * `Phar::interceptFileFuncs`
>>>>>>  * `Phar::isValidPharFilename`
>>>>>>  * `Phar::loadPhar`
>>>>>>  * `Phar::mapPhar`
>>>>>>  * `Phar::running`
>>>>>>  * `Phar::mount`
>>>>>>  * `Phar::mungServer`
>>>>>>  * `Phar::unlinkArchive`
>>>>>>  * `Phar::webPhar`
>>>>>>  * `SQLite3::version`
>>>>>>  * `SQLite3::escapeString`
>>>>>>
>>>>>> Anyway, it would be nice to get VCS access so I don't have to jump
>>>>>> through too many hoops for future contributions.
>>>>>>
>>>>>> PS: I've heard a love for cats will get you far with this list, so I
>>>>>> submit to you my cat-related open source contributions:
>>>>>>
>>>>>>  * https://github.com/whatthejeff/nyancat-phpunit-resultprinter
>>>>>>  * https://github.com/phpspec/phpspec/pull/133
>>>>>>  * https://github.com/whatthejeff/nyancat-scoreboard
>>>>>>
>>>>>>
>>>>>
>>>>> Hey you cheated. There was a dinosaur in there!
>>>>>
>>>>> Looks OK, but I suspect that it would be even better to add the
>>>>> visibility modifiers as long as you're adding the access modifiers.
>>>>>
>>>>
>>>> I can agree to this.
>>>>
>>>>
>>>>> The documentation is currently wishy-washy about having those for all
>>>>> of the classes. Some have just the access and others have both visibility
>>>>> and access. If you'd be willing to help fix the rest that would be awesome
>>>>>
>>>>
>>>> I don't mind adding the missing visibility modifiers.
>>>>
>>>
>>> Alright, I've updated the patch (
>>> https://gist.github.com/whatthejeff/5790970) to include visibility
>>> modifiers. For the most part I only worked on core classes as I don't have
>>> time to go through all the available PECL classes. I can't guarantee that I
>>> caught them all, but I did my best :)
>>>
>>
>> I realize this diff will be very time consuming to verify manually, so
>> I've added a script that parses the modifiers from my diff and verifies
>> them through reflection.
>>
>> You can find the script here:
>> https://gist.github.com/whatthejeff/5790970#file-test-missing-modifiers-php
>> And the output here:
>> https://gist.github.com/whatthejeff/5790970#file-output
>>
>>  Hopefully this helps :)
>>
>>
>>>
>>>>
>>>>> and I'm sure the cats will give you bonus points for your VCS account.
>>>>>
>>>>> You also might want to take a look at https://edit.php.net
>>>>>
>>>>
>>>> Yeah, I looked into that, but it's also nice to use shell tools for
>>>> making mass changes. For instance, I found all the missing static modifiers
>>>> and patched the documentation using grep/awk/sed.
>>>>
>>>>
>>>>> If no one has any objections I'll go ahead and apply your patch later
>>>>> tonight. I admit I didn't look it over that thoroughly.
>>>>>
>>>>
>>>> I can tell you that I compiled all the sources and manually verified
>>>> that the changed pages look as expected. We use DocBook for PHPUnit's
>>>> documentation, so I have a decent amount of experience with this toolchain.
>>>>
>>>>
>>>>>
>>>>>
>>>>>> Thanks,
>>>>>>
>>>>>> - Jeff
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
>
> Wow, this patch is huge and scary. Maybe we should give you a CVS account
> so that you can patch it yourself? :P
>
>
> Actually, I cheated and asked Sebastian Bergmann to patch it for me last
> night:
>
>
That would explain why svn is telling me the patch failed when I tried to
run it through patch this morning :) I didn't update from trunk apparently.

Good job. 999999 more patches like this and you get a free t-shirt!


> https://svn.php.net/viewvc?limit_changes=0&view=revision&revision=330543
>
> I wouldn't mind having a CVS account, though :P
>
> - Jeff
>

Reply via email to