From 7f292e4d9ed17f3a1f881dec2e715c43294e6d8c Mon Sep 17 00:00:00 2001 From: aviv-utila Date: Sun, 25 Aug 2024 14:20:48 +0300 Subject: [PATCH] Add IdlTypeF64 --- generator.go | 2 ++ idl.go | 1 + 2 files changed, 3 insertions(+) diff --git a/generator.go b/generator.go index df5c1a2..ad5479a 100644 --- a/generator.go +++ b/generator.go @@ -48,6 +48,8 @@ func typeStringToType(ts IdlTypeAsString) *Statement { stat.Qual(PkgDfuseBinary, "Uint128") case IdlTypeI128: stat.Qual(PkgDfuseBinary, "Int128") + case IdlTypeF64: + stat.Float64() case IdlTypeBytes: stat.Index().Byte() case IdlTypeString: diff --git a/idl.go b/idl.go index 2f54e46..e621780 100644 --- a/idl.go +++ b/idl.go @@ -225,6 +225,7 @@ const ( IdlTypeI64 IdlTypeAsString = "i64" IdlTypeU128 IdlTypeAsString = "u128" IdlTypeI128 IdlTypeAsString = "i128" + IdlTypeF64 IdlTypeAsString = "f64" IdlTypeBytes IdlTypeAsString = "bytes" IdlTypeString IdlTypeAsString = "string" IdlTypePublicKey IdlTypeAsString = "publicKey"