News for hackers. Stuff that matters.
Re:Why I'm Choosing C++ by eridius on Monday February 01, 2016 @01:32AM (#11010152)
It's not that Rust has a C API, it's that Rust has a simple means by which you can mark a function as using the C calling convention, and export this function as a symbol from your library, which lets anything else that speaks the C calling convention (e.g. C, or plenty of other languages) invoke that function.
Re:Why I'm Choosing C++ by Ygg2 on Monday February 01, 2016 @03:11AM (#11010468)
Yeah, I did say exposes C API. It's what most crates that have it, call it.
Re:Why I'm Choosing C++ by eridius on Monday February 01, 2016 @01:13PM (#11013785)
Saying that a particular crate has a C API makes sense. Saying that Rust has a C API suggests that Rust has some equivalent to e.g. Python or Ruby's C APIs that let you invoke arbitrary Rust code from C, which isn't true.