google / flatbuffers

FlatBuffers: Memory Efficient Serialization Library

Home Page:https://flatbuffers.dev/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add option to remove @ExperimentalUnsignedTypes in kotlin code as these are no longer unstable

aaronriekenberg opened this issue · comments

writer += "@ExperimentalUnsignedTypes";

writer += "@ExperimentalUnsignedTypes";

In Kotlin 1.5 unsigned integer types are considered stable https://kotlinlang.org/docs/whatsnew15.html#stable-unsigned-integer-types

Now all kotlin code generated by flatc has @ExperimentalUnsignedTypes which generates warnings at compile-time in the kotlin compiler. I think this happens even if unsigned types are not being used in the flatbuffer schema.

Would you consider the addition of an option to flatc to not generate the @ExperimentalUnsignedTypes so that users of Kotlin 1.5 and newer can use the now-stable unsigned types?

Thanks!