Alexander Udalov
214abea4d6
Minor, introduce DeclarationProviderFactory.EMPTY
2016-10-02 21:03:35 +03:00
Alexander Udalov
0ed9897b03
Minor refactorings related to PackagePartProvider and implementations
...
- Document what exactly should findPackageParts return
- Make EMPTY a named object instead of a val in the companion
- Do not use JvmPackagePartProvider in tests where Empty works fine
- Add a couple default values to arguments of setupResolverForProject
2016-10-02 21:03:34 +03:00
Alexander Udalov
97f2051a03
Add debugName to ModuleMapping
2016-10-02 21:03:33 +03:00
Alexander Udalov
74ad6b1410
Drop obsolete logic related to obsolete package parts
...
Filtering out obsolete package parts in incremental compilation was necessary
before the big refactoring of package parts, when package parts had been
compiled together into a package class
2016-10-02 21:03:31 +03:00
Alexander Udalov
610c549225
Filter out equivalent calls before reporting "none applicable"
...
If a module is configured in such a way that the same function appears multiple
times via different dependencies, it's not helpful to report "none of the
following functions can be called", listing the same function multiple times
2016-10-02 21:03:30 +03:00
Alexander Udalov
5d37fab4f5
Minor, add toString for debug
2016-10-02 21:03:29 +03:00
Alexander Udalov
74d6ef73d4
Prevent double initialization in codegen tests, fix ScriptGenTest#testDependentScripts
...
Add an assertion to prevent duplicate initialization of CodegenTestFiles
instance in CodegenTestCase, which was happening in ScriptGenTest with multiple
invocation of loadFile()
2016-10-02 21:03:28 +03:00
Alexander Udalov
9fb9c12f5e
Inline LazyTopDownAnalyzerForTopLevel#analyzeFiles
...
To make module initialization more explicit and configurable (especially in
TopDownAnalyzerFacadeForJVM)
2016-10-02 21:03:27 +03:00
Alexander Udalov
a5a874f23f
Move module creation into TopDownAnalyzerFacadeForJVM#analyzeFilesWithJavaIntegration
...
The only place where the logic has changed is in AbstractDiagnosticsTest, where
modules are already created and sealed before the analysis. Copy-paste the
container creation logic there (it's almost fine because it's also present in a
bunch of other tests), and simplify it: get rid of incremental compilation and
other stuff irrelevant for diagnostic tests.
This is needed to make analyzeFilesWithJavaIntegration configure the module
properly before sealing it
2016-10-02 21:03:27 +03:00
Alexander Udalov
596fdab2f2
Extract container for single-module top-down analysis
2016-10-02 21:03:26 +03:00
Alexander Udalov
2699356ce3
Simplify JavaClassFinderPostConstruct, inline javaAnalysisInit
2016-10-02 21:03:25 +03:00
Alexander Udalov
278941a8a1
Deduplicate code in container creation for JVM analysis
2016-10-02 21:03:24 +03:00
Alexander Udalov
0250ea861c
Simplify return types of createContainer* functions
2016-10-02 21:03:23 +03:00
Alexander Udalov
9cfe0be98e
Prettify TopDownAnalyzerFacadeFor{JVM,JS}
2016-10-02 21:03:22 +03:00
Alexander Udalov
4467e127f0
J2K TopDownAnalyzerFacadeFor{JVM,JS}: convert to Kotlin
2016-10-02 21:03:21 +03:00
Alexander Udalov
b34150e1ce
J2K TopDownAnalyzerFacadeFor{JVM,JS}: rename files
2016-10-02 21:03:21 +03:00
Alexander Udalov
be5e0f4275
Minor, improve exception when getting missing component from container
2016-10-02 21:03:20 +03:00
Alexander Udalov
87fe6c41df
Drop ExternalDeclarationsProvider
...
It was added for Android extensions, but now another mechanism is used there
(PackageFragmentProviderExtension), and there were no other implementations of
ExternalDeclarationsProvider in the project
2016-10-02 21:03:19 +03:00
Alexander Udalov
1d6abc32bc
Minor, delete ModuleContext#builtIns
2016-10-02 21:03:18 +03:00
Valentin Kipyatkov
a55273646a
Fixed check for convention operator
2016-09-30 21:37:48 +03:00
Valentin Kipyatkov
17adee68cd
Fixed optimize imports for operators
2016-09-30 21:37:47 +03:00
Mikhail Glukhikh
725df49c8c
KT-9839: intention introduced: convert secondary constructor to primary one #KT-9839 Fixed
...
(cherry picked from commit f3fa779)
2016-09-30 16:39:24 +03:00
Mikhail Glukhikh
7f50e6e70e
KT-9839: intention introduced: convert primary constructor to secondary one
...
(cherry picked from commit 93aaa48)
2016-09-30 16:39:01 +03:00
Denis Zharkov
d4418d5686
Prohibit not-Unit suspend functions
...
#KT-13560 Fixed
2016-09-30 12:25:59 +03:00
Denis Zharkov
96186c6217
Prohibit star-projections in last parameter of suspend functions
2016-09-30 12:25:59 +03:00
Dmitry Petrov
bd95d2ef4c
KT-14071 Type alias cannot be used as a qualifier for super
...
Use corresponding class for type alias in super qualifier resolution.
2016-09-30 10:17:30 +03:00
Vsevolod
ff7c7538d4
KT-13931 generate IntRange#contains with awareness of inverse in operator
2016-09-29 17:56:18 +03:00
Vsevolod
1ac07340c9
KT-13931 generate IntRange#contains with respect to side-effects on argument loading, test added
2016-09-29 17:56:18 +03:00
Vsevolod
1f9b148a5d
KT-13931 more compact inIntRange bytecode generation
2016-09-29 17:56:18 +03:00
Mikhail Glukhikh
f95dcad179
CFA minor: retain initialization state while analyzing variable declaration
...
(cherry picked from commit c89f4db)
2016-09-29 15:57:01 +03:00
Mikhail Glukhikh
436b0ec873
CFA merge for definition / initialization : more accurate handling of unknown variables #KT-13969 Fixed
...
(cherry picked from commit 4a96589)
2016-09-29 15:56:47 +03:00
Alexey Andreev
a18f5eca2d
JS: move more test to box tests
2016-09-29 12:00:41 +03:00
Simon Ogorodnik
18feb8f622
Return Kotlin fields and methods through KotlinShortNameCache
...
#KT-12205 Fixed
2016-09-28 13:36:20 +02:00
Denis Zharkov
bb1b8cca20
Fix AssertionError in CodegenUtil.getDelegates
...
Change getAllOverriddenDescriptors contracti, now it returns
original (not substituted) descriptors without any duplicates.
First of all it's necessary in CodegenUtil.getDelegates to avoid
duplicates (see assertion there), but also it's convenient for all
other usages of this method
#KT-8154 Fixed
2016-09-28 11:40:35 +03:00
Denis Zharkov
49fee026fc
Minor. Simplify CodegenUtil.getDelegates
2016-09-28 11:40:20 +03:00
Denis Zharkov
567b0cc8ea
Add a couple of covariant necessary overrides
...
They become unavoidable after checking override conflicts
for delegation members
2016-09-28 11:40:20 +03:00
Denis Zharkov
c884cffeea
Prohibit return type mismatch for delegation members
...
#KT-13952 Fixed
#KT-13005 Fixed
2016-09-28 11:40:20 +03:00
Denis Zharkov
ddb7a6aa13
Minor. Extract subinterface for specific strategy
...
It contains only methods related to explicitly declared overrides
2016-09-28 11:40:20 +03:00
Alexey Sedunov
22271f0af0
Pull Up/Push Down/Extract Super: Show member dependencies in the refactoring dialog
2016-09-27 21:26:29 +03:00
Alexey Sedunov
8a5628cde5
Pull Up/Extract Super: Support members declared in the companion object of the original class
2016-09-27 21:26:28 +03:00
Alexey Sedunov
982d4d4ead
Pull Up/Extract Super: Support properties declared in the primary constructor
2016-09-27 21:26:27 +03:00
Mikhail Glukhikh
025d063b27
UNNECESSARY_LATEINIT: do not report if property is not initialized at use-site #KT-13806 Fixed
...
(cherry picked from commit 09c0865)
2016-09-27 18:49:02 +03:00
Mikhail Glukhikh
4da9a101cf
UNNECESSARY_LATEINIT warning introduced #KT-13295 Fixed
...
(cherry picked from commit 88f9938)
2016-09-27 18:48:50 +03:00
Pavel V. Talanov
b275dacad8
Light classes: getOwnInnerClasses() filters out inner classes with null names
...
#KT-13927 Fixed
2016-09-26 19:51:57 +03:00
Pavel V. Talanov
32daf048c2
PlatformConfigurator: create container for each platform (it contains static services, mostly checkers) ahead of time
2016-09-26 14:42:57 +03:00
Pavel V. Talanov
be00a6ec49
StorageComponentContainer: allow to specify parent container which can be reused to provide components to several child containers
2016-09-26 14:35:37 +03:00
Alexander Udalov
33d33ab144
Exclude additional tests from Android codegen test runner
2016-09-24 11:31:59 +03:00
Alexander Udalov
9bc6d6ae92
Remove recursion workaround from DeprecatedClassifierUsageChecker
2016-09-24 11:26:57 +03:00
Alexander Udalov
dca99c3fd2
Move ClassifierUsageChecker invocation lower in LazyTopDownAnalyzer
...
Invoking checkers right after resolution of qualified expressions is too early:
DeprecatedClassifierUsageChecker tries to load the annotations of a referenced
classifier to report deprecation, and that may result in building light classes
for not yet analyzed declarations
#KT-13954 Fixed
2016-09-24 11:26:56 +03:00
Nikolay Krasko
0abf94c2f4
Allow to avoid rebuilding application in debugger tests on local machine
...
(cherry picked from commit 8b899a7)
2016-09-24 01:44:40 +03:00