Commit Graph

20 Commits

Author SHA1 Message Date
Dmitrii Gridin d64f18eaa9 [SLC] AbstractSymbolLightClassesStructureTestBase: add stable order
Now more diff between sources and libraries are readable

^KT-62892
2024-01-03 21:35:12 +00:00
Dmitrii Gridin 6c7d1babf0 [Analysis API] support Java compilation in tests
Previously we just skipped Java sources.
The order of classes in light classes test data is changed due to
differences in implementations of `compileLibraryToJar` and `runJvmCompiler`

^KT-62892
2024-01-03 21:35:12 +00:00
strangepleasures 03ed1d1d31 KT-62560 [SLC] Fix handling of empty varargs in annotations 2023-11-20 20:57:21 +00:00
Marco Pennekamp 223c793258 [SLC] Order parent classes before nested classes in structure test results
- This improves the readability of the result files.
2023-10-09 19:46:51 +00:00
Marco Pennekamp cd8143af7b [SLC] Fix nested classes missing in SLC structure tests for libraries
^KT-62038 fixed
2023-10-09 19:46:51 +00:00
Marco Pennekamp 315573d99f [SLC] Add SLC structure tests for nested classes
^KT-62038
2023-10-09 19:46:51 +00:00
strangepleasures cf01d2970f [SLC] [KAPT] KT-61916 Fix generation of annotations in annotation arguments 2023-09-14 13:21:07 +00:00
Anna Kozlova 190d49a1e0 [light classes] optimize accessors retrieval
Avoid expensive calls to `navigationElement` for methods
that cannot be getters/setters and would be filtered later.
Repeat partly naming generation strategy.

Merge-request: KT-MR-10689
Merged-by: Anna Kozlova <Anna.Kozlova@jetbrains.com>
2023-06-22 14:14:39 +00:00
Anna Kozlova 95ec7ede66 [light classes] create enum references as PsiReferenceExpressions
Ensure that enum constants with special characters in their names are properly ignored
2023-06-13 20:09:54 +00:00
Anna Kozlova 57f429206c [light classes] Improve isEquivalence checks
^KTIJ-25412

Update equivalence checks for light accessor methods and light fields
 to make them equivalent if they share the same underlying property.
 Follow the `kotlinOrigin` declaration:
 even if there is a property accessor,
 use property declaration.
2023-06-13 12:39:51 +00:00
Dmitrii Gridin c046bedfc2 [AA FIR] FirLazyAnnotationTransformer: fix resolve contract violation
We can't reduce resolve to COMPILER_REQUIRED_ANNOTATIONS phase for
annotations with arguments, because currently they don't have
argument mapping

```stracktrace
org.jetbrains.kotlin.utils.KotlinExceptionWithAttachments: By now the annotations argument mapping should have been resolved
	at org.jetbrains.kotlin.analysis.api.fir.annotations.FirAnnotationUtilsKt.mapAnnotationParameters(firAnnotationUtils.kt:137)
	at org.jetbrains.kotlin.analysis.api.fir.FirUtilsKt.toKtAnnotationApplication(FirUtils.kt:79)
	at org.jetbrains.kotlin.analysis.api.fir.annotations.FirAnnotationUtilsKt.annotationsByClassId(firAnnotationUtils.kt:60)
	at org.jetbrains.kotlin.analysis.api.fir.annotations.FirAnnotationUtilsKt.annotationsByClassId$default(firAnnotationUtils.kt:46)
```

^KT-57424 Fixed
2023-03-22 10:33:27 +01:00
Dmitrii Gridin ba9520f5c5 [SLC] add more tests
^KT-56046
2023-02-03 19:49:04 +00:00
Dmitrii Gridin 3b9318bd3a [SLC] LazyAnnotationsBox: drop redundant synchronization
We can use less strict rule for produced annotations:
* Previously: the same annotations from `findAnnotation` and `annotations`
have the same identity
* Now: the same annotations from `findAnnotation` and `annotations`
are equals by 'equals'

^KT-56046
2023-02-03 19:49:03 +00:00
Anna Kozlova d7179d929f [LC] add isEquivalentTo implementation so LC can be referenced from java
otherwise references from java to ktElements won't be treated as references,
cause java references resolve to light elements and search can/should be called
on ktElements
2023-01-09 18:43:57 +00:00
Dmitrii Gridin cebccee4be [SLC] add inheritors testData for facade class 2022-12-13 16:54:26 +00:00
Dmitrii Gridin 66dc7a3168 [SLC] make inheritors testData more human-readable 2022-12-13 16:54:26 +00:00
Dmitrii Gridin 69d308edac [SLC] change 'inh.txt' extension to 'inheritors.txt' for tests 2022-12-13 16:54:25 +00:00
Dmitrii Gridin aa625ffb0d [SLC] implement 'isInheritor' for 'DefaultImpls'
^KT-55442 Fixed
2022-12-13 16:54:25 +00:00
Dmitrii Gridin b2c0a37050 [SLC] implement infrastructure for light class hierarchy tests 2022-12-13 16:54:25 +00:00
Dmitrii Gridin feff03894f [SLC] fix testData dir name 2022-12-13 16:54:24 +00:00