Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #9057
| From | Joshua Cranmer <Pidgeot18@verizon.invalid> |
|---|---|
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: eclipse and un-generics |
| Date | 2011-10-20 17:51 -0500 |
| Organization | A noiseless patient Spider |
| Message-ID | <j7q8ku$v5m$1@dont-email.me> (permalink) |
| References | <slrnja0lhk.6gl.avl@gamma.logic.tuwien.ac.at> |
On 10/20/2011 12:11 PM, Andreas Leitgeb wrote: > My attempt to use Class<?> as argument type in the implementing > class failed, and I'm not sure I understand the deeper reasons of > why this has to fail. I.e. why it doesn't just see it as an override > instead of complaining about a bad overload. While Class<?> is often treated as being the generic equivalent of Class, they're not quite the same thing. Logically, "Class" means "a class of anything", while "Class<?>" means "a class of some unknown type". Indeed, if anything, "Class" is probably closer in typing terms to "Class<Object>", although there are a slew of special rules to account for the fact that "Class<Object>" is probably very rarely meant. -- Beware of bugs in the above code; I have only proved it correct, not tried it. -- Donald E. Knuth
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar
eclipse and un-generics Andreas Leitgeb <avl@gamma.logic.tuwien.ac.at> - 2011-10-20 17:11 +0000
Re: eclipse and un-generics Joshua Cranmer <Pidgeot18@verizon.invalid> - 2011-10-20 17:51 -0500
Re: eclipse and un-generics Andreas Leitgeb <avl@gamma.logic.tuwien.ac.at> - 2011-10-22 23:04 +0000
csiph-web