SerializationException should be thrown instead.
Example: try to parse this JSON:
for deserializing this class:
class MyClass(val foo: SomeObject)
This exception is thrown:
java.lang.IllegalStateException: Expected class kotlinx.serialization.json.JsonObject but found class kotlinx.serialization.json.JsonNull
at kotlinx.serialization.json.internal.AbstractJsonTreeInput.beginStructure(TreeJsonInput.kt:224)