dart-sdk/tools/dom
Stephen Adams f997d62a6d [html] Better code for Element / _ChildrenElementList method
Two tricks let us compile this more efficiently:

    e.children.addAll(cs);

Normally, get$children is inlined, returning a _ChildrenElementList
wrapper, generating:

     new W._ChildrenElementList(e, e.children).addAll$1(0, cs);

The two tricks:

1. Split _ChildElementList.addAll into an 'unwrap' that then calls the
   logic in '_addAll'

2. Add information about the properties of e.children that allow it to
   be removed.

With these tricks, dart2js can optimize the code to this version that
avoids allocating a wrapper or accessing the 'children' property:

     W._ChildrenElementList__addAll(e, cs);

Change-Id: Ifdf533ac4f9790f09f87302e67304b5696097266
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/153904
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2020-07-13 20:33:19 +00:00
..
docs [dart:html] Add track event to RTCPeerConnection 2020-06-12 00:42:36 +00:00
idl/dart [dart:html] Make browser-incompatible attributes nullable 2020-05-16 03:47:12 +00:00
new_scripts Mass format python with yapf 2019-08-05 20:34:31 +00:00
scripts [html] Better code for Element / _ChildrenElementList method 2020-07-13 20:33:19 +00:00
src [dart:html] Revert commits using MDN compatibility info 2020-07-02 01:33:18 +00:00
templates [html] Better code for Element / _ChildrenElementList method 2020-07-13 20:33:19 +00:00
.gitignore Moved most of html lib generating scripts into tools. 2012-12-28 22:26:48 +00:00
dom.json Fixed a number of dart:html P1 issues. 2019-01-15 17:21:50 +00:00
dom.py Mass format python with yapf 2019-08-05 20:34:31 +00:00
PRESUBMIT.py Mass format python with yapf 2019-08-05 20:34:31 +00:00