3 ms·
Yup. The addition of restrictions on shared mutability were fairly recent (Swift 4 IIRC) and actually go further than just structs, which was slightly surprisin
by saagarjha 7y ago
Yup. The addition of restrictions on shared mutability were fairly recent (Swift 4 IIRC) and actually go further than just structs, which was slightly surprising to me when I read the proposal: apparently the Swift compiler is allowed to insert checks to dynamically ensure exclusive read/write access to a class’s properties as well.