[PATCH] D92108: Fix inconsistent availability attribute message string literal check.

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 4 08:57:07 PST 2020


aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.

I think this is a good change but would point out that the diagnostic message is pretty confusing as-is. `u8"a"` is a string literal, so saying that a string literal is expected doesn't make sense. We may want to consider either supporting string literals more generally or changing the diagnostic. The mixing of adjacent string literals with prefixes is something I don't think we need/want to support (esp as both C and C++ are making efforts to make such code ill-formed anyway), but I don't see why we should reject `message=u8"whatever"` (or any of the other prefixes).

However, that's an orthogonal issue and this is good incremental progress, so LGTM!


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D92108/new/

https://reviews.llvm.org/D92108



More information about the cfe-commits mailing list