Commit Graph

274 Commits

Author SHA1 Message Date
Pavel V. Talanov 640d2de5b9 Fix incorrect reference target for class literals in some cases 2015-03-03 13:04:27 +03:00
Nikolay Krasko f3919db592 Find usages and reference to delegation origin 2015-02-24 21:52:52 +03:00
Svetlana Isakova 204e9a0c34 KT-6751 References to type arguments of a type argument not resolved when wrong number of them
#KT-6751 Fixed
2015-02-19 14:43:18 +03:00
Pavel V. Talanov f0003449e5 Test named class object reference resolve 2015-02-16 15:38:46 +03:00
Pavel V. Talanov ed5e2a21d1 Restore some of the tests for deprecated OBJECT$ field 2015-02-16 15:38:45 +03:00
Pavel V. Talanov 1972c2f177 Update test data for various tests
Due to slight semantic changes after class object refactor
2015-02-16 15:38:37 +03:00
Pavel V. Talanov a1f4c06a49 Update test data that mentioned old JvmAbi constants 2015-02-16 15:38:34 +03:00
Nikolay Krasko 0f3971323f Go to Declaration does not work on usage of constant from class object in Java (KT-6172)
#KT-6172 Fixed
2015-02-13 20:28:51 +03:00
Valentin Kipyatkov 0cffdeb973 Added 2 failing tests for bugs in resolve 2015-01-30 13:33:36 +03:00
Andrey Breslav da238cffaf Visibility of local classes is LOCAL 2015-01-29 16:07:29 +03:00
Valentin Kipyatkov 77a560775f KT-6628 Allow imports of classes from root package
#KT-6628 Fixed
2015-01-21 20:10:18 +03:00
Valentin Kipyatkov 8f32a6c1f9 Partial body resolve test to test 2 resolve modes 2014-12-18 15:48:27 +03:00
Valentin Kipyatkov 32a13502c5 Fixed one of the cases with lambda's returning Nothing 2014-11-24 20:11:29 +03:00
Valentin Kipyatkov bd8eaeedaa Added tests for lambda's returning Nothing (currently do not work) 2014-11-24 20:11:29 +03:00
Valentin Kipyatkov 6cb6a907d7 Changed test output from line comments to block comments 2014-11-24 20:11:29 +03:00
Valentin Kipyatkov 0f59622a44 Checked that partial body resolve works for property delegating 2014-11-24 20:11:28 +03:00
Valentin Kipyatkov 0b56760910 Partial body resolve works for property accessor body 2014-11-24 20:11:27 +03:00
Valentin Kipyatkov 8ccf56415a Partial body resolve filter: fixed nested loops case 2014-11-24 20:11:27 +03:00
Valentin Kipyatkov cc84e9682b Partial body resolve: corrected it for explicit function type but unfortunately it does not work for non-explicit type yet 2014-11-24 20:11:27 +03:00
Valentin Kipyatkov 058af69078 Partial body resolve: added more tests 2014-11-24 20:11:27 +03:00
Valentin Kipyatkov 2f19713cc2 Partial body resolve: rewritten algorithm of filter building to ensure correct resolve of smart cast points (+ prepared to support more strict mode for resolve only) 2014-11-24 20:11:27 +03:00
Valentin Kipyatkov cd90ab951f Partial body resolve tests: more informative test output 2014-11-24 20:11:27 +03:00
Valentin Kipyatkov 4503adb7fc Partial body resolve filter: more correct lambda resolve for return 2014-11-24 20:11:26 +03:00
Valentin Kipyatkov 4ca8a3400e Added a test 2014-11-24 20:11:26 +03:00
Valentin Kipyatkov 166d580682 Partial body resolve: found group of cases incorrectly handled by the current implementation 2014-11-24 20:11:26 +03:00
Valentin Kipyatkov 6230ba7310 "casted" -> "cast" 2014-11-24 20:11:25 +03:00
Valentin Kipyatkov 8010c0f09d Partial body resolve works for local Nothing functions + does not go inside local functions and classes 2014-11-24 20:11:25 +03:00
Valentin Kipyatkov e5579bcf32 Partial body resolve: to take source Kotlin callables with Nothing type from caches 2014-11-24 20:11:25 +03:00
Valentin Kipyatkov 992cdd9fe2 Partial body resolve: processing of standard "error" function 2014-11-24 20:11:25 +03:00
Valentin Kipyatkov ca8d45259b Partial body resolve: added a test to fail if smart-casts will become too clever 2014-11-24 20:11:25 +03:00
Valentin Kipyatkov e7ba59b209 Partial body resolve: correct handing of this qualifier 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov f56d89c487 Partial body resolve: don't be confused by exits after ?: 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov e724af4b4e Partial body resolve: more efficient handling if-statements 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov 0a7d73ef6b Partial body resolve: more efficient handling of loops 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov 806bf3b942 Partial body resolve: more efficient handling of while 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov 38c73f8df4 Partial body resolve: added test for do-while 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov a89c07924d Partial body resolve: fixed bug 2014-11-24 20:11:24 +03:00
Valentin Kipyatkov e6acc5601c Partial body resolve: more efficient for-loop handling 2014-11-24 20:11:23 +03:00
Valentin Kipyatkov 5283b92269 Partial body resolve: more precise smart casts analysis for if-statement 2014-11-24 20:11:23 +03:00
Valentin Kipyatkov a675b5ba38 Basic implementation of partial body resolve 2014-11-24 20:11:23 +03:00
Nikolay Krasko 95a2dce627 Remove warning and add tests when this warning had been reproducible 2014-11-11 17:33:12 +03:00
Alexander Udalov 685a1c38e2 Fix indent in built-in sources 2014-10-27 17:17:26 +03:00
Pavel V. Talanov 95302fd540 Fix not generating KotlinLightField for OBJECT$ and INSTANCE$ fields
Fix navigation from Java to such fields
Fix TODO in converter
2014-10-03 21:35:06 +04:00
Pavel V. Talanov b2ec5e1ec4 Test reference resolve from Java to Kotlin
Cases cover the most basic features
Sadly it was missing before
2014-10-03 21:35:00 +04:00
Alexander Udalov 04bb43e907 Fix navigation to data class copy function 2014-09-19 11:45:22 +04:00
Zalim Bashorov 48de3b706d Frontend: added the support file annotations to LazyTopDownAnalyzer. 2014-09-10 22:39:12 +04:00
Alexander Udalov 25bb220223 Fix navigation on values()/valueOf() of enum classes 2014-09-09 20:42:39 +04:00
Svetlana Isakova 9d366cb896 Prohibit local objects and enum classes
#KT-5402 Fixed
  #KT-4838 Fixed

