Hello, is it possible to serialize objects e.g. `...
# serialization
p
Hello, is it possible to serialize objects e.g.
Copy code
sealed class Error {
    @Serializable
    data class Fatal(val message: String) : Error()

    @Serializable
    object Unauthorized: Error()

    @Serializable
    object Forbidden: Error()
}
It does not throw an error but it is not the same object if i deserialize it multiple times.
s
Objects currently don't have any special support, so you likely need to write deserializers for them manually.
p
Understood, thank you for your reply.