Commit Graph

72367 Commits

Author SHA1 Message Date
Alexander Udalov e0b6d4d917 Add -Xsuppress-deprecated-jvm-target-warning to modules compiled with 1.6
Currently this leads to an unknown argument warning, but it'll be
removed automatically on the next bootstrap.
2021-02-03 12:51:39 +01:00
Alexander Udalov 99b5e5a373 Deprecate JVM target 1.6
#KT-44650 Fixed
2021-02-03 12:50:52 +01:00
Dmitry Petrov ab20a8ffff JVM_IR indy-lambdas: minor updates and fixes
KT-44278 KT-26060 KT-42621
2021-02-03 14:16:25 +03:00
Dmitry Petrov 088448043a JVM_IR indy-lambdas: don't use indy for big arity lambdas
KT-44278 KT-26060 KT-42621
2021-02-03 14:16:24 +03:00
Dmitry Petrov d94912ed62 JVM_IR indy-lambdas: initial implementation and tests
KT-44278 KT-26060 KT-42621
2021-02-03 14:16:22 +03:00
Igor Chevdar 0bc386cb08 [IR] Fixed bug with reflectionTarget evaluation 2021-02-03 15:26:40 +05:00
Igor Chevdar bb8bf28b8b [PSI2IR] Set reflectionTarget for all adapted references 2021-02-03 15:26:40 +05:00
Andrei Klunnyi 690fb47cbb KT-44079 [Sealed Interfaces]: move refactoring update
The idea behind this commit is that Move Refactoring should warn
developers in case their intention potentially breaks sealed
hierarchies (members must share the same module and package).

Provided algorithm has two goals:
- prevent destruction of correct hierarchies
- help in fixing broken ones
2021-02-03 10:04:26 +00:00
Ilya Goncharov de3678a805 [JS IR] Add test with fun interface call inside lambda
^KT-44433 fixed
2021-02-03 12:13:53 +03:00
Ilya Goncharov d6e74b9620 [JS IR] Use local scope for SAM if there are scopes
[JS IR] Use private for top level sam wrappers and local otherwise

^KT-44433 fixed
2021-02-03 12:13:52 +03:00
Jinseong Jeon ca314c5bb9 FIR checker: add diagnostic CANNOT_WEAKEN_ACCESS_PRIVILEGE 2021-02-03 12:07:36 +03:00
Jinseong Jeon 3a07ca4c64 FIR checker: add diagnostic VAR_OVERRIDDEN_BY_VAL 2021-02-03 12:07:36 +03:00
Jinseong Jeon 80d5a1a1db FIR checker: add diagnostic OVERRIDING_FINAL_MEMBER 2021-02-03 12:07:36 +03:00
Jinseong Jeon 4ef1e1119f FIR LT: introduce positioning strategies for specific modifiers 2021-02-03 12:07:35 +03:00
Jinseong Jeon 0dd5b94556 FIR checker: rename override checker
We can report more diagnostics than type mismatch, e.g.,
nothing to override, var overridden by val, final override, etc.
2021-02-03 12:07:35 +03:00
Jinseong Jeon b48835f3ce FIR checker: fix positions of type mismatch on overrides
To handle implicit return types, those should be reported on
declarations with return type positioning strategy, instead of
return type itself.
2021-02-03 12:07:35 +03:00
Dmitriy Novozhilov 571c4ce398 [Test] Support new configuration directives in old codegen tests 2021-02-03 10:03:23 +03:00
pyos 8277c96933 FIR: copy nullability when mapping type alias arguments 2021-02-03 08:38:56 +03:00
scaventz bd205317aa CLI: improve behavior of -include-runtime
1.fix KT-17344: Include kotlin-reflect to resulting jar if "-include-runtime" is specified, unless the -no-reflect option is specified.
2.fix KT-43220: -include-runtime should add .kotlin_builtins to the output
2021-02-02 12:49:23 -08:00
Alexander Udalov 496d857db1 Add kotlin.build.disable.werror to disable -Werror locally
This can be placed, for example, in `local.properties` to temporarily
disable `-Werror` in compiler/stdlib/plugin/test modules during
development.
2021-02-02 21:47:33 +01:00
Mads Ager 6a959fefd0 [JVM_IR] Fix accessibility bridges for static protected fields.
Super-qualifiers have to be taken into account. Otherwise, too
few accessibility bridges will be generated which can lead to
binary compatibility issues.
2021-02-02 12:46:08 -08:00
Dmitriy Dolovov 62897a194b [Commonizer] Force GC after each serialized target 2021-02-02 23:13:14 +03:00
Dmitriy Dolovov ff45e58543 [Commonizer] Minor. Post-review changes, p.2 2021-02-02 23:13:06 +03:00
Dmitriy Dolovov c8a938275c [Commonizer] Minor. Post-review changes 2021-02-02 23:13:00 +03:00
Dmitriy Dolovov 318dd22bd1 [Commonizer] Add tests for CommonizerTarget 2021-02-02 23:12:54 +03:00
Dmitriy Dolovov 6fe5f85da7 [Commonizer] Use kotlin/Any as the default supertype for commonized class 2021-02-02 23:12:49 +03:00
Dmitriy Dolovov 2438265ba8 [Commonizer] Dump every target to disk immediately when it's ready 2021-02-02 23:12:43 +03:00
Dmitriy Dolovov 9c4af5070b [Commonizer] Ignore acceptable (minor) metadata mismatches in tests 2021-02-02 23:12:37 +03:00
Dmitriy Dolovov a4438ad64f [Commonizer] Fix calculation of type parameter IDs for nested classes and their members 2021-02-02 23:12:30 +03:00
Dmitriy Dolovov 55c37183d9 [Commonizer] Ignore constructors for enum entries 2021-02-02 23:12:23 +03:00
Dmitriy Dolovov dfd1a53624 [Commonizer] Don't serialize kotlin/Any? as the single type parameter upper bound 2021-02-02 23:12:18 +03:00
Dmitriy Dolovov 1c8cd242bf [Commonizer] Don't write IS_EXPECT flag for synthesized expect functions 2021-02-02 23:12:12 +03:00
Dmitriy Dolovov 9d6c0e56ed [Commonizer] Fix HAS_ANNOTATIONS flag calculation for serialized classes 2021-02-02 23:12:07 +03:00
Dmitriy Dolovov b39a205671 [Commonizer] Minor. Improved diagnostics message in tests 2021-02-02 23:12:01 +03:00
Dmitriy Dolovov 80b95a22a4 [Commonizer] Fix property backing/delegate field annotations serialization 2021-02-02 23:11:55 +03:00
Dmitriy Dolovov 3b91d1c5e5 [Commonizer] Don't commonize built-ins 2021-02-02 23:11:49 +03:00
Dmitriy Dolovov 585cd64b9a [Commonizer] Drop descriptors for commonized declarations 2021-02-02 23:11:44 +03:00
Dmitriy Dolovov 5ff6b5ef42 [Commonizer] Rework test infrastructure to compare metadata instead of descriptors 2021-02-02 23:11:38 +03:00
Dmitriy Dolovov f67a9615b8 [Commonizer] Pretty target name output in console 2021-02-02 23:11:31 +03:00
Dmitriy Dolovov e5aa772639 [Commonizer] Fix approximation for aliases types 2021-02-02 23:11:26 +03:00
Dmitriy Dolovov 4c640e3f81 [Commonizer] Log stats during building metadata 2021-02-02 23:11:19 +03:00
Dmitriy Dolovov d610837caf [Commonizer] Integrate metadata builder with the commonizer environment 2021-02-02 23:11:13 +03:00
Dmitriy Dolovov 2bcaf1fa63 [Commonizer] Introduce metadata builder 2021-02-02 23:11:04 +03:00
Dmitriy Dolovov e28c1fd310 Metadata: Chunked KlibModuleFragmentWriteStrategy implementation 2021-02-02 23:10:57 +03:00
Dmitriy Dolovov 9551e0fff2 [Commonizer] Introduce MetadataDeclarationsComparator for metadata-based comparison of KLIBs 2021-02-02 23:10:51 +03:00
Dmitriy Dolovov 701374a646 [Commonizer] Embed :kotlinx-metadata-klib into the commonizer Jar 2021-02-02 23:10:45 +03:00
Dmitriy Dolovov 08cc904a71 [Commonizer] Restore lost nullability for underlying types in TAs 2021-02-02 23:10:39 +03:00
Dmitriy Dolovov 85f79695b9 [Commonizer] Avoid leaking non-commonized underlying types in TAs 2021-02-02 23:10:32 +03:00
Dmitriy Novozhilov 4bf6e58f2b [TD] Fix directive order in codegen testdata 2021-02-02 20:37:47 +03:00
Zalim Bashorov 3f10914f05 [JS] Replace usages of FileUtil.loadTextAndClose with functions from stdlib to avoid crashes on files larger than 10MiB 2021-02-02 18:47:44 +03:00