https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68322
Bug ID: 68322 Summary: -Wodr warning on templates should list the instantiation Product: gcc Version: 5.2.1 Status: UNCONFIRMED Severity: minor Priority: P3 Component: lto Assignee: unassigned at gcc dot gnu.org Reporter: thiago at kde dot org Target Milestone: --- When compiling a certain part of Qt, I get: qshareddata.h:129:26: warning: type ‘struct QExplicitlySharedDataPointer’ violates one definition rule [-Wodr] template <class T> class QExplicitlySharedDataPointer ^ qshareddata.h:129:26: note: a different type is defined in another translation unit qshareddata.h:215:8: note: the first difference of corresponding definitions is field ‘d’ T *d; ^ The warning itself is bogus (probably bug 66180), but regardless of that, the warning output should list which instantiation of the template class the compiler is talking about.