[PATCH] D61318: [Sema] Prevent binding references with mismatching address spaces to temporaries

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 1 02:03:14 PDT 2019


Anastasia marked an inline comment as done.
Anastasia added inline comments.


================
Comment at: lib/Sema/SemaInit.cpp:4836
+  if (T1Quals.hasAddressSpace()) {
+    if (!T1Quals.isAddressSpaceSupersetOf(cv1T1IgnoreAS.getQualifiers())) {
+      Sequence.SetFailed(
----------------
rjmccall wrote:
> Isn't `cv1T1IgnoreAS.getQualifiers()` always `LangAS::Default`?
Yes, this is true currently. However, we don't have an overload of `isAddressSpaceSupersetOf` that takes `LangAS` as a parameter. Are you suggesting to add it?


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

https://reviews.llvm.org/D61318





More information about the cfe-commits mailing list