If you generate C you can ensure it doesn't have any UB (assuming no interfacing with unsafe arbitrary C code), & can even do GC if you want (but GC is uhg).
“Knowing the lifetime statically” means “stack and register maps”, which are impossible to do in C.
-
-
No, that's dynamic. Static is a property you can determine in your HLL before doing any transpiling.
-
I think you’ll find if you try to implement it that “static lifetimes” end up being equivalent to stack and register maps.
- 3 more replies
New conversation -
-
-
Cards on the table: I’m, in vain, trying to prevent other projects from falling into the trap of “implement conservative GC, then spend a decade trying to dig out of the hole”. SpiderMonkey is the only project I know of that successfully transitioned from conservative to moving.
- 1 more reply
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.