I'm trying to figure out how Clang's CodeGen deals with AnnotateAttr objects. The only uses of "AnnotateAttr" I can find in the CodeGen directory seem to point to CodeGenModule::EmitAnnotateAttr(). The comment here seems to imply that this function will only handle AnnotateAttrs on GlobalValues. <br>
<br>How/where does it handle AnnotateAttrs on VarDecls, or even regular Decls? I'm asking because I have added some AnnotateAttrs to VarDecls in a plugin, had that plugin write out its AST file and then let clang compile it(with -S -emit-llvm). There was no references to my string(used in the AnnotateAttrs) or even of something like @llvm.var.annotation. So for some reason they are not making it to the IR and I have no idea why.<br>
<br>Thank you<br>