Commit Graph

47878 Commits

Author SHA1 Message Date
Ilya Gorbunov ebc64da52a Update EXPECTED_REACHABLE_NODES after introducing top-level comparator
#KT-18067
2018-08-15 21:28:57 +03:00
Ilya Gorbunov ed53983e1e Add support for CASE_INSENSITIVE_ORDER in JS and common
#KT-18067
2018-08-15 21:28:54 +03:00
Ilya Gorbunov 6866f5d19a Move test and cover more cases of string comparison
#KT-18067
2018-08-15 21:28:50 +03:00
Ilya Gorbunov 27dde5f730 String.compareTo: SinceKotlin in JS and common, restore default parameter value in JVM
Default parameter is required to generate docs with Dokka for now.

#KT-18067
2018-08-15 21:28:47 +03:00
Toshiaki Kameyama f05a19aafb JS stdlib: implement String.compareTo with ignoreCase
#KT-18067 Fixed
2018-08-15 21:28:44 +03:00
Alexey Sedunov d194893012 MPP: Add production module dependencies to the test one (new MPP import)
#KT-25985 In Progress
2018-08-15 18:21:53 +03:00
Alexey Sedunov 443f8b6f02 Minor: Fix test data 2018-08-15 18:21:53 +03:00
Svyatoslav Kuzmich f5a80a30f7 Mute and unmute tests 2018-08-15 18:20:07 +03:00
Sergey Igushkin d13ca38296 Relax some restrictions on Gradle dependency configurations in new MPP
* Set canBeConsumed = false only on those configurations that have this
  flag according to the Gradle Java plugins. This saves us from breaking
  existing build scripts but introduces ambiguity between consumable
  configurations (e.g. between `apiElements`, `compile`, `runtime`). See
  the solution in the next point.

* Don't set the Kotlin platform attribute on configurations that are
  not meant for consuming in other projects or resolving directly. This
  change hides these configurations from Gradle's variant aware
  dependency resolution and therefore prevents ambiguity

(cherry-picked from 81f2c48f)
2018-08-15 17:48:44 +03:00
Georgy Bronnikov 00da193167 Introduce IrDeclarationWithVisibility 2018-08-15 16:56:16 +03:00
Dmitry Petrov 8e95ecb821 Use underlying type when computing type mapping mode for inline classes 2018-08-15 15:37:46 +03:00
Dmitry Petrov 948e72f653 Inline classes can only implement interfaces 2018-08-15 15:32:50 +03:00
Ilmir Usmanov 1c098bf5cf Minor. Fix test 2018-08-15 14:23:33 +03:00
Ilmir Usmanov b4189d9e85 Minor. Use more granular assertion levels in assertion tests 2018-08-15 14:23:30 +03:00
Mikhael Bogdanov 1a1bb53381 Update IR text test
Additional implicit coercions to unit was added
2018-08-15 14:18:15 +03:00
Ilmir Usmanov 300876348a Fix line numbers generation for coerced primitives
in coroutines
 #KT-25076: Fixed
2018-08-15 13:47:45 +03:00
Ilmir Usmanov a470fd21ca Eliminate only first {ASTORE, ALOAD} in locals elimination
of ALOAD.
 #KT-25912: Fixed.
