[PATCH] D23895: [ms] Add support for parsing uuid as a MS attribute

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 25 18:16:03 PDT 2016


On Thu, Aug 25, 2016 at 5:46 PM, Reid Kleckner <rnk at google.com> wrote:

> rnk added a comment.
>
> I think these are known as "IDL attributes":
> https://msdn.microsoft.com/en-us/library/8tesw2eh.aspx
>
> Let's update the naming to use that terminology, so AS_MS should be
> AS_IDL, and MaybeParseMicrosoftAttributes should be
> MaybeParseMicrosoftIDLAttributes, etc.
>
> Also, doesn't this introduce ambiguities into the grammar? Something like
> this:
>
>   void useit(int);
>   int main() {
>     int uuid = 42;
>     [uuid]() {
>       useit(uuid);
>     }();
>   }
>
> Will we keep parsing that as a lambda after this change or not?


I can see why (paraphrasing that MSDN article) parsing these attributes
requires you to be a wizard.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160825/15a96420/attachment-0001.html>


More information about the cfe-commits mailing list