https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82721
--- Comment #21 from Christopher Albert <albert at tugraz dot at> --- Created attachment 63879 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=63879&action=edit Proposed patch: fix ICE after rejected CHARACTER duplicate declaration When a CHARACTER declaration is rejected because the symbol already has a different type, the fresh charlen node survived on the namespace list with dangling references. This patch discards the unattached charlen before it can be resolved through stale pointers. Regtested on x86_64-pc-linux-gnu.
