Returns a JSON representation of this.
@override Map<String, Object?> toJson() => { 'runtimeType': 'RefType', 'nullable': nullable, 'heap-type': heapType.toJson(), };