Steven Schäfer
05da65654e
Parcelize: Enable warnings in tests
2021-10-26 17:06:18 +02:00
Steven Schäfer
ca74b7becc
AsmLikeInstructionListingTest: Handle remaining instructions
...
Adds argument printing for TypeInsnNode, IincInsnNode,
MultiANewArrayInsnNode, InvokeDynamicInsnNode,
TableSwitchInsnNode, and LookupSwitchInsnNode.
2021-10-26 16:50:12 +02:00
Dmitriy Novozhilov
f0aba5e892
[Test] Update parcelize bytecode testdata
2021-10-12 10:30:13 +03:00
Dmitriy Novozhilov
df47bffabb
[Test] Migrate Parcelize tests to new test infrastructure
2021-10-07 13:08:45 +03:00
Steven Schäfer
00134fddf9
Parcelize: Allow Parcelize annotation on sealed classes
...
See https://issuetracker.google.com/177856520
2021-09-28 22:16:33 +02:00
Steven Schäfer
cb46a56815
Parcelize: Support unsigned array types
...
See https://issuetracker.google.com/200774823
2021-09-22 13:42:04 +02:00
Steven Schäfer
2501013012
Parcelize: Support ShortArray
...
ShortArrays are broken in the Parcelize JVM backend, which caused a
frontend error on the JVM IR backend.
2021-09-22 13:42:04 +02:00
Steven Schäfer
fc013c6b9f
Parcelize: Add an intrinsic to access Parcelable CREATOR fields
...
Fixes KT-19853.
The CREATOR field is a static field on a Parcelable class which is not
visible from Kotlin since the necessary metadata would have to be in a
Companion object which may not exist.
This commit adds a [parcelableCreator] function to kotlinx.parcelize,
which is optimized to a direct field access whenever possible.
2021-09-21 15:09:39 +02:00
Steven Schäfer
897c09bf8d
Parcelize: Use the class loader of the Parcelable class for reading
...
In `readBundle`, `readPersistableBundle`, and `readValue`.
2021-09-21 15:09:04 +02:00
Steven Schäfer
ae27be16eb
AsmLikeInstructionListingTest: Print owner for FieldInsnNode
2021-09-18 00:25:58 +02:00
Dmitry Petrov
bcafece28e
Minor: update testData
2021-09-03 15:54:19 +03:00
Steven Schäfer
b2e6e075ab
Parcelize: Fix diagnostics for parcelable value classes
2021-08-31 02:48:03 +02:00
Steven Schäfer
9fd777cb7d
Parcelize: Add support for unsigned types on the IR backend
2021-08-27 21:28:31 +02:00
Steven Schäfer
2f7bc8ca79
Parcelize: Add tests for parcelable value classes
2021-08-27 21:26:46 +02:00
Steven Schäfer
a743669bc9
Parcelize: Fix type signatures in parcelable creator objects
...
These objects are visible from annotation processors and should not
refer to the type parameters of enclosing parcelable classes.
2021-08-27 21:26:46 +02:00
Steven Schäfer
0bbb36e765
Parcelize: Add tests for obsolete issues
2021-08-27 21:26:46 +02:00
Steven Schäfer
bf7db84451
Parcelize: Handle class hierarchies of Parcelers (KT-46567)
2021-05-18 18:52:15 +02:00
Andrey Zinovyev
95140f35f8
[parcelize] Fix codegen for generic classes
...
Replace type arguments with star projection in static methods
Fix IR function generation
^KT-42652 Fixed
2021-02-04 15:11:51 +03:00
Mads Ager
ef36b81c67
[JVM_IR] Reduce the amount of super suffixes on accesibility bridges.
...
The super suffix was used for any static field/method that needed
an accessor. We should only use it when that field or method is
inherited.
2021-01-22 13:20:25 +01:00
Yan Zhulanow
e83a3c3f27
Parcelize: Use @Parcelize annotations from Android Extensions instead of the copied&deprecated ones (KT-42342, KT-43150)
...
Dex can't merge class files from both android-extensions-runtime and parcelize-runtime, so we have to keep only one copy of each class.
Instead of @Deprecated annotations, there are new diagnostics (without quick-fixes yet).
The goal is to allow simple usages (@Parcelize alone) but forbid kotlinx.android.synthetic.Parceler usage.
2020-11-11 04:25:07 +09:00
Steven Schäfer
714d17ac63
Parcelize, JVM IR: Handle star projected and nullable arrays.
2020-10-06 17:42:35 +02:00
Mads Ager
4e518e77ca
[JVM_IR] Fix expectations for parcelize tests.
...
The generated bridges now have line numbers as for the JVM
backend. There are some extra (irrelevant) labels in the JVM_IR
bytecode listing compared to JVM so expectations can still not
be shared even though they are closer.
2020-09-24 20:52:22 +02:00
Yan Zhulanow
2d158ffebd
Parcelize: Add tests for deprecated (kotlinx.android.parcel) annotations
2020-09-24 15:50:59 +09:00
Yan Zhulanow
b7796d63d8
Parcelize: Add the Parcelize compiler plugin with sources extracted from Android Extensions plugin (KT-40030)
2020-09-24 15:50:57 +09:00