Commit Graph

1624 Commits

Author SHA1 Message Date
Denis.Zharkov 72b0372927 K2: Allow PCLA inference when a value parameter has a TV type
^KT-64877 Fixed
2024-01-11 10:32:12 +00:00
Dmitriy Dolovov 6951efe63c Metadata comparator: Support new metadata attributes (see below)
Support new metadata attributes that were added to Kotlin metadata
but are not yet supported in `MetadataDeclarationsComparator`:
- DNN type flag
- context receivers
- underlying type & property name for inline classes

^KT-62753
2024-01-11 09:26:41 +00:00
Timofey Solonin 59b8941c28 Remove ModuleResult.Missing from commonization results
This result seems to not be used

^KT-51026
2024-01-11 08:57:28 +00:00
Vladimir Sukharev 3c8e7bdfb1 [K/N][Tests] Refactor to AssertionsMode.assertionsEnabledWith() 2024-01-10 23:31:00 +00:00
Vladimir Sukharev fee2a20a55 [K/N][Tests] Support test directive ASSERTIONS_MODE
^KT-64844 Fixed
2024-01-10 23:31:00 +00:00
Vladimir Sukharev 809d652bdf [K/N][Tests] Change assertions and runtime assertions modes to default, when optimizationMode=OPT
^KT-64844 Fixed
2024-01-10 23:31:00 +00:00
Dmitrii Gridin d828a646cf [Analysis API] move allKtFiles util from LL FIR module
^KT-64805
2024-01-10 22:07:03 +00:00
Denis.Zharkov 7e4d9d9f64 K2: Add new tests for PCLA implementation
Many of them have been found & minimized at FP tests/user projects

^KT-59791 Fixed
2024-01-10 14:56:31 +00:00
eugene.levenetc 92affa1b24 [ObjCExport] Add initial objective-c function translation
KT-64226
2024-01-10 09:17:00 +00:00
Pavel Kunyavskiy 9374cacdd6 [IrActualizer] Don't actualize expect types
This was never semantically correct, but was not important
before KT-63644, as they were immediately dropped after that anyway.

After KT-63644, they were used to compute fake overrides inside them,
which were later matched against actual class, which can
produce false-positive matching errors.

^KT-64835
2024-01-09 17:53:06 +00:00
Vladimir Sukharev 7eb239c282 [K/N][Tests] Move objCActionFqName to NativeStandardInteropNames
^KT-61259
2024-01-09 14:17:47 +00:00
Vladimir Sukharev 08bc0a6bd0 [K/N] Adjust moved special backend checks tests
^KT-61564
2024-01-09 14:17:47 +00:00
Alexander Udalov d08c9ba222 JVM IR: transform fake override properties in SAM adapters
Replace every property with its getter and setter. This is needed
because later on, JVM backend assumes that all properties have been
lowered (by JvmPropertiesLowering) to this state.

 #KT-64116 Fixed
2024-01-08 21:31:13 +00:00
Sebastian Sellmair 7dbd5cd57f [ObjCExport] Implement 'test - dispatchAndExtensionReceiverWithMustBeDocumentedAnnotation'
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 90632ad746 [ObjCExport] Implement isObjCObjectType util
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair e0383282b5 [ObjCExport] Implement isObjCBaseCallable util
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair b5bcfaa2e3 [ObjCExport] translateToObjCProtocol: Support building members
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 47273a3d58 [ObjCExport] Move MethodBridge to shared module (2/2)
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 8f7e409bd7 [ObjCExport] Move MethodBridge to shared module (1/2)
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair b78f185299 [ObjCExport] Remove unnecessary instances in favor of static methods
All state will later be stored inside the KtObjCExportSession

KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 2f759243ba [ObjCExport] Implement isVisibleInObjC util
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 66533141b8 [ObjCExport] Implement getSuperClassSymbolNotAny util
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 9909940b24 [ObjCExport] Implement rudimentary interface to ObjCProtocol translation
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair aa3fa9e8c5 [ObjCExport] Implement 'findKdocString' utility for Analysis Api
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 72f135396c [ObjCExport] Extract generation of ObjC base declarations into shared code
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair aab9a606ce [ObjCExport] Split ObjCExportHeaderGenerator and ObjCExportTranslator
KT-64226
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 74c39b149f [ObjCExport] ObjCExportLazy: Get 'comment' from 'realStub' 2024-01-08 15:25:19 +00:00
Sebastian Sellmair 1cb60a53d9 [ObjCExport] Cleanup misleading test name for 'functionWithMustBeDocumentedAnnotation' 2024-01-08 15:25:19 +00:00
Sebastian Sellmair 7944a3dc4b [ObjCExport] Document 'ObjCExportStubOrigin' factory special case 2024-01-08 15:25:19 +00:00
Sebastian Sellmair 7ef62d1779 [ObjCExport] KtResolvedObjCNameAnnotation: Return null if ObjCName annotation is absent 2024-01-08 15:25:19 +00:00
Sebastian Sellmair 98fda13523 [ObjCExport] Extract header generation to shared module
^KT-64227 Fixed
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 1440e66519 [ObjCExport] Fix 'MustBeDocumented' annotation missing on non value parameters 2024-01-08 15:25:19 +00:00
Sebastian Sellmair 885a7dcd8f [ObjCExport] Implement test - kdocWithBlockTags
FL-23390
2024-01-08 15:25:19 +00:00
Sebastian Sellmair e409c60780 [ObjCExport] Split ObjCExport into K1 and Analysis Api implementation
FL-23390
^KT-64168 Fixed
2024-01-08 15:25:19 +00:00
Sebastian Sellmair 3e57265fcb [ObjCExport] ObjCExportStub: Do not retain reference to descriptor
FL-23390
^KT-64076 Fixed
2024-01-08 15:25:19 +00:00
Sebastian Sellmair e97463afb3 [ObjCExport][Minor] Reformat Code after move into newly created modules
FL-23390
2024-01-08 15:25:19 +00:00
Dmitriy Dolovov e92017f64e [KLIB Resolver] Deprecate Logger.fatal()
Invocation of Logger.fatal() may cause severe side effects such as
throwing an exception or even terminating the current JVM process
(check various implementations of this function for details).

The code that uses Logger.fatal() sometimes expects a particular kind
of side effect. This is totally a design flaw. And it's definitely not
a responsibility of Logger to influence the execution flow of
the program.
2024-01-08 13:26:24 +00:00
Vladimir Sukharev 35e5b0613d [K/N] Migrate filecheck test redundant_safepoints to new infra
^KT-62157
2024-01-08 08:59:24 +00:00
Vladimir Sukharev 35b83a1225 [K/N][FIR] Do not emit CAST_NEVER_SUCCEEDS when casting to forward declarations
^KT-61841 Fixed
2024-01-08 08:57:42 +00:00
Pavel Kunyavskiy f45d92eebc [K/N, K/JS, K/WASM] Enable FakeOverrideRebuilder by default
While not beeing final solution, this is closer to what
we want to have in the end. Enabling on non-JVM targets
would help better testing.

Enabling in JVM is now not possible yet, as some of the bugs are
not fixed yet (check KT-61360 for details)

^KT-62476
2024-01-08 07:46:07 +00:00
Pavel Kunyavskiy c6e32571d6 [FakeOverrideBuilder] Workaround KT-64743
Because of KT-64743 there is unexpanded type-alias in a place we don't
expect it to occur. To workaround this, we just expand typialiases in
one more place.

^KT-64743
2024-01-08 07:46:07 +00:00
Dmitrii Gridin b6d373d8e5 Update copyright to 2024 2024-01-05 13:43:17 +00:00
Alexander Shabalin 3f2584bb02 [K/N] Move calls checker into separate module ^KT-62091 2024-01-05 13:35:35 +00:00
Vladimir Sukharev 55bff799a8 [K/N][tests] Split tests for Any.collectReferenceFieldValues
^KT-61259
2024-01-04 18:24:37 +00:00
Vladimir Sukharev d972fec13c [K/N][tests] Move tests into better places
^KT-61259
2024-01-04 18:24:37 +00:00
Vladimir Sukharev e68bd1f04f [K/N][tests] Adjust moved tests to new testing infra
^KT-61259
2024-01-04 18:24:37 +00:00
Vladimir Sukharev 0a0da76a56 [K/N][tests] Move some more native tests to new testing infra
^KT-61259
2024-01-04 18:24:37 +00:00
Pavel Kunyavskiy 4080776fe3 [Fir2IR] Set correct module descriptors for builtins
^KT-64420
2024-01-04 17:29:58 +00:00
Andrey Yastrebov 4176c50107 KT-63592 Create setupLLDBScript task 2024-01-03 10:29:18 +00:00
Vladimir Sukharev 5728b34733 [K/N][Tests] Ignore test klibName on LInux with caches
^KT-61259
2024-01-02 18:47:05 +00:00