Anastasia added inline comments.
================ Comment at: lib/Sema/SemaDecl.cpp:2157 if (getDiagnostics().getSuppressSystemWarnings() && - (Context.getSourceManager().isInSystemHeader(Old->getLocation()) || + // Some standard types are defined implicitly in Clang (e.g. OpenCL). + (Old->isImplicit() || New->isImplicit() || ---------------- Anastasia wrote: > ahatanak wrote: > > Is it necessary to check whether New is implicit? I was just wondering when > > or how an implicit definition would redefine a typedef. > I had a thought on it too, and I am not sure actually. This can happen if we > implicitly define something from the standard headers. But I believe the Sema > initialization should always happen before parsing the standard header or > even loading them from the PCH. So I guess this shouldn't ever happen really? > Perhaps, I should just remove this? Actually in case of implicit typedefs we don't seem to follow this program path at all. So I am removing this. https://reviews.llvm.org/D31397 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits