3 ms·
ARC is dynamic memory management. Is the decision to run destructors in an if block at run time? If so, that's dynamic. Rust provides dynamic memory management
by Manishearth 11y ago
ARC is dynamic memory management. Is the decision to run destructors in an if block at run time? If so, that's dynamic.
Rust provides dynamic memory management too, but you aren't forced to use it and most use it for a few variables only.
So far nothing I've seen about Swift tells me that it will be able to be used for things like Servo and other perf-critical applications. Yes, it might edge out Rust webdev, but not much more.
"You cam get a job in swift" is largely due to its iOS backing. I'm not so sure how that's going to apply to other OSs especially if Cocoa and co aren't made open source.
- Gankro 11y agoAll destructors in Rust are also decided at runtime, fwiw. Even without any allocation or anything: let foo = Moves::new(); if condition { mem::drop(foo) } // should foo be dropped here? In practice many destructors can probably be scheduled statically at compile time.
- Manishearth 11y agoDynamic drop is something that will go away for all but the strange deferred-let case (It's not a language restriction). So that's okay.