Resolve type of object inside local object as special, not supertype('Any').
Changed visibility of constructor of anonymous object to 'internal' to be able to resolve the following:
fun box(): String {
    var foo = object {
        val bar = object {
            val baz = "ok"
        }
    }
    return foo.bar.baz
}
The containing declaration of property initializers is constructor, so 'baz' was invisible inside private constructor.
2014-09-01 12:32:52 +04:00
Pavel V. Talanov db5303c019 Implement modules in IDE
IDE:
Rewrite AnalyzerFacade and implementations for JS and JVM to support creating separate analyzers for each module
Introduce ModuleInfo which is an intermediate entity between configuration (tests or idea modules) and ModuleDescriptor
Implement IdeaModuleInfos which represent IDEA modules, sdks and libraries
Add (somewhat thin) test checking their behaviour
Implement getModuleInfo() - utility to obtain IdeaModuleInfo for PsiElement
Drop Project.getLazyResolveSession() - not possible to obtain resolve session for the whole project any more
Adjust JavaResolveExtension accordingly
KotlinSignature Intention/Marker - make sure that analyzed element is cls element (he's not in resolve scope otherwise)

LightClasses:
Create separate package light classes for each module
Java code can only reference light class from the first module among it's dependencies
Duplicate jvm signature is only reported on package declarations inside one module

Injectors:
Receive GlobalSearchScope as paramer for VirtualFileFinder and JavaClassFinder
which allows to narrow analyzer scope

JDR:
Introduce ModuleClassResolver resolves java classes in correct java descriptor resolver (corresponding ModuleDescriptor)
Add test checking that java classes belong to correct module

Debugger:
Provide context to analyze files created by debugger in

Converter:
Postprocessor now needs a context to analyze resulting code in

JetPsiFactory:
Add verification that files created by psi factory are not analyzed without context (that is almost never a good idea)

Other:
Use new API in various tests, utilities, run configuration producers and builtin serializers
Various "TODO: (module refactoring)" which mark the unfinished parts
2014-08-22 22:58:54 +04:00
Alexander Udalov cdbdfaf182 Make Pair and Triple data classes 2014-07-25 21:19:38 +04:00