4 ms·
Hrm, what do you think about rust vs Felix? They seem to be targeting the same problem.
by Rickasaurus 13y ago
Hrm, what do you think about rust vs Felix? They seem to be targeting the same problem.
- srean 13y agoI have to delegate that to John (Felix's author) not much of a language theorist myself. It seems to me that Rust wants to be the better/safer C replacement. I think Felix's sweet spot is at a slightly higher level. For example, Felix's garbage collector can indeed be avoided for lower level code, it was meant to be used as an optional feature, but to me it seems it requires more than superficial knowledge to avoid it successfully.
- skaller 13y agoRust and Felix both try to be general languages so they're both targeting that. Felix has a better type system. Rust provides more secure but restricted protocol for concurrency, Felix has no such restrictions, it's specifically designed to support shared memory concurrency, which Rust specifically doesn't allow. Rust uses message passing but organises via the memory management mechanism to do it very fast.
- dbaupp 13y agoNote that Rust does allowed shared memory, either via "unsafe" code (i.e. same flexibility & dangers as in C, but the compiler only accepts it when wrapped in an `unsafe {}` block, so it's clear that you need to be careful), or higher level wrappers around this like Arc[1] for immutable shared memory, or RWArc[2] & MutexArc[3] for mutable shared memory. > Felix has a better type system What do you mean by this? From what I can see, the only way Felix encodes any form of memory safety (e.g. dangling pointers) in the type system is by garbage collection. [1]: http://static.rust-lang.org/doc/master/extra/arc/struct.Arc.html http://static.rust-lang.org/doc/master/extra/arc/struct.Arc.... [2]: http://static.rust-lang.org/doc/master/extra/arc/struct.RWArc.html http://static.rust-lang.org/doc/master/extra/arc/struct.RWAr... [3]: http://static.rust-lang.org/doc/master/extra/arc/struct.MutexArc.html http://static.rust-lang.org/doc/master/extra/arc/struct.Mute...