ddaws / go-maker

Golang bindings to the Multi-Colatoral Dai stablecoin system
https://pkg.go.dev/github.com/ddaws/go-maker/maker?tab=overview
MIT License
0 stars 2 forks source link

Update generated contract code to return Rad, Ray, and Wad types where appropriate #3

Open ddaws opened 4 years ago

ddaws commented 4 years ago

Contract code is currently generated using abigen and uses the defaults, returning big.Int for uint256 types on chain. A custom generator should be written to allow us to return Rad, Ray, and Wad types as defined here: https://github.com/ddaws/go-maker/blob/master/maker/math.go#L15-L25

This will remove the need to for consumers to create these types and reduce the chance of user precision errors when using these types.