Commit 122f84f3 authored by philipj's avatar philipj Committed by Commit bot

Sync the URL constructor with the spec

https://url.spec.whatwg.org/#api

This changes the generated code, but ought not be observable, as any
call to `new URL(x, urlObject)` will now instead behaves as
`new URL(x, urlObject.toString())`.

BUG=460722

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

Cr-Commit-Position: refs/heads/master@{#361342}
parent 76009229
......@@ -52,11 +52,6 @@ public:
{
return new DOMURL(url, KURL(KURL(), base), exceptionState);
}
static DOMURL* create(const String& url, DOMURL* base, ExceptionState& exceptionState)
{
ASSERT(base);
return new DOMURL(url, base->m_url, exceptionState);
}
static String createObjectURL(ExecutionContext*, Blob*, ExceptionState&);
static void revokeObjectURL(ExecutionContext*, const String&);
......
......@@ -27,11 +27,7 @@
// https://url.spec.whatwg.org/#url
[
// TODO(philipj): There should only be one constructor:
// Constructor(USVString url, optional USVString base)
Constructor(USVString url),
Constructor(USVString url, USVString base),
Constructor(USVString url, URL base),
Constructor(USVString url, optional USVString base),
Exposed=(Window,Worker),
ImplementedAs=DOMURL,
RaisesException=Constructor,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment