]> granicus.if.org Git - clang/commit
[ms-cxxabi] Implement member pointer comparisons
authorReid Kleckner <reid@kleckner.net>
Tue, 30 Apr 2013 20:15:14 +0000 (20:15 +0000)
committerReid Kleckner <reid@kleckner.net>
Tue, 30 Apr 2013 20:15:14 +0000 (20:15 +0000)
commit3d2f000df9311bfccb6d2ac350be3d3efa5a412b
tree5a1b96031f88223113f0d68cbffb1602ed178fdd
parentc7d77b25a37acad689ae5c318fdf80fde92983f0
[ms-cxxabi] Implement member pointer comparisons

Summary:
Like Itanium, comparisons are basically bitwise comparisons of the two
values, with an exception for null member function pointers.  If two
function pointers are null, only the function pointer field matters for
comparison purposes.  The rest of the bits can be arbitrary.  We take
advantage of this in isZeroInitializable(), and it may matter once we
start emitting conversions.

Reviewers: rjmccall

CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D695

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@180800 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/MicrosoftCXXABI.cpp
test/CodeGenCXX/microsoft-abi-member-pointers.cpp