Re:Ask HN: Will the C programming language really die?
by steveklabnik on Thursday May 14, 2015 @10:04AM
(#9545189)
> I don't think Rust can either.
Rust has no defined ABI at this time, just like C++, but by adding the 'extern' keyword, and a '#[no_mangle]' attribute, you get the C ABI, and so then it's easy. We also support a few other ABIs as well, then it's 'extern "fastcall"' or whatever.
(This still doesn't mean "Rust will kill C" or something silly like that.)
1) Being reasonably high level
2) Having asm() be usable at all. You can't drop into asm with Go, as far as I'm aware. You can with Rust and C++, but the next point...
3) The ABI as commonly implemented is dead simple. I know how to call C from asm, and vice versa, without screwing everything up, having bizarre initialization and destruction to worry about, etc. C++ can't claim that. I don't think Rust can either.
C will live on until there's an actually usable replacement. Right now, there isn't.