[PATCH] Sema: Treat dllimport globals without explicit storage class as extern

Nico Rieck nico.rieck at gmail.com
Wed Feb 26 15:22:11 PST 2014


On 26.02.2014 23:18, Gao, Yunzhong wrote:
> Why do you have to check whether the dllimport attribute is inherited?

Because redeclarations inherit the attribute. This would make the second
line in the following snippet a declaration instead of a definition:

__declspec(dllimport) int v;
int v;

> Do you have a test case that checks that the generated IR has the correct linkage?

I do have a comprehensive set of IRGen tests but they aren't split up
yet into incremental patches, and this first round of patches is just
for Sema.

-Nico



More information about the cfe-commits mailing list