Commit Graph

33513 Commits

Author SHA1 Message Date
Michael Bogdanov 8d2ffb2dab Fix wrong "InlineProperties are unsupported at this language level" error on inline functions when inline properties are disabled 2016-09-07 17:39:09 +03:00
Mikhail Zarechenskiy 3ad451e33e Partly support generics and nullable types as parameters for script templates 2016-09-07 17:24:19 +03:00
Michael Bogdanov 7230965e62 Support for property reference inlining 2016-09-07 12:01:49 +03:00
Michael Bogdanov 237afb4b7c Mark linenumber in property reference 2016-09-07 12:01:48 +03:00
Michael Bogdanov b4ae70139a PropertyReferenceCodegen refactoring 2016-09-07 12:01:48 +03:00
Michael Bogdanov a12d7b6019 Check lambda inlining in package part files in test framework 2016-09-07 12:01:47 +03:00
Dmitry Petrov f2b8569b4b KT-13735 NoSuchMethodError for generic typealias acces
Use underlying constructor descriptor for type alias constructor code generation.
2016-09-07 09:46:00 +03:00
Nikolay Krasko 727ff15af3 j2k: fix converter
(cherry picked from commit a21e85b)
2016-09-06 15:28:00 +03:00
Nikolay Krasko 9970289efb j2k: right after convert
(cherry picked from commit c0db343)
2016-09-06 15:27:58 +03:00
Nikolay Krasko 9606282d01 j2k: rename file
(cherry picked from commit 8deaa34)
2016-09-06 15:27:57 +03:00
Nikolay Krasko acc7c3286c Extract base class for goto action tests
(cherry picked from commit 0b25723)
2016-09-06 15:27:55 +03:00
Nikolay Krasko 115bc7e73b Tests for GotoTypeDeclaration action
(cherry picked from commit 3cd100b)
2016-09-06 15:27:54 +03:00
Alexey Tsvetkov eb22c94b6d Fix maven build 2016-09-06 14:48:07 +03:00
Alexey Andreev 43abdaa894 KT-13658: don't capture FakeCallableDescriptorForObject in closure 2016-09-06 10:59:56 +03:00
Denis Zharkov 6a22d75dd7 Drop TypeAliasDeserializer
Currently it's only used for local type aliases, while code in
'deserializeTypeAlias' works properly only for nested or top-level type
aliases.

Also it seems that serialization of types based on local type aliases
doesn't work now anyway (see KT-13692)
2016-09-05 17:54:36 +03:00
Denis Zharkov 86c1dbe7b5 Fix decompilation of types based on local classifiers
If deserializing a type with arguments based on a local class for
decompiler, then just return Any type (without arguments).

Previously Any constructor was used with serialized arguments, that lead
to exception

Note that in case of deserialization for compiler nothing changes about
local-classes-based types (LocalClassifierResolverImpl is just inlined)

 #KT-13408 Fixed
2016-09-05 17:54:36 +03:00
Alexander Udalov 1be3b9c192 Exclude more irrelevant maven-generated stuff in CodeConformanceTest 2016-09-05 16:44:54 +03:00
Alexander Udalov dc689ff514 Fix concurrent access issues in CallableReference implementations
Because of multiple reads from the same non-volatile variable, NPE was possible
to achieve in a multi-threaded application
2016-09-05 16:44:54 +03:00
Alexander Udalov 8fb5858dae Fix occasional NPE from reflection initialization
This could happen when a .jar containing Kotlin stdlib and reflection classes
was launched with 'java -jar'
2016-09-05 16:44:54 +03:00
Alexander Udalov 9da1840523 Minor, rename ConsPStack$1 -> ConsPStack$Itr
To somewhat improve stack traces (see
http://stackoverflow.com/questions/34214290/kotlin-massive-amounts-of-conspstack-how-can-i-avoid/34214718#34214718)
2016-09-05 16:44:54 +03:00
Alexander Udalov f4a1aa640e Optimize KClass creation from Class instance
Don't create unnecessary iterator every time in HashPMap.get (see
https://github.com/hrldcpr/pcollections/pull/41). Also fix a warning and remove
misleading comment
2016-09-05 16:44:54 +03:00
Alexander Udalov d0d1824e7d Optimize argument array creation in reflection call 2016-09-05 16:44:54 +03:00
Alexey Tsvetkov c422de7c3c Update changelog for 1.0.4 2016-09-05 14:55:22 +03:00
Alexey Tsvetkov 2afd79c977 Fix compatibility with AS 2.2 gradle plugin
#KT-13594 fixed
2016-09-05 14:52:43 +03:00
Alexey Tsvetkov 6e4bbfef86 Fix snapshot version for testModuleKind 2016-09-05 14:52:35 +03:00
Alexey Tsvetkov ed7d31eb6c Assume cache format is always up-to-date when compiling non-incrementally 2016-09-05 14:52:27 +03:00
Alexey Tsvetkov 0b017aa3ca Support multi-project IC for android projects 2016-09-05 14:52:23 +03:00
Alexey Tsvetkov 9f6509cd8e Fixes after review 2016-09-05 14:52:20 +03:00
Alexey Tsvetkov 4e8deb9566 Implement multiproject IC in Gradle
#KT-13528 fixed
2016-09-05 14:52:17 +03:00
Alexey Tsvetkov f967edfaeb Join paths to string for better assertion message in idea 2016-09-05 14:52:14 +03:00
Alexey Tsvetkov 4ceec37bfe Refactor version checking 2016-09-05 14:52:11 +03:00
Alexey Tsvetkov eea01f468b Introduce KotlinGradleBuildServices that is created once per build 2016-09-05 14:52:07 +03:00
Alexey Tsvetkov 7fa32a886d Minor: remove outdated TODO 2016-09-05 14:52:04 +03:00
Alexey Tsvetkov 3922ebcd4b Refactor loading kotlin version in gradle plugin 2016-09-05 14:51:56 +03:00
Alexey Tsvetkov 8a5df120a5 Ensure java is forced to compile when kotlin is compiled incrementally
Previously java compilation was not forced when there were only
removed kotlin files.
2016-09-05 14:51:49 +03:00
Alexander Udalov cb209074d3 Minor, add regression test on incomplete code with callable reference
#KT-13685 Fixed

(cherry picked from commit c8b30d3310c990193414d7f82bedd50189e0109c)
2016-09-05 13:13:57 +03:00
Nikolay Krasko 67f353903e Show lint diagnostics even if there're errors in the file (KT-12022)
It also affects working with KotlinChangeLocalityDetector. Right after error is fixed in local context file is still reported as having errors and diagnostics are not counted.

 #KT-12022 Fixed
2016-09-02 13:41:24 +03:00
Nikolay Krasko 795fef20d7 Don't highlight declaration with WRAPPED_INTO_REF
Leave highlighting only for usage. This may allow to make highlighting more local and lazy.
Java follows the same rules for "Implicit anonymous class parameter".
2016-09-02 13:41:24 +03:00
Nikolay Krasko f797d53343 Precheck method is called main in RunConfiguration check 2016-09-02 13:41:24 +03:00
Nikolay Krasko 9a54aa99fa Drop kotlin-bare-plugin (KT-11859) 2016-09-02 13:41:24 +03:00
Nikolay Krasko 4a0f14b64b Minor: toString() for NONE filter 2016-09-02 13:41:24 +03:00
Nikolay Krasko 52dd02fe08 Make changes in super call lambda not cause out-of-block modification (KT-13474)
#KT-13474 Fixed
2016-09-02 13:41:24 +03:00
Nikolay Krasko 64d511566e Test that out-of-block behaviour conforms running the analyze of the nearest expression
Mark as exceptions cases with field initialize expression and body of class init for now
2016-09-02 13:41:24 +03:00
Nikolay Krasko ec6780b49c Use AtomicLong for modification stamp 2016-09-02 13:41:24 +03:00
Nikolay Krasko 82bcd8192b Re-highlight only single function after local modifications 2016-09-02 13:41:24 +03:00
Nikolay Krasko 043502f836 Minor: remove warnings and refactoring 2016-09-02 13:41:24 +03:00
Dmitry Petrov e0cdad30e4 KT-13181 Unresolved reference when referencing a type alias from a different module
Add corresponding resolution code.
2016-09-02 10:18:23 +03:00
Dmitry Petrov 6428a7655d KT-13422 Type alias for Java exception class can be used as an object in 'throw' expression
Report NO_COMPANION_OBJECT for type aliases.
2016-09-02 10:18:22 +03:00
Mikhail Glukhikh c7f87e655c Build fix (ConvertLambdaToReferenceIntention) 2016-09-01 18:45:42 +03:00
Stanislav Erokhin 9fa6fb213b Potential fix for some random errors about "cannot choose between equals invoke functions". 2016-09-01 18:01:56 +03:00