Commit Graph

1270 Commits

Author SHA1 Message Date
Nicolay Mitropolsky dd0e3cd135 Uast: ULambdaExpression returns proper functionalInterfaceType for SamAdapterExtensionFunctionDescriptor (KT-25297) 2018-07-09 19:41:07 +03:00
Nicolay Mitropolsky 2c7687195c Uast: properly handling explicit SAM (KT-25297) 2018-07-09 19:41:07 +03:00
Nicolay Mitropolsky 38e2d474b7 Uast: create KotlinULambdaExpression for in-place lambdas (KT-25297)
and provide appropriate functionalInterface
2018-07-09 19:41:07 +03:00
Nicolay Mitropolsky 5d9807ac36 Uast: converting Unit to void on type mapping (KT-25249) 2018-07-04 16:16:22 +03:00
Alexey Tsvetkov bfc608de29 Close kapt context 2018-07-04 14:55:42 +03:00
Alexey Tsvetkov 5bf5632886 Do not load annotation processors when generating stubs
#KT-25131 fixed
2018-07-04 14:55:42 +03:00
Ilya Gorbunov bed26dc700 Fix local delegated property smartcast usage 2018-06-29 20:11:03 +03:00
Nicolay Mitropolsky 698096f13e Uast: fix for creating an UClass for invalid object-literals (EA-122644, KT-20056) 2018-06-28 10:29:47 +03:00
Vyacheslav Gerasimov abd3ac4e96 UAST: Reformat KotlinUObjectLiteralExpression.kt 2018-06-27 16:04:41 +03:00
Vyacheslav Gerasimov a829251690 UAST: Fix possible TypeCastException when creating KotlinUNamedExpression 2018-06-27 16:04:40 +03:00
Vyacheslav Gerasimov 62c0d37d45 UAST: Do not log PCE in DeclarationDescriptor.toSource 2018-06-27 16:03:16 +03:00
Nicolay Mitropolsky bef3d4ace2 Uast: proper identifiers for KotlinUBinaryExpression (KT-25092) 2018-06-26 16:39:47 +03:00
Ilya Chernikov 7bff5e3ce7 Add missing tests dependencies on the renewed kotlin-scripting-idea plugin 2018-06-25 08:06:20 +02:00
Ilya Chernikov 1fbece9e7d Clean scripting plugin options and classpath on importing from gradle
should prevent problems that may appear if JPS will try to load
gradle scripting subplugin

(cherrypicked with update from 1.2.50)
2018-06-25 08:06:20 +02:00
Vyacheslav Gerasimov e724cfa60f Revert "Build: Copy uast to idea plugin as separate artifacts"
This reverts commit e6f6451
2018-06-22 21:41:25 +03:00
Nicolay Mitropolsky 01e9dd5085 don't use project scope to resolve java.lang.String (#KT-25024) 2018-06-22 20:28:55 +03:00
Egor Neliuba 4fd076e4f4 Fix typo in DefaultErrorMessagesAndroid
"Delegating 'Parcelable' is now allowed" -> "Delegating 'Parcelable' is not allowed"
2018-06-20 01:04:30 +03:00
Ilya Chernikov 29adf09b7e Add test with other annotation, tests fix of #KT-2496 2018-06-15 12:01:49 +02:00
Rodrigo B. de Oliveira e24a9d08f2 Only collect annotations with a name starting with KotlinScript 2018-06-15 11:53:49 +02:00
Yan Zhulanow 2bc45e0484 Kapt: Extract annotation processing running logic from the compiler plugin 2018-06-08 19:37:19 +03:00
Yan Zhulanow eb4492394e Kapt: Fix compatibility with Java 9
1. Move option set up to one place, before using any of Java context components;
2. Set Javac file manager options (new to Java 9)
2018-06-08 19:37:19 +03:00
Yan Zhulanow 614003ad70 Android Extensions: Allow to disable specific features of Android Extensions (#KT-23244) 2018-06-08 19:26:59 +03:00
Nicolay Mitropolsky c150878086 172: Uast: testdata fixes 2018-06-06 14:05:31 +03:00
Nicolay Mitropolsky 5c8e4958db Uast: exposing enum constants literal values (#KT-23456) 2018-06-06 14:05:30 +03:00
Nicolay Mitropolsky 12707a6443 Uast: handling resolve to deserialized methods (KT-24679) 2018-06-06 14:05:30 +03:00
Nicolay Mitropolsky 2ede37496c 173: Uast: removing kotlinInternalUastUtils.kt.173
no sense to keep difference
2018-06-06 14:05:30 +03:00
Nicolay Mitropolsky 045cc253ab Uast: KotlinUEnumConstant.returnType now is evaluated from containing сlass
to make it not load additional clsDelegates
2018-06-05 18:00:15 +03:00
Alexey Tsvetkov db66bfd726 Pack scripting plugin into kotlin-scripting-embeddable for use in Gradle 2018-06-01 23:13:36 +03:00
Alexey Tsvetkov 873de17056 Resolve compiler plugin classpath using 'kotlinCompilerPluginClasspath' configuration
#KT-24653 fixed
        #KT-24676 fixed
2018-06-01 23:13:36 +03:00
Nicolay Mitropolsky 8e2c9358bc Uast: updates for consistency tests and fixes for missed things
we should use `sourcePsi` instead of `psi` for parents matching, because light `psi` will not be tested, and it is not enough to store only PSI as map key to match parent consistency, because some different UElements could have same sourcePsi.
2018-05-29 13:30:52 +03:00
Ilya Chernikov 6fdb8746de Fixes after review 2018-05-28 22:10:56 +02:00
Ilya Chernikov a46dd5b30e Avoid using reflected types in the scripting API
since it causes numerous classloading issues. Using the wrapping types
and reload them in the proper context when needed.
Note: this version supports only classes, but the wrapping type could
be extended to support other types in the future.
+ numerous fixes related to proper loading and handling of the templates.
2018-05-28 22:10:56 +02:00
Nicolay Mitropolsky eea66bea73 Making LightAnnotation work without clsDelegate (KT-20924, KT-22883) 2018-05-28 17:06:35 +03:00
Dmitry Savvinov da7b59984f Move importsDumper to compiler plugin 2018-05-28 13:02:48 +03:00
Ilya Chernikov 92d848b6e6 Fix scripting plugin commandline processing 2018-05-25 09:51:04 +02:00
Ilya Chernikov 705faa4792 Add lazy discovery test 2018-05-25 09:51:04 +02:00
Natalia Selezneva 30c62bccb2 Refactoring: do not store scriptModuleInfo inside ScriptDependenciesInfo
Cache for ScriptDependenciesInfo.ForFile is dropped because there is a cache for ScriptModuleInfo, so the facade for dependencies shouldn't be created too often
Cache for ScriptDependenciesInfo.ForProject is stored in a field
2018-05-24 08:47:32 +03:00
Yan Zhulanow 015d7f3300 Kapt: Do not retain references to Kotlin compiler classes in customized Javac components
This should fix potential memory leakages.
2018-05-24 01:01:52 +03:00
Yan Zhulanow 99ecedc32e Kapt: Ensure there isn't duplicating entries in the processor loading classpath
(cherry picked from commit 1354a0d)
2018-05-24 01:01:52 +03:00
Yan Zhulanow aa8c266940 Pill: Add kotlin-scripting-gradle and kotlin-gradle-plugin-integration-tests to JPS model (in 'full' variant) 2018-05-24 01:01:52 +03:00
Yan Zhulanow b6d59da8a8 Kapt3: Avoid normal compilation in case if no apClasspath entries are passed (#KT-24538) 2018-05-24 01:01:52 +03:00
Yan Zhulanow 6e362f6734 Kapt: Remove kapt1 from Kotlin compiler 2018-05-24 01:01:51 +03:00
Yan Zhulanow 20cb4e91b3 Do not retain proxy-based components for compiler plugin settings in project model 2018-05-16 17:04:03 +03:00
Vyacheslav Gerasimov a1c551faaf as32: Make use of createIfNecessaryParameter of AndroidModuleInfoProviderImpl.getApplicationResourceDirectories 2018-05-15 22:32:20 +03:00
Yan Zhulanow c439b6d38b Pill: Import common modules as libraries 2018-05-15 16:29:47 +03:00
Ilya Chernikov b3219cb762 Implement lazy script definition and light discovery in cli plugin, ...
update appropriate parts of the scripting infrastructure
2018-05-14 11:13:44 +02:00
Nicolay Mitropolsky 05be8f7536 UastKotlinPsiVariable: hashCode nullability fix (EA-119715) 2018-05-11 12:57:23 +03:00
Vyacheslav Gerasimov c1f5ebb28e as32: Fix usages of AppResourceRepository in AS 3.2 C14 plugin 2018-05-10 23:28:41 +03:00
Vyacheslav Gerasimov 4adc0a94ab as32: Update to 181 platform api 2018-05-10 23:28:41 +03:00
Vyacheslav Gerasimov ab25145458 as32: Restore uast to 181 platform state 2018-05-10 23:28:41 +03:00