diff options
| author | Aaron Ballman <aaron@aaronballman.com> | 2021-01-27 15:27:53 -0500 |
|---|---|---|
| committer | Aaron Ballman <aaron@aaronballman.com> | 2021-01-27 15:30:15 -0500 |
| commit | 9f2c7effd7f386e95aff3358500bc30974d35b0d (patch) | |
| tree | 73c2c747ab70825d018ef09affba78be7cefb1a2 /clang/lib/Frontend/CompilerInvocation.cpp | |
| parent | 8e6713436462daa43d84f8450d07a54f7657c31b (diff) | |
| download | llvm-9f2c7effd7f386e95aff3358500bc30974d35b0d.zip llvm-9f2c7effd7f386e95aff3358500bc30974d35b0d.tar.gz llvm-9f2c7effd7f386e95aff3358500bc30974d35b0d.tar.bz2 | |
Parse different attribute syntaxes in arbitrary order
In Clang today, we parse the different attribute syntaxes
(__attribute__, __declspec, and [[]]) in a fairly rigid order. This
leads to confusion for users when they guess the order incorrectly,
and leads to bug reports like PR24559 or necessitates changes like
D94788.
This patch adds a helper function to allow us to more easily parse
attributes in arbitrary order, and then updates all of the places
where we would parse two or more different syntaxes in a rigid order to
use the helper method. The patch does not attempt to handle Microsoft
attributes ([]) because those are ambiguous with other code constructs
and we don't have any attributes that use the syntax.
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions
