Commit Graph

1859 Commits

Author SHA1 Message Date
Tianyu Geng 2c2851af6e Analysis API: add test covering get missing when branches
Also fix FIR implementation to generate boolean branches in the same
order as FE1.0.
2021-11-04 23:04:35 +01:00
Tianyu Geng 197079c85c FIR IDE: make smartcast API return unstable smartcasts 2021-11-04 16:00:37 +01:00
Jinseong Jeon 3f2c86afb8 FIR IDE/LC: introduce/use delegated member scope 2021-10-27 17:06:32 +02:00
Jinseong Jeon 700f8ac287 FIR IDE: relocate scope-related test data 2021-10-27 17:06:32 +02:00
Jinseong Jeon 4266ffa274 FIR IDE: fix typo in test directory (overridden) 2021-10-27 17:06:32 +02:00
Jinseong Jeon 9ed2c9d371 FIR LC: add tests about type approximation in PsiType provider 2021-10-25 20:24:48 +03:00
Yan Zhulanow 516dd825c2 [FIR IDE] Initial descriptor-based implementation of the Analysis API 2021-10-20 19:41:24 +03:00
Yan Zhulanow e2c9be0932 [FIR IDE] Extract common components of the Analysis API to separate modules 2021-10-20 19:41:23 +03:00
Yan Zhulanow 20b73499f5 Pill: Add Analysis API test generator to the "Generate all tests" run configuration 2021-10-19 19:55:09 +03:00
Yan Zhulanow 1f2508c177 Pill: recognize 'protobufCompare' as a test module 2021-10-19 19:55:07 +03:00
Tianyu Geng 8b44a4685f FIR IDE: add API to get super types of a KtType 2021-10-16 14:16:25 +02:00
Dmitriy Novozhilov 20e35167c8 [FIR] Add simple IR body generator to FIR plugin prototype 2021-10-12 17:26:39 +03:00
Dmitriy Novozhilov e3579389ee [FIR] Create IR text tests for declarations generators 2021-10-12 17:26:36 +03:00
Dmitriy Novozhilov ea93d23dca [FIR] Move fir plugin tests to diagnostics sub directory 2021-10-12 17:26:34 +03:00
Dmitriy Novozhilov 6d42914e56 [FIR] Migrate fir plugin prototype tests to new test infrastructure 2021-10-12 17:26:18 +03:00
Dmitriy Novozhilov e56c87a17a [Build] Move utils for generation JUnit 5 tests to :generators module 2021-10-12 17:26:18 +03:00
Dmitriy Novozhilov df47bffabb [Test] Migrate Parcelize tests to new test infrastructure 2021-10-07 13:08:45 +03:00
Dmitriy Novozhilov bc7cc6b5a9 Move generated parcelize tests to tests-gen directory 2021-10-07 13:08:43 +03:00
Ilya Gorbunov bd856ad726 Propagate option deprecation to options impl class
This is to avoid the new warning OVERRIDE_DEPRECATION that is reported
when a base method is deprecated and an overriding method is not.
2021-09-29 21:46:51 +03:00
Vyacheslav Gerasimov ab146bd6d4 Build: Fix deprecated Gradle configurations usages
for migration to Gradle 7+ #KTI-559
2021-09-26 18:28:44 +03:00
Tianyu Geng d77db2cda6 FIR checker: expose API to check if two types are compatible
This is useful for quickfixes offering casts. We don't want to offer
user to cast incompatible types.

Also, explicitly allow compare to `Nothing` and handle `Nothing` from intersection
2021-09-17 01:59:05 +03:00
Jinseong Jeon 068e81570d FIR IDE: type-aware constant conversion 2021-09-15 22:32:12 +02:00
Ilya Kirillov 5b38bd2be2 FIR IDE: fix generators after changing analysis api packages 2021-09-15 11:32:47 +02:00
Ilya Kirillov 4d52b354af FIR IDE: move analysis api fir generator to the analysis directory 2021-09-15 11:32:33 +02:00
Ilya Kirillov b70f4f581e FIR IDE: move low level api main sources to the analysis directory 2021-09-15 11:32:22 +02:00
Roman Golyshev 911bfcf150 [FIR IDE] Add basic compiler-side Import Optimizer tests
These tests are not complete, but it is intentional - it is just a basic
setup, so when the need arise, the tests can be added right away
2021-09-02 18:10:16 +00:00
Ilya Kirillov abe2311372 FIR IDE: move declaration/package providers to separate module 2021-08-24 20:12:58 +03:00
Steven Schäfer d08990ebb4 JVM: New single-pass implementation for jvm-abi-gen 2021-08-23 18:25:33 +02:00
Ivan Kylchik b85a796492 Support interpretation for floorDiv and mod functions 2021-08-13 16:18:28 +03:00
Nikita Bobko 5455800de4 [imltogradle] Exclude 'kotlin.util.compiler-dependencies' module from generation
This module is used as helper module in JPS project module to make sure that IDEA will download
all required dependencies. There are some dependencies which IDEA cannot determine as used so
we force it to download them (kotlinc.kotlin-dist, kotlinc.kotlin-compiler-testdata)

We don't need this module in Gradle project model

This commit fixes:
```
Could not resolve project :prepare:ide-plugin-dependencies:kotlin-compiler-testdata-for-ide.
Required by:
    project :kotlin-ide.kotlin.util.compiler-dependencies
```
2021-08-11 02:17:52 +02:00
Nikita Bobko 747cc7d55d [imltogradle] Fix other kotlinc libraries which don't follow kotlinc.* naming
e.g. kotlin-reflect
2021-08-11 02:17:51 +02:00
Nikita Bobko 784273ac5b [imltogradle] Add additional check for absence of snapshot version in JpsLikeJarDependency 2021-08-11 02:17:51 +02:00
Nikita Bobko 493fdbd418 Fix kotlin stdlib handling for 212 IDEA in ide-iml-to-gradle-generator 2021-08-11 02:17:51 +02:00
Alexander Udalov 0d1380c232 Fix warnings in generator modules 2021-08-10 17:57:50 +02:00
Nikita Bobko a97b4ea4ae Fix UnsupportedClassVersionError when running ./gradlew generateIdePluginGradleFiles
This commit fixes:
```
Exception in thread "main" java.lang.UnsupportedClassVersionError: com/intellij/jps/impl/JpsIdePluginManagerImpl has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
```
2021-08-07 00:07:30 +03:00
Nikita Bobko dac4fe7507 Adapt coop-dev for 212 platform 2021-08-07 00:07:28 +03:00
Alexander Udalov ca7334acb9 Fix some warnings in Gradle plugin and related modules 2021-08-06 22:36:58 +02:00
Dmitriy Novozhilov c2e2068682 [Test] Add ability to mark group of tests with specific tags
Currently tags can be applied to all tests in specific testdata
  directory by placing `_tags.txt` file in it, where all tags should
  be listed on separate lines. Test generator adds those tags to
  corresponding generated test classes with `@Tag` annotation

Please note that is applicable only to JUnit 5 tests
2021-08-01 22:23:41 +03:00
Ilya Kirillov f19dfd9d2a HL API: restore SymbolByReferenceTest
Now it is possible as references are working in HL API tests now
2021-07-27 17:58:46 +03:00
Ilya Kirillov c678d4b506 HL API: generate reference resolve tests
The testdata is taken from corresponding IDE reference resolve tests
2021-07-27 17:58:45 +03:00
Nikolay Krasko bba0dfb469 Cleanup as42 bunch files
We don't build AS42 plugin from main kotlin repo anymore.
2021-07-23 16:58:24 +03:00
Nikita Bobko d1e46e8ce7 Delete Kotlin IntelliJ IDEA plugin modules from settings.gradle 2021-07-21 11:23:53 +02:00
Nikita Bobko 39fa2b0baf Delete Kotlin IntelliJ IDEA plugin sources
Kotlin plugin sources were migrated to intellij-community:
https://github.com/JetBrains/intellij-community/tree/master/plugins/kotlin

Preserve `jps-plugin/testData/incremental`
because it's used in `compiler/incremental-compilation-impl/test`

Preserve `idea/testData/multiModuleHighlighting/multiplatform`
because it's used in `MppHighlightingTestDataWithGradleIT`
2021-07-21 11:23:43 +02:00
Dmitriy Novozhilov f3116cb64a Fix NON_EXHAUSTIVE_WHEN_STATEMENT warnings in project code 2021-07-20 13:33:46 +03:00
Ilya Kirillov c0eb669191 LL API: add basic tests for kt -> fir mapping 2021-07-19 18:45:28 +03:00
Ilya Chernikov dee0487185 IR: Refactor IrBuiltIns to abstract it from descriptors 2021-07-16 02:24:18 +03:00
Georgy Bronnikov 9efd0d7589 JVM_IR: JvmIrSerializer 2021-07-14 21:20:02 +03:00
Igor Yakovlev 64afba299f [imltogradle] Don't use deprecated kotlinOptions.jdkHome in generated build.gradle.kts files 2021-07-05 17:52:04 +02:00
Roman Artemev 6cdac22a23 [IR] Introduce new IdSignatures
FileSignature, CompositeSignature, LocalSignature

They are needed to make possible reference any non-local declaration via
 signature, including private signature, type parameters and so on.

- Support those new signatures in proto and klibs
- Rename `isPublic` -> `isPubliclyVisible` due to changed semantic
- Fix FIR
- clean up code
2021-07-01 17:40:31 +03:00
Yahor Berdnikau 430306b23d Change 'jvmTarget' backing property visibility to internal.
Allows to check if this property was updated by the user or not.

^KT-45611 In Progress
^KT-43095 In Progress
2021-06-25 16:28:54 +00:00