WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
126418
Add toHTMLTableSectionElement() functions, and use it
https://bugs.webkit.org/show_bug.cgi?id=126418
Summary
Add toHTMLTableSectionElement() functions, and use it
Gyuyoung Kim
Reported
2014-01-02 22:37:30 PST
When 9 generating toFoo(), we can use more plenty of helper functions. This patch generate toHTMLTableElement() using existing templates.
Attachments
Patch
(4.47 KB, patch)
2014-01-02 22:38 PST
,
Gyuyoung Kim
no flags
Details
Formatted Diff
Diff
Patch
(5.20 KB, patch)
2014-01-03 01:42 PST
,
Gyuyoung Kim
no flags
Details
Formatted Diff
Diff
Patch
(5.20 KB, patch)
2014-01-03 01:43 PST
,
Gyuyoung Kim
no flags
Details
Formatted Diff
Diff
Patch
(4.11 KB, patch)
2014-01-07 01:44 PST
,
Gyuyoung Kim
no flags
Details
Formatted Diff
Diff
Show Obsolete
(3)
View All
Add attachment
proposed patch, testcase, etc.
Gyuyoung Kim
Comment 1
2014-01-02 22:38:23 PST
Created
attachment 220280
[details]
Patch
Gyuyoung Kim
Comment 2
2014-01-02 22:39:13 PST
CC'ing Kling.
Andreas Kling
Comment 3
2014-01-02 23:25:21 PST
Comment on
attachment 220280
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=220280&action=review
> Source/WebCore/ChangeLog:3 > + Generate toHTMLTableElement(), and use it
This patch seems to be about toHTMLTableSectionElement(), not toHTMLTableElement().
> Source/WebCore/html/HTMLTagNames.in:121 > -tbody interfaceName=HTMLTableSectionElement > +tbody interfaceName=HTMLTableSectionElement, generateTypeHelpers
HTMLTableSectionElement can have one of three tags: <thead>, <tbody> or <tfoot>. This would generate an isHTMLTableSectionElement() that only returns true for <tbody>.
Gyuyoung Kim
Comment 4
2014-01-03 00:35:20 PST
Comment on
attachment 220280
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=220280&action=review
>> Source/WebCore/ChangeLog:3 >> + Generate toHTMLTableElement(), and use it > > This patch seems to be about toHTMLTableSectionElement(), not toHTMLTableElement().
Oops. my mistake.
>> Source/WebCore/html/HTMLTagNames.in:121 >> +tbody interfaceName=HTMLTableSectionElement, generateTypeHelpers > > HTMLTableSectionElement can have one of three tags: <thead>, <tbody> or <tfoot>. > This would generate an isHTMLTableSectionElement() that only returns true for <tbody>.
Ah, right. I forget it. I'm sorry. If so, how about adding manual toHTMLTableSectionElement() for HTMLTableSectionElement ?
Gyuyoung Kim
Comment 5
2014-01-03 01:42:24 PST
Created
attachment 220293
[details]
Patch
Gyuyoung Kim
Comment 6
2014-01-03 01:43:56 PST
Created
attachment 220294
[details]
Patch
Gyuyoung Kim
Comment 7
2014-01-03 02:38:56 PST
kling, how about this latest one ?
WebKit Commit Bot
Comment 8
2014-01-06 21:11:13 PST
Comment on
attachment 220294
[details]
Patch Clearing flags on attachment: 220294 Committed
r161401
: <
http://trac.webkit.org/changeset/161401
>
WebKit Commit Bot
Comment 9
2014-01-06 21:11:17 PST
All reviewed patches have been landed. Closing bug.
Alexey Proskuryakov
Comment 10
2014-01-06 22:24:59 PST
This broke dozens of tests, which crash now.
http://build.webkit.org/results/Apple%20Mavericks%20Debug%20WK1%20(Tests)/r161401%20(1535)/results.html
Gyuyoung Kim
Comment 11
2014-01-06 23:08:12 PST
Reverted
r161401
for reason: REGRESSION(
r161401
): Break layout test on mac-wk1(Debug) Committed
r161408
: <
http://trac.webkit.org/changeset/161408
>
Andreas Kling
Comment 12
2014-01-06 23:17:17 PST
Comment on
attachment 220294
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=220294&action=review
Can't this just use NODE_TYPE_CASTS instead? SVGSMILElement does something similar.
> Source/WebCore/html/HTMLTableSectionElement.h:66 > + return node.hasTagName(HTMLNames::trTag) || node.hasTagName(HTMLNames::tfootTag) || node.hasTagName(HTMLNames::tbodyTag);
trTag should be theadTag here.
> Source/WebCore/html/HTMLTableSectionElement.h:94 > +inline HTMLTableSectionElement* toHTMLTableSectionElement(Node* node) > +{ > + ASSERT_WITH_SECURITY_IMPLICATION(!node || isHTMLTableSectionElement(*node)); > + return static_cast<HTMLTableSectionElement*>(node); > +} > + > +inline const HTMLTableSectionElement* toHTMLTableSectionElement(const Node* node) > +{ > + ASSERT_WITH_SECURITY_IMPLICATION(!node || isHTMLTableSectionElement(*node)); > + return static_cast<const HTMLTableSectionElement*>(node); > +} > + > +inline HTMLTableSectionElement& toHTMLTableSectionElement(Node& node) > +{ > + ASSERT_WITH_SECURITY_IMPLICATION(isHTMLTableSectionElement(node)); > + return static_cast<HTMLTableSectionElement&>(node); > +} > + > +inline const HTMLTableSectionElement& toHTMLTableSectionElement(const Node& node) > +{ > + ASSERT_WITH_SECURITY_IMPLICATION(isHTMLTableSectionElement(node)); > + return static_cast<const HTMLTableSectionElement&>(node); > +} > + > +void toHTMLTableSectionElement(const HTMLTableSectionElement*); > +void toHTMLTableSectionElement(const HTMLTableSectionElement&);
Can't
Gyuyoung Kim
Comment 13
2014-01-07 01:44:23 PST
Created
attachment 220504
[details]
Patch
Gyuyoung Kim
Comment 14
2014-01-07 01:45:45 PST
(In reply to
comment #12
)
> (From update of
attachment 220294
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=220294&action=review
> > Can't this just use NODE_TYPE_CASTS instead? SVGSMILElement does something similar.
There were many faults. I updated this patch according to your suggestion. Thanks.
WebKit Commit Bot
Comment 15
2014-01-07 05:58:23 PST
Comment on
attachment 220504
[details]
Patch Clearing flags on attachment: 220504 Committed
r161420
: <
http://trac.webkit.org/changeset/161420
>
WebKit Commit Bot
Comment 16
2014-01-07 05:58:26 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug