f-o-a-m / purescript-web3

a purescript library for the web3 api
Apache License 2.0
127 stars 24 forks source link

rework typlevel numbers in base 10 with `Inc`rement classs #88

Closed safareli closed 6 years ago

safareli commented 6 years ago

Also piano numbers were removed as Inc class now could be used instead of S

this should open up a way to fix https://github.com/f-o-a-m/purescript-web3-generator/issues/41

~The only part of this change which I don't like is that for vUncons they way we use Inc works fine but if you remove type annotation to code there it's used compiler can't infer the type itself, so it should be used with care.~ I removed vUncons and moved it in tests we can add it later

Before using this version of Inc I had to chose from this two:

I had to comparing this version somehow, I came up with this points:

(superclass version has more code mostly because of we need 2x IncDinstances but Line of code is not that important)

So I dicided to conditional version, which you can see here.

martyall commented 6 years ago

looks good to me