Summary: | check-webkit-style is wrong about expected format parameter pack rvalue reference arguments | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Brady Eidson <beidson> | ||||||||
Component: | Tools / Tests | Assignee: | Nobody <webkit-unassigned> | ||||||||
Status: | RESOLVED FIXED | ||||||||||
Severity: | Normal | CC: | bfulgham, commit-queue, glenn, llango.u-szeged, ossy, rniwa | ||||||||
Priority: | P2 | ||||||||||
Version: | 528+ (Nightly build) | ||||||||||
Hardware: | All | ||||||||||
OS: | All | ||||||||||
Attachments: |
|
Description
Brady Eidson
2013-11-21 11:45:52 PST
Bug #123406 likely covers the same issue. (In reply to comment #1) > Bug #123406 likely covers the same issue. Hmmmm I guess it's not out on the bot yet? László fixed an rvalue related bug in bug123406. It seems the style checker needs a little bit more fine tuning. (In reply to comment #1) > Bug #123406 likely covers the same issue Unortunately no, I tried the mentioned patch after the fix for bug123406 landed, but style checker still fails on it. (In reply to comment #4) > (In reply to comment #1) > > Bug #123406 likely covers the same issue > > Unortunately no, I tried the mentioned patch after the fix > for bug123406 landed, but style checker still fails on it. Yes, that was another bug, but i can check this too, if nobody works on it. Created attachment 217661 [details]
Patch
Created attachment 217663 [details]
Patch
I fixed this. It passed on the code you mentioned and passed on all webkitpy test, but maybe this isn't the best regexp. I don't know that is there any other tricky way to use c++11 rvaule reference. Comment on attachment 217663 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=217663&action=review > Tools/Scripts/webkitpy/style/checkers/cpp.py:1848 > if matched: > - error(line_number, 'whitespace/operators', 3, > - 'Missing spaces around %s' % matched.group(1)) > + # It is necessary to check this because rvaule references > + # parameter packs (c++11 feature) > + if not search(r'&&\.\.\.', line): These two ifs could be merged together. (In reply to comment #9) > (From update of attachment 217663 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=217663&action=review > > > Tools/Scripts/webkitpy/style/checkers/cpp.py:1848 > > if matched: > > - error(line_number, 'whitespace/operators', 3, > > - 'Missing spaces around %s' % matched.group(1)) > > + # It is necessary to check this because rvaule references > > + # parameter packs (c++11 feature) > > + if not search(r'&&\.\.\.', line): > > These two ifs could be merged together. You are right, we could simplify this. Created attachment 218037 [details]
Patch
Comment on attachment 218037 [details]
Patch
cool, this looks better now :)
Comment on attachment 218037 [details]
Patch
r=me
Comment on attachment 218037 [details] Patch Clearing flags on attachment: 218037 Committed r160086: <http://trac.webkit.org/changeset/160086> All reviewed patches have been landed. Closing bug. Comment on attachment 218037 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=218037&action=review > Tools/Scripts/webkitpy/style/checkers/cpp.py:1845 > + # It is necessary to check this, because rvaule references can be in Typo here: rvaule. |