Huston, we have a problem !
Maurizio Cimadamore
maurizio.cimadamore at oracle.com
Fri Feb 18 09:14:28 PST 2011
On 18/02/11 17:10, Florian Weimer wrote:
> * Maurizio Cimadamore:
>
>>> But are these concepts actually different? If they are, there has to
>>> be case where adding<> to a raw type results in different results at
>>> run-time.
>> Well, because of type-erasure you won't be able to tell the difference
>> between List<String> and List<Integer> either - so are they the same
>> thing?
> Clearly, those a different at compile time. What I'm looking for is a
> case where both Foo and Foo<> result in legal expressions at compile
> time and produce different byte code.
>
As I've shown with my example, Foo and Foo<> are different at
compile-time. Just as List<String> and List<Integer> are (well, in a
more subtle way). They have different members, different supertypes etc.
They are just different types.
Maurizio
More information about the coin-dev
mailing list