On 6/7/11 12:59 AM, Marijn Haverbeke wrote:
Unfortunately, there's this hole I mentioned before. What this analysis guarantees is that the location pointed to by an alias will always hold a value of type X — if you reassign to it, the alias will still be valid. Except when going through a tag type. If you have an alias inside a tag (as alt creates them) and you reassign its parent, your alias might not point at memory of the right type anymore.
Sorry if I'm misunderstanding, but I thought I covered that in my previous email--we have to forbid access to the expression in an "alt" statement inside the case blocks. This means that the expression obeys normal alias rules, if it's an lval: there can only be one reference to it so that forbidding access to that one lval actually forbids access to the value.
There's actually another problem I just thought of, but it's orthogonal to this one. I have to get ready this morning, will elaborate in detail later.
Patrick _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
