[PATCH] Allow "redefinition" of typedef of anon tag from unimported submodule
Richard Smith via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 13 16:20:42 PST 2015
On Fri, Nov 13, 2015 at 4:03 PM, Ben Langmuir via cfe-commits <
cfe-commits at lists.llvm.org> wrote:
> This time sending to the right list address.
Likewise =)
> On Nov 13, 2015, at 4:00 PM, Ben Langmuir <blangmuir at apple.com> wrote:
> >
> > Hey Richard,
> >
> > After your commit r233345 we started diagnosing “redefinition” errors
> for typedefs of anonymous tags that are *not visible* in case like this:
> >
> > module that isn’t imported:
> > typedef struct { … } Foo_t;
> > source file:
> > typedef struct { … } Foo_t;
> >
> > I think the only change needed is to not consider these anonymous tags
> to be the same entity unless we’re in C++. Patch attached.
>
Looks fine. Do we also miscompute the linkage for these things in C (where
types don't really have linkage), or is this just a problem because we bail
out before we hit the isExternallyVisible check?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20151113/7f685b0a/attachment.html>
More information about the cfe-commits
mailing list