Open iurii-ssv opened 1 month ago
Can you share a repro of the struct that fails?
What's also curious is that latest
version seems to be 0.1.3
while 0.1.4
seems to have been out for a while now as per https://github.com/ferranbt/fastssz/tags
➜ go install github.com/ferranbt/fastssz/sszgen@latest
...
➜ sszgen version
0.1.3
looking more into it - I believe the issue is only showing up when struct fields start with capital letter (and have int or int64 or uint type):
package storage
//go:generate sszgen -path ./shares.go --objs storageShare
type storageShare struct {
// intExample working fine
intExample int
// int64Example working fine
int64Example int64
// uintExample working fine
uintExample uint
// IntExample not working fine
IntExample int
// Int64Example not working fine
Int64Example int64
// UintExample not working fine
UintExample uint
Layer2Struct layer2Struct
}
type layer2Struct struct {
// intExample working fine
intExample int
// int64Example working fine
int64Example int64
// uintExample working fine
uintExample uint
// IntExample not working fine
IntExample int
// Int64Example not working fine
Int64Example int64
// UintExample not working fine
UintExample uint
}
I'm trying to use generator and encounter the following error(s):
int
int64
uint
It seems
uint64
works fine, is there a reason those 3 can't bessz
-encoded ?