Commit Graph

48515 Commits

Author SHA1 Message Date
Ilya Gorbunov 36f154882c Provide JvmSynthetic annotation in stdlib-common as optional
#KT-24478
2018-08-31 04:17:42 +03:00
Ilya Gorbunov 0c89996e34 Introduce platform specific annotations as optional in common stdlib
#KT-24478
2018-08-31 04:17:42 +03:00
Ilya Gorbunov ce7a863843 Move OptionalExpectation and related annotations to another source root 2018-08-31 04:17:42 +03:00
Ilya Gorbunov 2091601fe8 Advance bootstrap to 1.3.0-dev-25
Update public API of specialized unsigned iterators.
2018-08-31 04:17:42 +03:00
Yan Zhulanow d00f5b335a MPP: Refactoring, extract IDE platform kinds, allow to add custom platforms 2018-08-31 05:14:15 +05:00
Ilya Gorbunov cf1b2bedf4 Support bootstrapping from TeamCity releases builds
that have build.number different from the version of artifacts.
2018-08-31 00:42:40 +03:00
Ilya Gorbunov 29ce1297da Prepend changelog of 1.3-M1 and 1.3-M2 2018-08-30 23:11:15 +03:00
Anton Bannykh e7f9727783 JS: fix tests related to 1.3 migration 2018-08-30 22:27:24 +03:00
Pavel V. Talanov 3a8499b10e Fix a bug where kotlin common classes were seen as missing dependencies
When kotlin referred to them through java signatures
Java resolver ignores expect classes

 #KT-24185 Fixed
2018-08-30 19:37:02 +02:00
Pavel V. Talanov 7087a1b3f5 MPP: test different jvm implementations for single common module
Add test infrastructure to support same platform implementations
2018-08-30 19:37:02 +02:00
Alexander Udalov cb8951eeef Do not write pre-release binaries for stable LV
This is another cherry-pick of the commit 475a80b641 which was
accidentally reverted by 927706883e during the rebase on master
2018-08-30 17:57:07 +02:00
Alexander Udalov 47bde73ed5 Minor, fix testdata to use release coroutines 2018-08-30 17:34:32 +02:00
Mikhail Glukhikh 2849919094 Fix starImport quick-fix test 2018-08-30 18:30:50 +03:00
Mikhail Glukhikh ea74b37b5b Insert new line between annotation and type alias or sec. constructor
#KT-26377 Fixed
2018-08-30 18:30:47 +03:00
Toshiaki Kameyama bae754a266 Foldable if-then: do not highlight for is checks #KT-24978 Fixed 2018-08-30 18:30:45 +03:00
Alexander Udalov ac14c5e74f Fix KType.javaType for suspend function return type
#KT-26293 Fixed
2018-08-30 16:47:48 +02:00
Toshiaki Kameyama fba539debf "Nested lambda has shadowed implicit parameter": minor improvements 2018-08-30 17:37:36 +03:00
Toshiaki Kameyama b7c4248524 "Nested lambda has shadowed implicit parameter": add quickfix to rename shadowing 'it' 2018-08-30 17:37:36 +03:00
Toshiaki Kameyama 97150cb0e2 "Nested lambda has shadowed implicit parameter": show warning on the shadowing 'it' reference 2018-08-30 17:37:36 +03:00
Toshiaki Kameyama 7fdbcda91d "Nested lambda has shadowed implicit parameter": downgraded to WEAK WARNING level 2018-08-30 17:37:36 +03:00
Toshiaki Kameyama 7800f42840 "Nested lambda has shadowed implicit parameter": Do not report if 'it' paramerter is not used #KT-26268 Fixed 2018-08-30 17:37:36 +03:00
Ilmir Usmanov f3879af9f6 Implement suspend lambdas of big arity
Suspend functions and callable references to suspend lambdas are already
supported.
Support callSuspendBy of suspend function of big arity.
 #KT-24854: Fixed
2018-08-30 17:29:09 +03:00
Georgy Bronnikov 769344569d Mute tests that are new to 1.3-M2 2018-08-30 16:24:48 +03:00
Anton Bannykh 9af8fad43f JS: more coroutines 1.3 API related fixes 2018-08-30 16:24:45 +03:00
Anton Bannykh 8975a6e17e JS: adapt to 1.3 coroutines API
Also update a line number test
2018-08-30 16:24:43 +03:00
Ilmir Usmanov 2d04acba42 Update test data of compiler tests, except IR tests 2018-08-30 16:24:41 +03:00
Dmitry Savvinov 23c945b002 Remove specific language version in testMetadataField
- Why we bother? Because this test tries to read @Metadata via
reflection, and in 1.3 @Metadata has @Since("1.3") annotation. Thus,
with version fixed to 1.2, this test fails with UNRESOLVED_REFERENCE

- Why it is correct? Because initially this directive was used to enable
'LanguageFeature.JvmPackageName' (we didn't have infrastructure for
enabling particulare feature at that moment). So, now we could change it
to the '!LANGUAGE:+JvmPackageName', but it is actually redundant,
because master is already >= 1.2
2018-08-30 16:24:34 +03:00
Dmitry Savvinov b064c48f83 Fix testdata after advancing LATEST_STABLE to 1.3
This commit contains minor changes in testdata, where test and behavior
change are not related
2018-08-30 16:24:31 +03:00
Dmitry Savvinov 4dfb99596b Fix testdata after introduction of inline-classes mangling 2018-08-30 16:24:29 +03:00
Dmitry Savvinov f23528770b Extract usages of legacy 'mod' in a separate test 2018-08-30 16:24:27 +03:00
Alexander Udalov 053b54d216 Report error on .class files produced by Kotlin 1.3-M1
Advance incremental cache version to force rebuild after switching from
1.3-M1 to 1.3-M2

