You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Like uint64_t (from <stdint.h>) or e.g. clock_t. These are probably typedefs in the standard library. As long as C compiler is considered, it would just expand these and don't see an abstraction. (Not sure what happens as library segfaults, #131(. But arguably in Haskell bindings it could make sense to preserve the abstraction and use Word64 and CClock respectively.
hs-bindgen could have a mode for host preprocessing (generating target-independent .hsc files, i.e. doing what people do now manually); then library writers won't expose dependency on their librarary users. Personally that's the mode which I'd use. In that mode preserving an abstraction is probably a must have.
The text was updated successfully, but these errors were encountered:
In #131 we still see uint64_t fields as typedefs. So this will depend on how we will deal with typedefs (are they types or newtypes or whether it depends).
Turns out we do see uint64_t and clock_t; see #176. That doesn't of course answer the question of how to deal with these; I guess we should have a prelude of standard types, which can be extended. I can take a first stab at this.
Like
uint64_t
(from<stdint.h>
) or e.g.clock_t
. These are probably typedefs in the standard library. As long as C compiler is considered, it would just expand these and don't see an abstraction. (Not sure what happens as library segfaults, #131(. But arguably in Haskell bindings it could make sense to preserve the abstraction and useWord64
andCClock
respectively.hs-bindgen
could have a mode for host preprocessing (generating target-independent.hsc
files, i.e. doing what people do now manually); then library writers won't expose dependency on their librarary users. Personally that's the mode which I'd use. In that mode preserving an abstraction is probably a must have.The text was updated successfully, but these errors were encountered: