3 ms·
This isn’t really enough. What you really want is something that hoists C memory management into the the language you’re using; for example, the constructor for
by saagarjha 8y ago
This isn’t really enough. What you really want is something that hoists C memory management into the the language you’re using; for example, the constructor for a high-level type would manage allocating memory and calling the constructor function, and the deinitializer would map to the custom free/close/release method. This isn’t really anything that I think can be automated; you’re going to have to write this wrapper yourself or find someone who’s already done it.
- nickpsecurity 8y agoYou might be able to kernelize it in a way where other language features are built on top of it. That's what House team did for a Haskell-based OS with unsafe stuff was stuffed into the H Layer. http://programatica.cs.pdx.edu/House/ http://programatica.cs.pdx.edu/House/ Likewise, metaprogramming routines that generate C code or interfaces for you from language statements closer to host.