diff options
author | dim <dim@FreeBSD.org> | 2015-06-09 19:08:19 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2015-06-09 19:08:19 +0000 |
commit | bb9760db9b86e93a638ed430d0a14785f7ff9064 (patch) | |
tree | a59f5569ef36d00388c0428426abef26aa9105b6 /lib/Sema/SemaChecking.cpp | |
parent | 3191b2b32a96e1a6ee833fcca73e5c8e0c67ba65 (diff) | |
download | FreeBSD-src-bb9760db9b86e93a638ed430d0a14785f7ff9064.zip FreeBSD-src-bb9760db9b86e93a638ed430d0a14785f7ff9064.tar.gz |
Vendor import of clang trunk r239412:
https://llvm.org/svn/llvm-project/cfe/trunk@239412
Diffstat (limited to 'lib/Sema/SemaChecking.cpp')
-rw-r--r-- | lib/Sema/SemaChecking.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Sema/SemaChecking.cpp b/lib/Sema/SemaChecking.cpp index 23a6fc3..c3b81b6 100644 --- a/lib/Sema/SemaChecking.cpp +++ b/lib/Sema/SemaChecking.cpp @@ -1604,6 +1604,10 @@ ExprResult Sema::SemaAtomicOpsOverloaded(ExprResult TheCallResult, return ExprError(); } + // atomic_fetch_or takes a pointer to a volatile 'A'. We shouldn't let the + // volatile-ness of the pointee-type inject itself into the result or the + // other operands. + ValType.removeLocalVolatile(); QualType ResultType = ValType; if (Form == Copy || Form == GNUXchg || Form == Init) ResultType = Context.VoidTy; |