Refactor: TopDownAnalysisParameters doesn't implement GlobalContext

This commit is contained in:
Pavel V. Talanov
2015-05-15 13:42:29 +03:00
parent f18b9caa8d
commit f9b6c25498
12 changed files with 42 additions and 104 deletions
@@ -79,13 +79,13 @@ public final class TopDownAnalyzerFacadeForJS {
GlobalContextImpl globalContext = ContextPackage.GlobalContext();
TopDownAnalysisParameters topDownAnalysisParameters = TopDownAnalysisParameters.create(
globalContext.getStorageManager(), globalContext.getExceptionTracker(), false, false);
false, false);
Collection<JetFile> allFiles = Config.withJsLibAdded(files, config);
InjectorForTopDownAnalyzerForJs injector = new InjectorForTopDownAnalyzerForJs(
project, topDownAnalysisParameters, trace, module,
new FileBasedDeclarationProviderFactory(topDownAnalysisParameters.getStorageManager(), allFiles));
project, globalContext, trace, module,
new FileBasedDeclarationProviderFactory(globalContext.getStorageManager(), allFiles));
try {
injector.getLazyTopDownAnalyzerForTopLevel().analyzeFiles(topDownAnalysisParameters, files,
Collections.<PackageFragmentProvider>emptyList());