News for hackers. Stuff that matters.
Re:Inside D's GC by jnbiche on Tuesday June 20, 2017 @05:11PM (#14598657)
> Additionally, lifetimes are also part of the system

That "additionally" is exactly why I said "more generally". I didn't say that lifetimes were not for thread safety. I just said that they were more generally for memory safety (I would count iterator invalidation etc as memory safety, would you not?).

Re:Inside D's GC by dbaupp on Wednesday June 21, 2017 @03:25AM (#14601638)
Iterator invalidation can lead to memory unsafety in C++, usually due to a pointer or reference becoming dangling, but most other languages just treat it as a correctness problem: GC avoids the problem of invalidating pointers. As my parent comment hinted, some languages, like Java, try to detect (some occurrences of) these problems at runtime.
Re:Inside D's GC by jjnoakes on Tuesday June 20, 2017 @08:37PM (#14599732)
Some languages throw exceptions if their iterators are invalidated, right? That seems separate from memory safety to me.

Or put another way, having memory safety doesn't guarantee iterator safety.