Make named window lookup more precise and correct BCG swap logic by kjmcnee · Pull Request #10818 · whatwg/html (original) (raw)

I did a more detailed review, and this is looking great. I guess we might have missed you, so we'll probably have to finish this ourselves, but if you're able to help, one thing that would be very nice would be a clearer documentation of the implementation-defined cases.

Hi. I'm no longer at my work computer, but I can comment on the implementation differences.

WebKit and Chromium search the requesting window's subtree then search from the top. Firefox iterates and searches from each ancestor. If there's a way to express in the spec that the implementation-defined behavior is fixed for the instance of the user agent, then that'd be appropriate here.

Firefox and Chromium do this. WebKit does not. Similarly, the choice is fixed for the implementation.

I can't remember the details, but I think Chromium and Firefox are based on creation order, or maybe reverse creation order. WebKit's ordering is arbitrary as it iterates over a hash set.