Nikolay Krasko
e3f85653e9
Don't request write action for RemoveUnusedFunctionParameterFix because it's based on refactoring (KT-12440)
...
Workaround for exception: Refactorings should not be started inside write action because they start progress inside and any read action from the progress task would cause the deadlock
#KT-12440 Fixed
2016-05-24 17:22:56 +03:00
Nikolay Krasko
01a6ce930e
Don't request write action for ReplaceExplicitFunctionLiteralParamWithItIntention because it's based on refactoring (KT-12436)
...
Workaround for exception: Refactorings should not be started inside write action because they start progress inside and any read action from the progress task would cause the deadlock
#KT-12436 Fixed
2016-05-24 17:22:56 +03:00
Pavel V. Talanov
6b001c608b
ProjectRootsUtil: accept directories and jar roots if "includeClassFiles == true"
2016-05-24 15:42:11 +03:00
Pavel V. Talanov
c7cefad7d5
Implement IdeReplCompletionTest to test completion of entities declared in already evaluated lines
2016-05-24 15:42:09 +03:00
Pavel V. Talanov
f59638d60f
Minor: prettify ReplState
2016-05-24 15:42:08 +03:00
Pavel V. Talanov
9cff590366
Use ReplState to implement completion in IDE REPL
...
Consider sucessfully evaluated lines as previous lines when analyzing console file
2016-05-24 15:42:06 +03:00
Pavel V. Talanov
08ef1749b6
Limit resolve scope when completing in module sources
2016-05-24 15:42:04 +03:00
Pavel V. Talanov
4ec4d6ec66
implicitReceiversUtils: Script descriptors are implicit receivers
...
This fixes completion in repl
2016-05-24 15:42:02 +03:00
Pavel V. Talanov
dcd7e6d767
Move ReplState to frontend
2016-05-24 15:42:00 +03:00
Pavel V. Talanov
4d75355cf2
Minor: Rename KotlinReplTest
2016-05-24 15:41:58 +03:00
Pavel V. Talanov
5058e9b4e6
Fix import resolution in Repl
...
#KT-11428 Fixed
Refactor ReplState to be a component
2016-05-24 15:41:56 +03:00
Pavel V. Talanov
9f67072098
Minor: ScopeUtils: avoid wrapping lexical scopes several times
2016-05-24 15:41:55 +03:00
Pavel V. Talanov
27bd74f4c5
Refactor: replace LastLineScopeProvider with ReplState, extract FileScopeFactory from FileScopeProviderImpl
2016-05-24 15:41:30 +03:00
Pavel V. Talanov
3b4ade2ca0
Refactor: extract resolve related code from ReplInterpreter to CliReplAnalyzerEngine
2016-05-24 15:36:12 +03:00
Alexander Udalov
68f1cf5f52
Fix typo in inspection description name: RedundantlIf.html -> RedundantIf.html
2016-05-24 15:03:04 +03:00
Mikhail Glukhikh
9e487a6326
Minor refactoring: convert to block body
2016-05-24 14:31:51 +03:00
Mikhail Glukhikh
fa5e284bf8
Convert to block body: when expression with Unit result is now handled as "return needed" #KT-12193 Fixed
2016-05-24 14:29:01 +03:00
Mikhail Glukhikh
9a69b8b7b5
REDUNDANT_OPEN_FOR_INTERFACE warning: reported for open members without implementation #KT-12452 Fixed
2016-05-24 14:25:27 +03:00
Mikhail Glukhikh
e66acd8101
Default modality is abstract for interface. REDUNDANT_MODIFIER_FOR_TARGET applicability reduced #KT-12302 Fixed
2016-05-24 14:25:22 +03:00
Mikhail Glukhikh
93defed324
KT-12302: ABSTRACT_MODIFIER_IN_INTERFACE warning is removed as obsolete
2016-05-24 14:25:18 +03:00
Dmitry Jemerov
3542834fa1
fix tests for RedundantIfInspection
2016-05-23 20:21:46 +02:00
Vladislav Golub
bb32c2d350
KT-12019 Highlighting of redundant 'if' statements ( #871 )
2016-05-23 21:02:38 +03:00
Vladislav Golub
cf56ac0305
Simplify method ( #873 )
2016-05-23 20:53:42 +03:00
Alexander Udalov
5bf14c106a
Delete unused ParentLastURLClassLoader
2016-05-23 20:00:51 +03:00
Alexander Udalov
b9fb6c0d84
Remove dangerous readKotlinHeader() in inlineUtil.kt
...
It was creating a phantom FileBasedKotlinClass which was not based on any file
2016-05-23 20:00:50 +03:00
Alexander Udalov
cf19166eca
Move IC-related initialization logic to GenerationState
...
To further reduce number of parameters of GenerationState's constructor
2016-05-23 14:50:06 +03:00
Alexander Udalov
29c5e655ab
Drop several more parameters of GenerationState's constructor
...
INCREMENTAL_COMPILATION_COMPONENTS and DECLARATIONS_JSON_PATH are already in
the configuration, and Progress was unused
2016-05-23 14:50:06 +03:00
Alexander Udalov
f8816b5d67
Pass CompilerConfiguration to GenerationState instead of ton of parameters
2016-05-23 14:49:26 +03:00
Alexander Udalov
1492c71e88
Refactor old test utility in LoadDescriptorUtil
...
Also make USE_TYPE_TABLE a flag in CompilerConfiguration instead of an extra
boolean parameter in numerous methods
2016-05-23 14:47:00 +03:00
Alexander Udalov
76d78ba666
Remove LazyResolveTestUtil, refactor usages to use JvmResolveUtil
...
LazyResolveTestUtil.resolve by now had almost exactly the same code as
JvmResolveUtil.analyze.
LazyResolveTestUtil.resolveLazily with 3 parameters was only used in
LoadBuiltinsTest, inline it there.
Move LazyResolveTestUtil.getTopLevelPackagesFromFileList to
AbstractDiagnosticsTest, the only place where it was used
2016-05-23 14:47:00 +03:00
Alexander Udalov
a85e98a078
Minor, inline unnecessary method of TopDownAnalyzerFacadeForJVM
...
The TopDownAnalysisMode parameter was TopLevelDeclarations everywhere
2016-05-23 14:47:00 +03:00
Alexander Udalov
0124cb64f0
Cleanup test utilities in JvmResolveUtil and GenerationUtils
...
Simplify usages and fix some warnings along the way.
Rename:
- analyzeFilesWithJavaIntegration, analyzeOneFileWithJavaIntegration -> analyze
- analyzeFilesWithJavaIntegrationAndCheckForErrors,
analyzeOneFileWithJavaIntegrationAndCheckForErrors -> analyzeAndCheckForErrors
- compileFilesGetGenerationState, compileManyFilesGetGenerationStateForTest ->
compileFiles
- compileFileGetGenerationStateForTest -> compileFile
- compileFileGetClassFileFactoryForTest -> compileFileTo
2016-05-23 14:47:00 +03:00
Alexander Udalov
8a00cabce6
Minor, do not copy CompilerConfiguration in Android codegen tests
...
This is needed to avoid passing a custom configuration to
GenerationUtils.compileManyFilesGetGenerationStateForTest, but rather take it
from the environment in a future commit
2016-05-23 14:47:00 +03:00
Alexander Udalov
6d6488e795
Pass CompilerConfiguration to TopDownAnalyzerFacadeForJVM
...
In most cases, the configuration can be loaded from KotlinCoreEnvironment. In
other cases, such as IDE tests, there's no environment, so we pass EMPTY. Since
currently the configuration is only used to load incremental compilation
components and module information, it's fine to pass EMPTY
2016-05-23 14:47:00 +03:00
Alexander Udalov
6c0ff40197
Move JVMConfigurationKeys to frontend.java
...
Similarly to K2JVMCompilerArguments, they will soon be needed in the IDE code.
Move COMPILER_JAR_LOCATOR to CLIConfigurationKeys because it's used both in JVM
and JS, and only in CLI. Other keys, non-relevant in the IDE, may be moved out
soon as well, such as incremental compilation components
2016-05-23 14:47:00 +03:00
Alexander Udalov
dcb2d7b4f6
Minor, break the line in "kotlinc -help" if it's too long
...
To improve description of the "pluginOptions" flag
2016-05-23 14:47:00 +03:00
Mikhail Glukhikh
1a8181bdc4
Only private constructors for sealed / enum classes #KT-12377 Fixed
...
Also #KT-8497 Fixed
2016-05-23 13:08:57 +03:00
Mikhail Glukhikh
cffdce908e
Annotation parameters now cannot be mutable #KT-12367 Fixed
2016-05-23 13:04:00 +03:00
Alexey Andreev
81bdd6b4bb
JS: improve performance of Hashtable-based collections
2016-05-23 12:23:27 +03:00
Alexey Andreev
f0ee52faaf
KT-11086 Treat initializer of a companion object as a class initializer
2016-05-23 12:22:50 +03:00
Alexey Andreev
c5eaea846d
KT-7424: add test to show that inlining works for anonymous functions
2016-05-23 12:22:50 +03:00
Alexey Andreev
db5baf7fa7
KT-8386: pass mutable list to JsInvocation from intrinsic generator, so that inliner had a chance to replace arguments
2016-05-23 12:22:50 +03:00
Pavel V. Talanov
d03fedde74
Implement "Decompile Kotlin to Java" action
...
Add this action to "Attach sources" notification panel if present
#KT-11657 Fixed
2016-05-23 12:12:13 +03:00
Pavel V. Talanov
68dd176d66
Minor: typo in changeLog
2016-05-23 11:54:16 +03:00
Pavel V. Talanov
6e9a35b432
Minor, missed '#'
2016-05-23 11:54:14 +03:00
Pavel V. Talanov
7606b4c69d
Update ChangeLog for 1.0.3
...
Improve ticket number presentation for 1.0.3
2016-05-23 11:54:12 +03:00
Dmitry Petrov
968ed3f091
KT-5068: Introduce a special diagnostic message for TYPE_MISMATCH cases such as 'fun f(): Int = { 1 }'.
2016-05-23 09:50:41 +03:00
Nikolay Krasko
8b06d919b4
Restore packing plugin-api module output to plugin
2016-05-20 19:40:07 +03:00
Nikolay Krasko
58d24d76c4
Check there's no direct usages of asm (org.objectweb.asm) library in project
...
Such usages should be replaced with asm from idea (org.jetbrains.org.objectweb.asm)
2016-05-20 15:51:57 +03:00
Nikolay Krasko
a801d8fa6f
Don't use reference to asm directly. Use asm from Idea instead.
2016-05-20 15:51:55 +03:00