Last modified: 2013-04-10 14:10:03 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 28389 - Single quote in comment derails doxygen
Single quote in comment derails doxygen
Status: NEW
Product: MediaWiki
Classification: Unclassified
Documentation (Other open bugs)
1.18.x
All All
: Normal trivial (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-04-02 18:15 UTC by s7eph4n
Modified: 2013-04-10 14:10 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description s7eph4n 2011-04-02 18:15:50 UTC
HTMLForm.php (r85166) contains in lines 76..78 a comment using #. The comment contains an apostrophe which derails doxygen. The # should be changed into //.
Comment 1 Happy-melon 2011-04-02 19:35:00 UTC
So you're saying that 

    if( $wgRequest->wasPosted() ){
        # Ok, so we got a POST submission asking us to reblock a user...
        # confirm checkbox; the user will only see it if they haven't previously
        $fields['Confirm']['type'] = 'check';
    }

is broken because of the apostrophe in "haven't"; but that 

    if( $wgRequest->wasPosted() ){
        // Ok, so we got a POST submission asking us to reblock a user...
        // confirm checkbox; the user will only see it if they haven't previously
        $fields['Confirm']['type'] = 'check';
    }

would be fine?  What happens to doxygen in the former case?
Comment 2 s7eph4n 2011-04-02 19:54:02 UTC
(In reply to comment #1)
> would be fine?  What happens to doxygen in the former case?

I could not find your code, I am talking about http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/HTMLForm.php?view=markup&pathrev=85166#l76

However, yours is probably a candidate, too.
The problem is, that doxygen interprets the apostrophe as a string start and consequently ignores the following code (or tries to cope with it somehow). See http://svn.wikimedia.org/doc/HTMLForm_8php_source.html.
Comment 3 Happy-melon 2011-04-02 20:18:11 UTC
Then why doesn't, for instance, the apostrophe at http://svn.wikimedia.org/doc/Title_8php_source.html#l00562 trigger the same behaviour?  I think it's that it doesn't like the comments inside the array declaration, rather than it not liking the syntax of the comment.  Thoughts?
Comment 4 s7eph4n 2011-04-02 20:28:37 UTC
Moving the comment out of the array declaration worked, so it seems to be the combination. The doxygen PHP parser is based on the C parser, AFAIK. Can't remember what a # signifies in C, but it's probably not a comment. This might explain, why it's unexpected in an array declaration, but works alright outside.
Comment 5 Mark A. Hershberger 2011-04-06 00:04:35 UTC
(In reply to comment #4)
> Can't remember what a # signifies in C, but it's probably not a comment.

# introduces pre-processor directives like #include and #define.
Comment 6 richa jain 2013-04-10 14:10:03 UTC
I can see // being used on line 117..119, seems the bug is fixed.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links