Clang currently hits the assert in GetGVALinkageForVariable when compiling

namespace {
  struct X {};
}
extern "C" {
  X b = X();
}

The attached patch fixes it by propagating the linkage to variables,
even if they are extern "C". This seems consistent with how we handle
other interactions of language linkage and non-external linkage.

Cheers,
Rafael

Attachment: t.patch
Description: Binary data

_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to