https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84387

--- Comment #4 from Damian Rouson <damian at sourceryinstitute dot org> ---
I don't agree that the code submitted in this bug report is non-sensical. The
submitted example is very useful for code debugging purposes.   I just spent a
couple of hours trying to isolate this same bug.  Being able to print output
for a type with no components would have saved me the all the time that led to
finding this bug report.

Also, there are many uses for an empty derived type that serves as a
polymorphic hook on which to hang various type-bound procedures where the
choice of which procedure gets executed is determined by the dynamic type of
the passed-object dummy argument.  Moreover, if a type with no components
appears one several objects being output, the user might like to see some text
to know that the type was there.  Such types crop up frequently in the Strategy
object-oriented design pattern.

Reply via email to