mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 19:29:16 +00:00
LibWeb: Support fast_is<T>() for table, table sections, rows and cells
3.2x speed-up on WebKit/PerformanceTests/DOM/GridSort.html
This commit is contained in:
@@ -30,6 +30,8 @@ public:
|
||||
private:
|
||||
HTMLTableSectionElement(DOM::Document&, DOM::QualifiedName);
|
||||
|
||||
virtual bool is_html_table_section_element() const override { return true; }
|
||||
|
||||
virtual void initialize(JS::Realm&) override;
|
||||
virtual void visit_edges(Cell::Visitor&) override;
|
||||
|
||||
@@ -37,3 +39,8 @@ private:
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
namespace Web::DOM {
|
||||
template<>
|
||||
inline bool Node::fast_is<HTML::HTMLTableSectionElement>() const { return is_html_table_section_element(); }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user