[Sema] Adjust addr space of reference operand in compound assignment
authorAnastasia Stulova <anastasia.stulova@arm.com>
Tue, 19 Mar 2019 16:50:21 +0000 (16:50 +0000)
committerAnastasia Stulova <anastasia.stulova@arm.com>
Tue, 19 Mar 2019 16:50:21 +0000 (16:50 +0000)
commit4ce581e5a9f902e5b6db0fd3115f5e914f105207
tree287c73f2295624a992002939e68bdd4db271fec8
parent7a8e5051f412e669cbf60c5406c70239d6518eea
[Sema] Adjust addr space of reference operand in compound assignment

When we create overloads for the builtin compound assignment operators
we need to preserve address space for the reference operand taking it
from the argument that is passed in.

Differential Revision: https://reviews.llvm.org/D59367

llvm-svn: 356475
clang/lib/Sema/SemaOverload.cpp
clang/test/CodeGenOpenCLCXX/addrspace-operators.cl