A D vs. Rust example
Siarhei Siamashka
siarhei.siamashka at gmail.com
Tue Oct 25 17:42:42 UTC 2022
On Tuesday, 25 October 2022 at 17:16:58 UTC, Don Allen wrote:
> Yes, there are a lot of positive things to say about Rust. But
> for me, the insistence on no GC disqualifies it from use in
> situations where a GC-ed language would do the job, because of
> the cost in programming difficulty that that insistence
> imposes, e.g., lifetime hell and frustrating battles with the
> borrow-checker. And that difficulty is compounded by the
> multi-threaded assumption and the handling of statics.
When developing C++ code, I was solving this problem by just
embedding a Lua interpreter (and also a much less known
http://squirrel-lang.org/ because its syntax resembles C). This
approach provides GC and easy programming for the parts of a
program, which are not performance critical.
Seems like Rust also can do this just fine:
https://docs.rs/rlua/latest/rlua/
More information about the Digitalmars-d
mailing list