Files
sdk/tests/language
paulberry@google.com d2349ec6c4 Fix least upper bound computation for generic types (dartbug.com/15060)
Consider the classes:

class A<T> {}
class B<T> extends A<T>
class C<T> extends A<T>
class D {}
class E {}

When computing the least upper bound of B<D> and C<E>, we were making
two mistakes:

1. When computing superclasses we were using
ClassElement.getSupertype() (which doesn't substitute type arguments),
so B<D> and C<E> were considered to derive from a common type A<T>
rather than distinct types A<D> and A<E>.  A similar problem existed
for interfaces.

2. When intersecting superinterface sets, we were recursively taking
the least upper bound of type arguments, so A<D> and A<E> were
coalesced into A<Object>.  The spec and VM consider A<D> and A<E> to
be unrelated types for the purpose of least upper bound computation,
so the least upper bound should simply be Object.

R=brianwilkerson@google.com

Review URL: https://codereview.chromium.org//234213002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@34952 260f80e4-7a28-3924-810f-c04153c831b5
2014-04-10 23:07:51 +00:00
..
2014-04-08 22:40:18 +00:00
2013-11-04 18:49:41 +00:00
2014-03-12 14:39:27 +00:00
2014-03-07 10:51:39 +00:00
2013-07-25 19:28:53 +00:00
2013-10-15 09:02:08 +00:00
2013-08-28 06:48:31 +00:00
2013-12-18 15:31:41 +00:00
2014-01-17 22:13:54 +00:00
2013-08-27 17:17:35 +00:00
2013-12-18 21:05:35 +00:00
2013-07-23 12:06:25 +00:00
2013-08-07 08:04:38 +00:00
2013-12-02 12:14:57 +00:00
2014-01-27 10:42:49 +00:00