Avoid looking at invalidation sets in a SubtreeStyleChange subtree

We were matching all the rulesets in a subtree even after finding a ruleset
that would invalidate the whole subtree which is wasted work. We were also
storing all the invalidation sets for an element even after one of them
would have invalidated the entire subtree.

This patch makes us only ever store one invalidation set for an element once
one of them would invalidate the whole subtree. It also removes the
foundInvalidationSet() bit since that's identical to just checking if the
Vector of invalidation sets is non-empty.

I also removed an ASSERT(renderer->style()), all renderers have a style, so
there's no reason to check this.

Review URL: https://codereview.chromium.org/233243003

git-svn-id: svn://svn.chromium.org/blink/trunk@171417 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Use ScriptPromiseResolverWithContext.

Use ScriptPromiseResolverWithContext instead of a pair of
ScriptPromiseResolver and NewScriptState.
This CL doen't change the behavior in many cases: The only exception
is when the resolution / rejection happens on the suspended or stopped
ExecutionContext. In such a case, ScriptPromiseResolver suspends or stops
resolution or rejection.

R=ksakamoto@chromium.org
BUG=352552

Review URL: https://codereview.chromium.org/236123007

git-svn-id: svn://svn.chromium.org/blink/trunk@171418 bbb929c8-8fbe-4397-9dbb-9b2b20218538