Closed joshvera closed 10 years ago
In this case, you just need to get Idris to dynamically load the C lib in question using %dynamic
.
There are some issues with laziness and type providers right now - I fixed them on an airplane a couple hours ago and I'll send a PR after I test it a bit more and perhaps sleep :-)
@david-christiansen Thanks! Then this was an issue with linking the library statically and has nothing to do with the laziness issues you mentioned right? Shall I close this out?
If you've made your (perfectly reasonable) code work by adding a %dynamic
directive, then I don't think this is a bug, and it should probably be
closed. If adding this does not fix it, then there may be a previously
unknown issue with the dynamic linking.
This fails to compile:
with:
test026.idr manages to call
readFile
without issues, but it seems we compile that specially. Could it be an issue withmkForeign
and type providers?