Originally posted by marc weber:
That's my interpretation. I tried to get an overflow with a tangled web of constructors going around in circles calling each other, but the compiler was "smart enough" to catch it.
[ February 24, 2006: Message edited by: marc weber ]
Maybe I'm overlooking something but it seems to me that the compiler doesn't have to be particular smart to catch this error. I.e. it just needs to find atleast 1 ctor in which there is either an explicit super call or in which a super call can be inserted. No need to follow a web, just check and check off each ctor for super() appearances. If the count is 0 after looking at each ctor there must be some recursion going on.
Anyway, I would appreciate it if Bert could respond to this issue. The way he writes about it makes it look like this is a compiler implementation dependent case, but if the
Java spec actually requires this to be a compilaton error we're talking about something entirely else.
(btw, I just checked with JDT from Eclipse 3.1 and it also gives the "Recursive Contructor Innovation" message.)