Closed GoogleCodeExporter closed 8 years ago
You want the static type system to magically know the dynamic types of the
objects
being compared. It can't.
Maybe the issue is really with the definition of equalTo. The equals method is
not
generic -- it compares values of type Object -- so equalTo should perhaps
return a
Matcher<Object> not a Matcher<T>.
Original comment by nat.pr...@gmail.com
on 6 Jul 2008 at 11:50
Thinking about this, this is *NOT* a compile error. The compiler is telling
you that
you cannot compare Double objects with just any kind of Number. This is
correct.
Original comment by nat.pr...@gmail.com
on 24 Oct 2008 at 12:33
Original issue reported on code.google.com by
i.am.pau...@googlemail.com
on 7 Mar 2008 at 6:55