Valentin Kipyatkov
d4050ee074
More correct way of replacing parameter names to preserve overrides
2016-10-11 23:38:53 +03:00
Valentin Kipyatkov
4513f679de
Fixed test data
2016-10-11 23:38:53 +03:00
Pavel V. Talanov
14f3e4c758
Cls stubs and decompiled text: Do not render parameter names in decompiled text and do not load ParameterName annotation in stubs
...
Add tests for decompiled text and stubs
2016-10-11 23:38:53 +03:00
Valentin Kipyatkov
86495fd136
No parameter name in functional type of lambda with 'it'
2016-10-11 23:38:53 +03:00
Valentin Kipyatkov
b2f215227d
Fixed completion to not render functional types with parameter names in lookup items
2016-10-11 23:38:52 +03:00
Valentin Kipyatkov
7f0063013c
Corrected test data
2016-10-11 23:38:52 +03:00
Valentin Kipyatkov
073845ebd4
Fixed test data
2016-10-11 23:38:52 +03:00
Valentin Kipyatkov
4a8b41c72c
Do not render @ParameterName annotations for types
2016-10-11 23:38:52 +03:00
Valentin Kipyatkov
1b7f7fb799
Minor changes on code review
2016-10-11 23:38:51 +03:00
Valentin Kipyatkov
1f9e00b23f
Added tests that surprisingly passed
2016-10-11 23:38:51 +03:00
Valentin Kipyatkov
a62a37f6d8
Added tests for parameter names in function type from SAM-adapter + fixed KT-13861
...
#KT-13861 Fixed
2016-10-11 23:38:51 +03:00
Valentin Kipyatkov
59269ef1ae
ParameterName annotation on type argument used to hold parameter name
2016-10-11 23:38:51 +03:00
Valentin Kipyatkov
3bd39df587
No parameter names in types for error messages
2016-10-11 23:38:50 +03:00
Valentin Kipyatkov
6527ada775
Changes on code review
2016-10-11 23:38:50 +03:00
Valentin Kipyatkov
c0ea237ba4
Added test with type alias
2016-10-11 23:38:50 +03:00
Valentin Kipyatkov
d8759fcbcc
Optimizations
2016-10-11 23:38:50 +03:00
Valentin Kipyatkov
6b94e5fd34
Use parameter names from function type for invoke() function
...
#KT-435 Fixed
#KT-9016 Fixed
2016-10-11 23:38:49 +03:00
Valentin Kipyatkov
0abb2edb2b
Corrected test
2016-10-11 23:38:49 +03:00
Valentin Kipyatkov
41ee06ec96
Use parameter names in DescriptorRenderer
2016-10-11 23:38:49 +03:00
Valentin Kipyatkov
f335f32b48
Some use of parameter names in completion
2016-10-11 23:38:48 +03:00
Valentin Kipyatkov
147d1da1ed
Supported obtaining function type parameter names from KotlinType
2016-10-11 23:38:48 +03:00
Valentin Kipyatkov
8d7b59777c
Moved and renamed tests
2016-10-11 23:38:48 +03:00
Alexander Udalov
4eac12e350
Report warning when SinceKotlin value is greater than -api-version value
...
To prevent this diagnostic be reported in each test on SinceKotlin, disable it
when a diagnostic test contains the "!API_VERSION" directive
2016-10-11 17:46:14 +03:00
Alexander Udalov
167ab1f860
Introduce "-api-version" CLI option
...
The `@SinceKotlin("X.Y.Z")` annotation now hides a particular declaration from
resolution when the API version specified by the `-api-version` option is
_less_ than X.Y.Z. The comparison is performed as for versions in Maven:
MavenComparableVersion is in fact a copy of
org.apache.maven.artifact.versioning.ComparableVersion.
Also support "!API_VERSION" directive in diagnostic tests
#KT-14298 Fixed
2016-10-11 17:46:01 +03:00
Alexander Udalov
e3df8ed2fe
Introduce SinceKotlin annotation, check validity of its value
...
#KT-14297 Fixed
2016-10-11 17:45:51 +03:00
Alexander Udalov
8d660c2f6e
Refactor gradle option generation mechanism
...
Ensure there's a statically checked dependency on LanguageVersion and
JvmTarget, so that this information is updated automatically once a new
language version or a JVM target is added
2016-10-11 17:30:15 +03:00
Alexander Udalov
2c66d4e59b
Move LanguageVersionSettings and JvmTarget to module 'util'
...
To be used from cli-common in the subsequent commits
2016-10-11 17:30:14 +03:00
Alexander Udalov
aaeae8b948
Support deprecation level HIDDEN for classifiers
...
Classifiers annotated with `@Deprecated(level = HIDDEN)` now have smaller
priority in imports, similarly to private classes. For example, if two
classifiers named Foo are imported with a star import and one of them is
deprecated-hidden, the name Foo in the source code is resolved to the other
one.
Also a minor change in multi-module diagnostic tests: do not append newlines
after the last module in the test
#KT-13926 Fixed
2016-10-11 17:30:14 +03:00
Alexander Udalov
83c86d06ed
Report error instead of warning for deprecation level HIDDEN
...
Since functions usually are hidden from resolution when they are
deprecated-hidden, the problem can only be reproduced for properties with
deprecated-hidden accessors, where DeprecatedCallChecker reported warnings
instead of errors
2016-10-11 17:30:13 +03:00
Alexander Udalov
6e0e8c6dc3
Pass LanguageVersionSettings instance to isHiddenInResolution
...
Unused at the moment, will be used later to check if the API version prohibits
the usage of the element
2016-10-11 17:30:12 +03:00
Alexander Udalov
59b29cf00d
Minor, extract isDeprecatedHidden for usage in codegen
...
Also remove a hundred year old TODO
2016-10-11 17:30:11 +03:00
Alexander Udalov
2e4592c6dc
Report error on bound callable references in compatibility mode
...
Previously examples were failing with IllegalStateException from JVM back-end
because there was an error type without any error reported
2016-10-11 17:30:10 +03:00
Valentin Kipyatkov
73dc5fefcb
KT-12077 Code completion inserts FQN for annotations with use-site target inside primary constructor
...
KT-13009 Kotlin: annotation auto-import is broken in multiple ways
#KT-12077 Fixed
#KT-13009 Fixed
2016-10-11 17:26:52 +03:00
Valentin Kipyatkov
0c14058d13
Moved tests
2016-10-11 17:26:52 +03:00
Ilya Gorbunov
16a0c55c6c
Since 'printStackTrace' now fallbacks to the extension in stdlib, change the test expecting it to be deprecated due to language-version 1.0 accordingly.
2016-10-11 16:46:14 +03:00
Ilya Gorbunov
a239231c75
Revert dropping inline-only extensions for Throwable, to be able to use runtime of 1.1 with language version of 1.0 which makes mapped builtin members unavailable again.
...
#KT-14213 Fixed
2016-10-11 16:46:14 +03:00
Dmitry Jemerov
fc46afc108
reduce ComponentRegistry memory use
...
#KT-13136 Fixed
2016-10-11 15:35:06 +02:00
Dmitry Petrov
2cd6b1d586
KT-14282 No error on unused type alias with -language-version 1.0
...
Always resolve descriptors for type aliases.
2016-10-11 16:33:21 +03:00
Mikhail Glukhikh
206374cd17
Minor refactoring: destructure intention
2016-10-11 16:13:21 +03:00
Mikhail Glukhikh
c6fefbc223
Rename: intention tests "ifNullToElvis" --> "foldInitializerAndIfToElvis"
2016-10-11 16:13:16 +03:00
Mikhail Glukhikh
0903402282
"If null to elvis" now converts to elvis also !is check right after initializer #KT-14032 Fixed
2016-10-11 16:13:11 +03:00
Mikhail Glukhikh
121f0ec810
KT-14032 related: if expression to elvis now handles also is and !is checks
2016-10-11 16:13:06 +03:00
Mikhail Glukhikh
8188bb1e54
Destructure intention: entries / entrySet are now removed only for kotlin.Map inheritors #KT-14244 Fixed
2016-10-11 16:13:01 +03:00
Mikhail Glukhikh
304f6a3b3a
KT-13943 related: inspection is now always reported if manual destructuring is available
2016-10-11 16:12:56 +03:00
Mikhail Glukhikh
475d5548c4
Destructure intention now handles the case with manual destructuring inside #KT-13943 Fixed
2016-10-11 16:12:51 +03:00
Nikolay Krasko
c7ba19696a
Refactoring: stop calling deprecated method
...
(cherry picked from commit 083656c)
2016-10-11 15:35:44 +03:00
Nikolay Krasko
11f8c904c4
Refactoring: inline method + inline variable
...
(cherry picked from commit 7e0f100 )
2016-10-11 15:35:43 +03:00
Nikolay Krasko
bd2ddbafb3
Refactoring: call apply method without returning intermediate object
...
(cherry picked from commit a2f7e00)
2016-10-11 15:35:41 +03:00
Nikolay Krasko
78525ed7c6
Refactoring: make createCommand non-nullable
...
(cherry picked from commit 67cc9b5)
2016-10-11 15:35:40 +03:00
Nikolay Krasko
f7813263ee
Refactoring: rename getStepOverPosition -> getStepOverAction
...
(cherry picked from commit 2b71909)
2016-10-11 15:35:38 +03:00