Adjust is_cr_convertible
If To is const& then From doesn't need to be &.
This commit is contained in:
parent
726002a6a6
commit
3686c3b65c
@ -116,10 +116,16 @@ template <typename T> using hb_remove_pointer = typename hb_match_pointer<T>::ty
|
|||||||
/* TODO Add feature-parity to std::decay. */
|
/* TODO Add feature-parity to std::decay. */
|
||||||
template <typename T> using hb_decay = hb_remove_const<hb_remove_reference<T>>;
|
template <typename T> using hb_decay = hb_remove_const<hb_remove_reference<T>>;
|
||||||
|
|
||||||
#define hb_is_cr_convertible(From, To) ( \
|
#define hb_is_cr_convertible(From, To) \
|
||||||
hb_is_same (hb_decay<From>, hb_decay<To>) && \
|
( \
|
||||||
hb_is_const (From) <= hb_is_const (To) && \
|
hb_is_same (hb_decay<From>, hb_decay<To>) && \
|
||||||
hb_is_reference (From) >= hb_is_reference (To))
|
( \
|
||||||
|
hb_is_const (From) <= hb_is_const (To) && \
|
||||||
|
hb_is_reference (From) >= hb_is_reference (To) \
|
||||||
|
) || ( \
|
||||||
|
hb_is_const (To) && hb_is_reference (To) \
|
||||||
|
) \
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user