Commit Graph

47318 Commits

Author SHA1 Message Date
Dmitry Petrov 99a71b9ecc Desugar synthetic Java properties in psi2ir 2018-07-19 12:34:45 +03:00
Dmitry Petrov 44962b00b2 Introduce SyntheticPropertyDescriptor interface 2018-07-19 12:34:45 +03:00
Dmitry Petrov 4061a36506 Minor: reformat 2018-07-19 12:34:45 +03:00
Dmitry Petrov 76bfb94538 Add tests for Java synthetic properties in external dependencies 2018-07-19 12:34:45 +03:00
Mikhael Bogdanov 56c535d505 Fix test data 2018-07-19 10:52:13 +02:00
Roman Elizarov f5193802fc Uncommented coroutines tests that were failing due to inline class bugs 2018-07-19 10:32:55 +03:00
Yan Zhulanow 094cb6be1d Pill: Add an order entry for module's sources 2018-07-18 22:05:36 +03:00
Yan Zhulanow 2049d00ca8 Pill: Fix packages to find tests in for default test run configurations 2018-07-18 22:05:36 +03:00
Yan Zhulanow e243dd18c1 Pill: Add "-Duse.pill=true" parameter to the default test configurations
This switches 'JUnit3RunnerWithInners' to the JPS mode.
2018-07-18 22:05:36 +03:00
Yan Zhulanow af2f5549c5 Debugger: Do not report division by zero also for rem 2018-07-18 22:05:36 +03:00
Alexander Udalov 1464a4ac58 Load Java parameter names correctly in BinaryJavaMethod
PSI-based implementation (accessible via
`-Xuse-old-class-files-reading`) loads parameter names from the
"MethodParameters" attribute if it's present, so our own implementation
should as well.

This metadata doesn't seem supported in the java.lang.model.element API
though, so SymbolBasedValueParameter (which is used in `-Xuse-javac`)
will continue to have incorrect behavior for now

 #KT-25193 Fixed
2018-07-18 18:15:09 +02:00
Alexander Udalov 0f0602230a Fix parameter names of Java inner classes in reflection
#KT-25541 Fixed
2018-07-18 18:15:09 +02:00
Alexander Udalov 873e1b01d6 Merge and improve tests on Java parameter metadata in reflection 2018-07-18 18:15:08 +02:00
Alexander Udalov 5fbe35d1c8 Add tests on RequireKotlin on nested classes with metadata version 1.4 2018-07-18 17:59:37 +02:00
Alexander Udalov ea3c5c0107 Use -Xmetadata-version in tests instead of custom preprocessing
Test data for the wrongMetadataVersion test has changed because now not
only the .class files have the "future" version, but also the
.kotlin_module file, which prevents the current compiler from being able
to read what parts does a package in the library consist of. This is
related to the TODO in ModuleMapping.kt:89
2018-07-18 17:59:37 +02:00
Alexander Udalov 871b896a21 Add internal compiler argument to change metadata version
Will be used in tests to check how we behave on binaries produced by a
"future" compiler
2018-07-18 17:59:37 +02:00
Alexander Udalov cfc0f5e453 Support correct way of writing/loading version requirement table
Tests are added in subsequent commits.

KT-25120 Fixed
2018-07-18 17:59:37 +02:00
Alexander Udalov 4122021090 Add BinaryVersion to DeserializationContext
This will be useful to implement version-dependent deserialization,
which is needed for gradual fixes of issues in metadata

 #KT-25120 In Progress
2018-07-18 17:58:46 +02:00
Alexander Udalov 1e9694f1db Fix version requirement serialization for nested classes
Use the version requierement table of the outer DescriptorSerializer
instance when serializing metadata for a class. Pass parent serializer
to DescriptorSerializer.create to make sure the correct table is used.
Serialize nested classes before the outer class in JS and common code,
to make sure requirements are not lost. Also, split
VersionRequirementTest to JVM and JS

 #KT-25120 In Progress
2018-07-18 17:58:46 +02:00
Ilya Chernikov a61de052c7 Do not throw on incompatible cli scripting plugin
More reliably fixes #KT-24946, #KT-24438 and alike
2018-07-18 15:15:41 +02:00
Roman Artemev e4b314c26c Fix inlining of invoke operator [#KT-25474]
* add test
2018-07-18 16:12:41 +03:00
Dmitry Petrov a457a9f870 Update testData for IDEA tests for annotations with target EXPRESSION 2018-07-18 15:56:11 +03:00
Svyatoslav Kuzmich b23dabb8b7 Revert EXPECTED_REACHABLE_NODES for failed tests 2018-07-18 15:31:29 +03:00
Dmitry Petrov 82f22f92ca Don't generate ConstantValue for non-const vals in Kotlin 1.3+ 2018-07-18 15:02:54 +03:00
Georgy Bronnikov 7640b7f63a Stylistic changes suggested in review for @JvmStatic 2018-07-18 14:29:03 +03:00
Alexander Udalov 1e675bdc01 Simplify implementation of JvmField property in interface companion
Move parts of the logic to the only places where they're needed:
checking for public/final/val is only needed in
JvmFieldApplicabilityChecker, checking the proto flag is only needed in
reflection, checking the JvmField annotation presence is only needed in
backend
2018-07-18 13:24:45 +02:00
Alexander Udalov 79c2aa4acf Minor, move tests on JvmField into subdirectory 2018-07-18 13:24:45 +02:00
Alexander Udalov 715abda908 Add JvmFlags, use flags field instead of is_moved_from_interface_companion
To be able to add more property-related flags into the same int field
later
2018-07-18 13:24:44 +02:00
Dmitry Petrov 5767f84c0e Restrict retention for annotations with target EXPRESSION
#KT-13762 Fixed
2018-07-18 14:21:03 +03:00
Ilya Chernikov 70eaa0ec75 Cleanup annotations in script-util:
remove unused targets and runtime retention
2018-07-18 13:11:32 +02:00
Roman Elizarov 20c255948a Coroutines migration adapters 2018-07-18 12:29:17 +03:00
Dmitry Petrov ebe3fca45c Enable ProperIeee754Comparisons in "progressive mode"
See https://youtrack.jetbrains.com/issue/KT-22723#focus=streamItem-27-2917037-0-0
2018-07-18 12:10:10 +03:00
Denis Zharkov cc2280b95b Fix test data after 89d99e3989 2018-07-18 11:14:46 +03:00
Mikhail Zarechenskiy 48606ad983 Advance bootstrap to 1.2.70-dev-491 2018-07-18 11:05:09 +03:00
Mikhael Bogdanov bca6b98ea8 Fix test data 2018-07-18 08:41:48 +02:00
Mikhail Zarechenskiy bb575866cb Pass actual invoke parameters for inline functions with inline classes
#KT-25511 Fixed
2018-07-17 23:39:38 +03:00
Mikhail Zarechenskiy 77959247d2 Fix bridge generation for inline classes over Any type 2018-07-17 23:39:34 +03:00
Ilmir Usmanov 4811757d8d Disable intercepted instrinsic in 1.3
Fix compiler bootstrapping.
2018-07-17 22:25:43 +03:00
Nicolay Mitropolsky a616f6cca9 Uast: implicit receiver for local function calls (KT-25524) 2018-07-17 21:41:03 +03:00
Nicolay Mitropolsky 5212728a82 Uast: implicit receiver for function variables calls (KT-25524) 2018-07-17 21:41:03 +03:00
Alexander Udalov 53a57e8e1b Reformat module 'deserialization', fix warnings/inspections 2018-07-17 20:26:31 +02:00
Alexander Udalov ae6627fe94 Simplify code in JS serialization related to module descriptors
Do not use `JsModuleDescriptor<...>` where only its `data` is needed
2018-07-17 20:26:31 +02:00
Alexander Udalov 77405b2cca Reformat module 'js.serializer' 2018-07-17 20:26:31 +02:00
Yan Zhulanow 37411c823d Android Extensions: Check the backing 'virtualFile' validity before calling 'findFile()' (EA-124028) 2018-07-17 20:54:30 +03:00
Yan Zhulanow a4b3653e1c Debugger: Navigate to the right file in MPP projects (#KT-25152, #KT-25147) 2018-07-17 20:54:29 +03:00
Yan Zhulanow 02ee3aef3f Kapt: Fix "Unknown option: infoAsWarnings" (#KT-25396) 2018-07-17 20:54:28 +03:00
Svyatoslav Kuzmich 1abb4f42ac [JS IR BE] Add ranges to runtime, rangeTo for primitive numbers 2018-07-17 20:18:29 +03:00
Pavel V. Talanov 4c38899a2a Improve error message on failing to get javaResolutionFacade 2018-07-17 17:37:22 +02:00
Pavel V. Talanov 770c280ba5 Light classes: handle broken context in case of supertype delegation
This lead to an exception being thrown frequently
Proper fix would be to prevent binding context from being corrupted
Known cases are hard to debug/reproduce

 #EA-101081 Fixed
2018-07-17 17:37:20 +02:00
Ilmir Usmanov 991b4251f3 Remove redundant RequireKotlin annotations from coroutines' stdlib. 2018-07-17 17:31:03 +03:00