aaron.ballman added inline comments.
================
Comment at: lib/Sema/SemaType.cpp:1212
-static StringRef getImageAccessAttrStr(AttributeList *attrs) {
+static OpenCLAccessAttr::Spelling getImageAccessAttr(AttributeList *attrs) {
if (attrs) {
----------------
Since we're updating this, can you change `attrs` to `Attrs`, and maybe make it
a `const AttributeList *`?
================
Comment at: lib/Sema/SemaType.cpp:1224
}
- return "";
+ return OpenCLAccessAttr::Keyword_read_only;
}
----------------
The caller can no longer tell the difference between a real-only OpenCL access
attribute and no OpenCL access attribute. I know that this was the effective
behavior of the original code, but that's specific to the current use case, so
I think this change is a tiny regression in the semantics.
================
Comment at: lib/Sema/SemaType.cpp:1629
+ Result = Context.Id##ROTy; break; \
+ default: assert(0 && "Unknown access attribute!"); \
+ } \
----------------
Just checking, but, has this situation already been diagnosed elsewhere?
Repository:
rL LLVM
https://reviews.llvm.org/D26668
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits