Commit Graph

721 Commits

Author SHA1 Message Date
Michael Nedzelsky 999c83240c JS: error message (not exception) for incompatible abi version during compilation 2015-06-10 05:37:57 +03:00
Dmitry Jemerov 34577a7e12 add test for ReferencesSearch; use standard isReferenceTo() API (which is the same thing for Kotlin but more efficient for non-Kotlin references) 2015-06-09 20:45:11 +02:00
Dmitry Jemerov 7d02b522db KotlinReferencesSearcher: remove enclosing read action, use queryParameters.getOptimizer().searchWord
#KT-7917 Fixed
2015-06-09 20:45:10 +02:00
Dmitry Jemerov 527751e967 KotlinReferencesSearcher: cleanup after J2K 2015-06-09 20:45:10 +02:00
Dmitry Jemerov b2a6531255 KotlinReferencesSearcher: J2K 2015-06-09 20:45:09 +02:00
Dmitry Jemerov 7ba13e5425 KotlinReferencesSearcher: rename to .kt 2015-06-09 20:45:09 +02:00
Pavel V. Talanov 07d35d305e Create import list psi element even if no directives are present
Fix a problem where deleting last import directive via "optimize imports" could lead to incorrect psi structure resulting in CCE, see EA-64291
New imports are inserted at the head (after package directive if present) of the file (before any comments) if no imports were present
Add test for inserting import to file where a first statement is a comment
Drop code dealing with non-existing import list in ImportInsertHelperImpl
AbstractQuickFixTest: check for unexpected actions before changes to the file are made as it relies on the first line having specific format
2015-06-08 20:51:04 +03:00
Pavel V. Talanov d3315f5ebb Refactor: Do not pass rootScope to QualifiedExpressionResolver#processImportReference 2015-06-08 20:25:54 +03:00
Pavel V. Talanov be66ee7015 Refactor QualifiedExpressionResolver: pass descriptor to check for visibility instead of scope 2015-06-08 20:25:51 +03:00
Valentin Kipyatkov 63b30cf7f6 KT-7955 "Add replaceWith to specify replacement pattern" intention/inpesction has too large a range
#KT-7955 Fixed
2015-06-08 15:37:58 +03:00
Pavel V. Talanov 812273cb2b Fix a problem when invoking completion outside of source roots could lead to declarations from index being analyzed in a wrong resolution facade 2015-06-04 18:36:05 +03:00
Valentin Kipyatkov 4169a78e6f Removing unnecessary uses of analyzeFully 2015-06-04 01:05:49 +03:00
Valentin Kipyatkov 662cc325f4 Never invoke intention action when it's not available 2015-06-04 01:05:48 +03:00
Pavel V. Talanov f335e9f6b2 Fix a problem where a sequence of out-of-block completions could lead to an inconsistent resolve session provided for a synthetic copy of a file 2015-06-03 21:22:10 +03:00
Pavel V. Talanov 04bef2cc08 Minor: Drop unused code and inline utility 2015-06-02 19:19:57 +03:00
Pavel V. Talanov 7f70a4ae89 Minor: extract implementation of ResolutionFacade to a separate class 2015-06-02 15:32:02 +03:00
Pavel V. Talanov a94c13be6d KotlinCacheService: allow to get ResolveSessionForBodies by module descriptor
Utility to resolve import in file by fq name
2015-06-02 15:32:01 +03:00
Valentin Kipyatkov f1d8838bbd Removed code duplication for getting annotation argument 2015-06-02 14:36:05 +03:00
Valentin Kipyatkov aefe0dd192 Changed highlighting range and attributes of useless elvis operator 2015-06-02 14:35:19 +03:00
Valentin Kipyatkov 8fd6a64be9 Refactored methods for val/var in PSI 2015-06-01 18:23:34 +03:00
Valentin Kipyatkov 034b74d3e5 Rewritten ChangeVariableMutabilityFix
#KT-7877 Fixed
2015-06-01 18:23:34 +03:00
Valentin Kipyatkov 494d96bbc7 Refactored PsiElement.parents() into 2 properties 2015-05-29 13:55:46 +03:00
Mikhail Glukhikh fe49a2ee51 Build fix 2015-05-27 23:40:40 +02:00
Dmitry Jemerov a41205fff7 Allow calling KotlinCacheService.getResolutionFacade() with an empty set of Kotlin files.
This is needed in Dokka, where a project to be documented can contain only Java files, but we will still attempt to resolve links in Markdown files containing package documentation through the KDoc reference resolver. The attempts will fail when there are no Kotlin files, but at least we won't crash trying to retrieve the first element of an empty list.
2015-05-27 19:22:19 +02:00
Denis Zharkov be9cc2e91b Change color scheme for annotations
Use same color as for modifiers, but with plain font type
2015-05-27 17:41:27 +03:00
Ilya Gorbunov 0c818767a6 Replace usages of renamed overloads annotation. 2015-05-27 17:26:07 +03:00
Dmitry Jemerov 966df199bb move KDocFinder to idea-analysis package 2015-05-27 15:41:47 +02:00
Valentin Kipyatkov 1d16b76a42 Minor corrections after code review 2015-05-27 16:15:54 +03:00
Valentin Kipyatkov 8e16ddb00e Minor 2015-05-27 16:15:51 +03:00
Valentin Kipyatkov a7580d95e5 Accessing of default parameter value in compiled code via source (if found) 2015-05-27 16:15:50 +03:00
Valentin Kipyatkov be9a3d10f6 DeprecatedSymbolUsageFix: fixed bug with symbols from root package not imported 2015-05-27 16:15:48 +03:00
Valentin Kipyatkov df850d7035 DeprecatedSymbolUsageFix: initial implementation 2015-05-27 16:15:45 +03:00
Valentin Kipyatkov 0a886320ca JetWholeProjectForEachElementOfTypeFix - not too much duplicating string arguments 2015-05-27 16:15:45 +03:00
Valentin Kipyatkov 25e323e960 Methods for editing in JetValueArgumentList 2015-05-27 16:15:44 +03:00
Valentin Kipyatkov 1e60c24134 Added ResolutionFacada.resolveImportReference and used it (but not all places replaced yet!!) 2015-05-27 16:15:44 +03:00
Sergey Mashkov 6e444baedb Indexer advance() should check previousTokens size before look inside
fixes IndexOutOfBounds during indexing
2015-05-27 15:32:00 +03:00
Alexey Sedunov 036e2c585b Refactoring: Introduce getReferenceTargets() function 2015-05-26 19:28:11 +03:00
Alexander Udalov 48b18f18d3 Restore explicit imports of Kotlin function types in Java
This is a follow-up to 738a84e259 and
d4965a4f3e. Optimize imports in all files
affected in those commits, drop temporary _.kt
2015-05-26 18:46:27 +03:00
Dmitry Jemerov 6e7ea662c8 "Code Cleanup" action to migrate all instances of deprecated syntax to new one 2015-05-26 14:41:21 +02:00
Alexander Udalov 49004a8b8e Conform functions to extension functions and vice versa
#KT-5989 Fixed
2015-05-26 15:04:56 +03:00
Alexander Udalov 4141e0a8df Introduce fictitious numbered Function class descriptors 2015-05-26 15:04:54 +03:00
Alexander Udalov 738a84e259 Temporary hack to migrate functions to package kotlin.jvm.functions
Add a file in package 'kotlin.jvm.functions' to the project and replace
explicit imports of functions 'kotlin.Function{n}' to two imports 'kotlin.*'
and 'kotlin.jvm.functions.*', so that the codebase can be compiled both by the
old and by the new compiler
2015-05-26 15:04:34 +03:00
Michael Nedzelsky ac01dd6996 JsAnalyzerFacade: use only metadata from library modules 2015-05-26 05:04:30 +03:00
Michael Nedzelsky 484a73c17e JsHeaderLibraryDetectionUtil -> KotlinJavaScriptLibraryDetectionUtil
JsHeaderLibraryPresentationProvider -> KotlinJavaScriptLibraryPresentationProvider
2015-05-26 05:04:28 +03:00
Michael Nedzelsky ebcc29b907 PluginDeclarationProviderFactoryService: remove special treatment for Kotlin/Javascript projects 2015-05-26 05:04:25 +03:00
Michael Nedzelsky 23da4f0897 JS: KotlinJavascriptMetaFileDecompiler -> KotlinJavaScriptMetaFileDecompiler 2015-05-26 05:04:23 +03:00
Michael Nedzelsky a0579ebedd add KotlinJavaScriptStubBuilder 2015-05-26 05:04:20 +03:00
Michael Nedzelsky ea9d7ed49a DecompiledTextFactory: new implementation of buildDecompiledTextFromJsMetadata 2015-05-26 05:04:17 +03:00
Michael Nedzelsky 18afa8f2d5 add KotlinJavaScriptDeserializeForDecompiler 2015-05-26 05:04:15 +03:00
Michael Nedzelsky f1a0d86f87 JsMetaFileUtils: add some useful code, remove unnecessary parts 2015-05-26 05:04:12 +03:00