Backed out 5 changesets (bug 1890092, bug 1888683) for causing build bustages & crash...
[gecko.git] / third_party / rust / uniffi_bindgen / src / bindings / kotlin / templates / Float32Helper.kt
blobeafec5d122422057dabb80a473bc2cd5cc95388b
1 public object FfiConverterFloat: FfiConverter<Float, Float> {
2     override fun lift(value: Float): Float {
3         return value
4     }
6     override fun read(buf: ByteBuffer): Float {
7         return buf.getFloat()
8     }
10     override fun lower(value: Float): Float {
11         return value
12     }
14     override fun allocationSize(value: Float) = 4
16     override fun write(value: Float, buf: ByteBuffer) {
17         buf.putFloat(value)
18     }