Ignore:
Timestamp:
Oct 20, 2017, 10:58:32 AM (8 years ago)
Author:
Matt Lewis
Message:

Unreviewed, rolling out r223744, r223750, and r223751.
https://bugs.webkit.org/show_bug.cgi?id=178594

These caused consistent failures in test that existed and were
added in the patches. (Requested by mlewis13 on #webkit).

Reverted changesets:

"[JSC] ScriptFetcher should be notified directly from module
pipeline"
https://bugs.webkit.org/show_bug.cgi?id=178340
https://trac.webkit.org/changeset/223744

"Unreviewed, fix changed line number in test expect files"
https://bugs.webkit.org/show_bug.cgi?id=178340
https://trac.webkit.org/changeset/223750

"Unreviewed, follow up to reflect comments"
https://bugs.webkit.org/show_bug.cgi?id=178340
https://trac.webkit.org/changeset/223751

Patch by Commit Queue <[email protected]> on 2017-10-20

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/runtime/JSModuleLoader.cpp

    r223751 r223777  
    4040#include "JSModuleEnvironment.h"
    4141#include "JSModuleRecord.h"
    42 #include "JSScriptFetcher.h"
    4342#include "JSSourceCode.h"
    4443#include "ModuleAnalyzer.h"
     
    293292}
    294293
    295 static Identifier jsValueToModuleKey(ExecState* exec, JSValue value)
    296 {
    297     if (value.isSymbol())
    298         return Identifier::fromUid(jsCast<Symbol*>(value)->privateName());
    299     ASSERT(value.isString());
    300     return asString(value)->toIdentifier(exec);
    301 }
    302 
    303 JSValue JSModuleLoader::notifyCompleted(ExecState* exec, JSValue scriptFetcher, JSValue key)
    304 {
    305     auto* fetcherWrapper = jsDynamicCast<JSScriptFetcher*>(exec->vm(), scriptFetcher);
    306     if (!fetcherWrapper)
    307         return jsUndefined();
    308     auto* fetcher = fetcherWrapper->fetcher();
    309     if (!fetcher)
    310         return jsUndefined();
    311 
    312     auto moduleKey = jsValueToModuleKey(exec, key);
    313     fetcher->notifyLoadCompleted(*moduleKey.impl());
    314     return jsUndefined();
    315 }
    316 
    317 JSValue JSModuleLoader::notifyFailed(ExecState* exec, JSValue scriptFetcher, JSValue errorValue)
    318 {
    319     auto* fetcherWrapper = jsDynamicCast<JSScriptFetcher*>(exec->vm(), scriptFetcher);
    320     if (!fetcherWrapper)
    321         return jsUndefined();
    322     auto* fetcher = fetcherWrapper->fetcher();
    323     if (!fetcher)
    324         return jsUndefined();
    325     fetcher->notifyLoadFailed(exec, errorValue);
    326     return jsUndefined();
    327 }
    328 
    329294} // namespace JSC
Note: See TracChangeset for help on using the changeset viewer.