[ES6 modules] Implement #concept-module-script-has-instantiated

This CL introduces ModuleScript::HasInstantiated(), which implements
spec concept: "#concept-module-script-has-instantiated"
This will replace usage of ModuleScript::state_ comparison to kInstantiated
after we switch to the new #internal-module-script-graph-fetching procedure
proposed in the linked PRs.

This codepath will be tested in modulator infra unit tests after
the #internal-module-script-graph-fetching update.

Bug: 594639, 727299, https://github.com/whatwg/html/pull/2674 , https://github.com/tc39/ecma262/pull/916
Change-Id: Icdcc21cf00b1e47a35e747d85dd5af7907dc5a2a
Reviewed-on: https://chromium-review.googlesource.com/558166
Commit-Queue: Kouhei Ueno <kouhei@chromium.org>
Reviewed-by: Kinuko Yasuda <kinuko@chromium.org>
Cr-Commit-Position: refs/heads/master@{#483904}
2 files changed