(cherry picked from commit ba111d58ae)
2018-08-30 16:23:33 +03:00
Dmitry Savvinov 2ecea06d3e Do not coerce inferred language levels when importing from facet
Rationaly is that facet importer knows better about which language
versions should be used, so we shouldn't interfere.

Otherwise, Gradle or Maven projects which have upgraded corresponding
plugin to 1.3 will be imported with 1.2 levels, which is undesirable
2018-08-30 16:23:30 +03:00
Sergey Igushkin 90ec151258 Bring back two methods used by old MPP K/N plugin
* First, it overrides `addCommonSourceSetToPlatformSourceSet` with an
  old signature that was drop during migration to 'KotlinSourceSet's

* Second, it uses an extension SourceSet.kotlin that got dropped during
  the aforementioned migration

Now, for the old MPP K/N plugin, `addCommonSourceSetToPlatformSourceSet`
is called twice, one time with the new signature and another with the
old one, which it overrides.
2018-08-30 16:22:00 +03:00
Mikhail Glukhikh 1e2334a911 Kotlin migration: fix data context calculation for 173 / AS31
Version for IDEA 182 does not work properly here (returns null),
so we have to use `DataManager.getDataContext(focusedComponent)` directly

#KT-26399 Fixed
2018-08-30 16:21:56 +03:00
Mikhail Glukhikh 2e4f46045e Kotlin migration: extract data context into a function, check it on null
The extraction itself is needed due to different behaviour of related
IDEA functions in different platforms.
Check on null is needed because `createFromAnAction` last argument
cannot be null, otherwise we will get an exception.

Partial fix of KT-26399
2018-08-30 16:21:53 +03:00
Roman Elizarov 319c16c885 CoroutineStackFrame: public API dump updated 2018-08-30 16:21:49 +03:00
Roman Elizarov a9eb94d822 Introduce CoroutineStackFrame interface for coroutine stack reconstruction in debugger
Fixes KT-26339
2018-08-30 16:21:46 +03:00
Dmitry Savvinov b23bf371cf Always pass languageVersion explicitly to JPS compiler
When 'languageVersion' isn't passed explicitly, compiler will choose
'LATEST_STABLE'.

This may lead to spurious migration of a project to the next major
version after plugin update (e.g. when user had project of major
version X and then installed plugin of version X+1 -- in such case,
meaning of "no language version" suddenly changes).

So, we set it to RELEASED_VERSION, which is exactly the version
that is safe to use as the fallback.
2018-08-30 16:21:43 +03:00
Alexander Podkhalyuzin 69a0fedd9f When version is not defined we need to fallback to released
There are few more such places. Better fix would be to avoid
situation, when we need to fallback. So in every project these
settings are defined. It means "Latest stable" setting is not good.

#KT-26364 Fixed
2018-08-30 16:21:40 +03:00
Ilya Gorbunov 009980944b Refine the exception type of EmptyRange.random()
Make it the same type as in case of an empty collection, so that
`emptyRange.random()` throws the same exception as `emptyRange.toList().random()`.

#KT-15539
2018-08-30 16:21:36 +03:00
Ilya Gorbunov 9c412ba436 Fix incorrect range transform in nextUInt/nextULong with range parameter
#KT-25570
2018-08-30 16:21:33 +03:00
Dmitry Petrov 583c66a2a7 Don't mangle synthesized 'box' function for inline classes 2018-08-30 16:21:30 +03:00
Ilya Gorbunov ea2c33a532 Extension random() to select random element from a collection
Fixes #KT-15539
2018-08-30 16:21:27 +03:00
Ilya Gorbunov b0bcd78e38 Optimize copying for typed arrays in JS 2018-08-30 16:21:24 +03:00
Ilya Gorbunov ea37a65178 copyInto: copying elements between two arrays
#KT-25874 Fixed
2018-08-30 16:21:20 +03:00
Ilya Gorbunov 58e6f910bc Update public API after stopping SuccessOrFailure mangling in signatures 2018-08-30 16:21:17 +03:00
Stanislav Erokhin 31f9184874 Update bootstrap 2018-08-30 16:21:14 +03:00
Yan Zhulanow 5d936a4c7c Kapt: Ignore annotation-processing-gradle compiler plugin we got from Gradle (KT-24714)
Cause it's built for the shaded Kotlin compiler and won't work with JPS.

(cherry picked from commit d08a32c7cb)
2018-08-30 16:21:11 +03:00
Stanislav Erokhin bcf2b39df2 Update bootstrap
Here we use build from custom branch intentionally and soon
we should bootstrap again.
2018-08-30 16:21:08 +03:00
Ilya Gorbunov 9c4a74ce5b Improve stability of nextBoolean test
Increase number of tosses (according to the Law of Large Numbers).
2018-08-30 16:21:05 +03:00