Implement overloading rules for reference binding
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@58381 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaOverload.h b/lib/Sema/SemaOverload.h
index 558718c..c3fa425 100644
--- a/lib/Sema/SemaOverload.h
+++ b/lib/Sema/SemaOverload.h
@@ -97,6 +97,14 @@
/// (C++ 4.2p2).
bool Deprecated : 1;
+ /// ReferenceBinding - True when this is a reference binding
+ /// (C++ [over.ics.ref]).
+ bool ReferenceBinding : 1;
+
+ /// DirectBinding - True when this is a reference binding that is a
+ /// direct binding (C++ [dcl.init.ref]).
+ bool DirectBinding : 1;
+
/// FromType - The type that this conversion is converting
/// from. This is an opaque pointer that can be translated into a
/// QualType.
@@ -155,17 +163,7 @@
};
/// ConversionKind - The kind of implicit conversion sequence.
- /// As usual, we use "unsigned" here because VC++ makes enum bitfields
- /// signed.
- unsigned ConversionKind : 2;
-
- /// ReferenceBinding - True when this is a reference binding
- /// (C++ [over.ics.ref]).
- bool ReferenceBinding : 1;
-
- /// DirectBinding - True when this is a reference binding that is a
- /// direct binding (C++ [dcl.init.ref]).
- bool DirectBinding : 1;
+ Kind ConversionKind;
union {
/// When ConversionKind == StandardConversion, provides the