2018-08-15 13:45:24 +03:00
Svyatoslav Kuzmich ff70b837ee [JS IR BE] Support local delegated properties 2018-08-15 13:35:14 +03:00
Svyatoslav Kuzmich 392ad521fd [JS IR BE] Reflection support 2018-08-15 13:35:14 +03:00
Mikhail Glukhikh 1471fe08d7 Minor rename in if-then utils 2018-08-15 12:36:01 +03:00
Mikhail Glukhikh 5b77def0e0 "if-then to safe access": treat transformation to 'let' as intention
Related to KT-7675
2018-08-15 12:36:01 +03:00
Toshiaki Kameyama f5cfec4a91 "if-then to safe access" inspection: support call expression -> let
#KT-7675 Fixed
2018-08-15 12:36:01 +03:00
Toshiaki Kameyama 2dcbf6aa34 Introduce "Redundant return label" inspection #KT-25270 Fixed 2018-08-15 12:36:01 +03:00
Toshiaki Kameyama b91f30ab15 Suspicious callable reference: no quick fix with invalid reference type
#KT-23467 Fixed
2018-08-15 12:36:00 +03:00
Leonid Startsev 0ac969a617 Attempt to make loading of compiler plugins from kotlin-platform-native Gradle plugin
Moved SubpluginEnviroment to separate file and made public some methods
KotlinNativeCompile task now extends AbstractCompile so it could be passed to SubpluginEnviroment.loadSubplugins
KotlinNativeBasePlugin now declares kotlinCompilerPluginClasspath configuration
2018-08-15 12:19:04 +03:00
Mikhael Bogdanov 494828f4cf Unmute jvm ir-tests 2018-08-15 10:26:28 +03:00
Mikhael Bogdanov 6d915bd68c Use original descriptors on implicit coercion to unit generation 2018-08-15 10:26:03 +03:00
victor.petukhov e01e832acd Add gradle task to print spec tests statistic by spec sections 2018-08-14 17:34:38 +03:00
victor.petukhov 93874de89b Add 'specTest' gradle task to run spec tests 2018-08-14 17:34:27 +03:00
victor.petukhov bed4c5f2f0 Add diagnostic spec tests for 'When expression' section 2018-08-14 17:34:15 +03:00
victor.petukhov 90f22d47b6 Fix incorrect severity for some diagnostics of DebugInfoDiagnosticFactory 2018-08-14 17:34:04 +03:00
victor.petukhov 0a58898817 Add diagnostic spec tests generator and validator, helper functions and classes 2018-08-14 17:33:54 +03:00
victor.petukhov e989cf2bf4 Add tests-spec module with basic gradle configuration 2018-08-14 17:33:41 +03:00
Alexey Tsvetkov b6575b0c57 Do not turn off IC in gradle.properties
It is turned off for teamcity in build.gradle.kts
2018-08-14 16:30:23 +03:00
Toshiaki Kameyama 08cfe1acfd "Convert lambda to reference": fix false positive for vararg function
#KT-16422 Fixed
2018-08-14 15:48:37 +03:00
Toshiaki Kameyama 28aa0763a9 "Convert to run / with": don't suggest on java static method call
#KT-25739 Fixed
2018-08-14 15:40:46 +03:00
Toshiaki Kameyama 0a5aa2b60c "Convert lambda to reference": fix case with extension 'this'
#KT-21999 Fixed
2018-08-14 15:39:26 +03:00
Toshiaki Kameyama 2bf3b435f2 Redundant semicolon: fix false positive between modifier and declaration
#KT-25579 Fixed
2018-08-14 15:32:26 +03:00
Toshiaki Kameyama 1898df3fb7 Introduce "Convert property getter to initializer" intention
#KT-13854 Fixed
2018-08-14 15:32:20 +03:00
Toshiaki Kameyama 6fbf6b0a93 "Let type implement interface": don't suggest same type #KT-25928 Fixed 2018-08-14 15:32:17 +03:00
Toshiaki Kameyama 2d2f1125a9 "Remove redundant let": fix destructuring declaration false positive
#KT-26042 Fixed
2018-08-14 15:32:10 +03:00
Toshiaki Kameyama 7e8521d9dc Remove redundant let in "Safe access to if-then" #KT-13515 Fixed 2018-08-14 14:11:15 +03:00
kenji tomita 443b1834bc Add "Replace assertBoolean() with assertEquals() inspection"
#KT-23445 Fixed
2018-08-14 14:11:14 +03:00
Nicolay Mitropolsky e92d3998de KotlinLanguageInjectionSupport: remove calling replaceInjectionsWithUndo on removing of in-place injection 2018-08-14 13:10:38 +03:00
Nicolay Mitropolsky cd047b9605 Uast: KotlinUAnnotation.uastAnchor uses nameReferenceElement as javaPsi
because `nameReferenceElement` is not-null in LightAnnotations, but `referenceNameElement` violates `javaPsi` contract
2018-08-14 13:08:38 +03:00
Vyacheslav Gerasimov 9a441b9c8d Make DocumentAdapter.documentChanged overrides compatible with 183 platform 2018-08-14 12:48:26 +03:00
Denis Zharkov 9f3a902ff3 Take into account refined applicability of dsl-marker in IDE
After the previous change, when being applied to a function type
with receiver it's assumed to work just as it's applied to receiver type

Thus, it's necessary to fix relevant IDE features relied on DSL markers

 #KT-23255 Fixed
2018-08-14 15:58:18 +07:00
Denis Zharkov 117abb04aa Fix applicability of dsl-marker on function type
When marker is applied to function type it should work
like it's applied to receiver type

 #KT-23255 Fixed
2018-08-14 15:58:18 +07:00
Denis Zharkov 99fe6de52a Avoid storing ContractProviderKey in user data of every function
Whenever the key is absent it means that for some reason
contract can't be defined there.

But we still want to check them properly, thus checkContractAndRecordIfPresent
should work even if contract is inapplicable here
(no ContractProviderKey in owner's user data)
2018-08-14 15:58:18 +07:00
Georgy Bronnikov 1f7776981d Introduce correspondingProperty to IrField 2018-08-14 10:36:56 +03:00