On 04/02/2012 4:13 AM, Thomas Leonard wrote:
But it doesn't remove the need to handle diamond dependencies. Very
often (most of the time, I think), if two libraries depend on a common
one then it's because they need to communicate using a common API or
common set of data-types.
This is true
On 2/7/2012 3:24 PM, Niko Matsakis wrote:
I would appreciate feedback. I am pretty sure that the idea is sound,
but the problem is subtle and I may be missing something, so that kind
of feedback would be particularly helpful! Also, I would like to know
what else alias analysis is used for
On 2/7/12 4:23 PM, Graydon Hoare wrote:
Hm. I am confused at the description of the hole in the type system. I
was under the impression that this was the distinction between immutable
values and immutably-rooted values (those contained within a
path-of-immutable-references). Am I
On 2/7/2012 4:27 PM, Patrick Walton wrote:
On 2/7/12 4:23 PM, Graydon Hoare wrote:
Hm. I am confused at the description of the hole in the type system. I
was under the impression that this was the distinction between immutable
values and immutably-rooted values (those contained within a
On 2/7/12 4:31 PM, Graydon Hoare wrote:
Really? I think our concept quite closely mirrors most languages that
mix mutable and immutable types. Either can nest in either, and saying
something is mutable or immutable is only a statement about one level
of nesting.
I agree that we mirror
On 2/7/12 4:23 PM, Graydon Hoare wrote:
On 2/7/2012 3:24 PM, Niko Matsakis wrote:
Hm. I am confused at the description of the hole in the type system.
I was under the impression that this was the distinction between
immutable values and immutably-rooted values (those contained within a
On 2/7/12 4:27 PM, Patrick Walton wrote:
It's not a hole per se
As I pointed out elsewhere, I think this is a genuine hole. It allows
you to create an immutable box that can later be mutated, as I showed.
Niko
___
Rust-dev mailing list
Ah yes, I remember now.
Can this also be used to break refinement types (i.e. break typestate)? We have
subtyping via refinements.
Patrick
--
Sent from my Android phone with K-9 Mail. Please excuse my brevity.
Niko Matsakis n...@alum.mit.edu wrote:
On 2/7/12 4:27 PM, Patrick Walton wrote:
On 2/7/2012 7:00 PM, Niko Matsakis wrote:
I am talking about our type system as implemented. We treat immutable
fields as covariantly typed, meaning that {x:T1} : {x:T2} if T1 : T2.
This is sound so long as the field x is really immutable; but it is not.
Here is an example of where this leads