According to [dcl.init.ref]p5:
A reference to type “cv1 T1” is initialized by an expression of type “cv2 T2”
as follows:— If the reference is an lvalue reference and the initializer expression — is an lvalue (but is not a bit-field), and “cv1 T1” is reference-compatible with “cv2 T2”, or — has a class type (i.e., T2 is a class type), where T1 is not reference-related to T2, and can be converted to an lvalue of type “cv3 T3”, where “cv1 T1” is reference-compatible with “cv3 T3” (this conversion is selected by enumerating the applicable conversion functions and choosing the best one through overload resolution), then the reference is bound to the initializer expression lvalue in the first case and to the lvalue result of the conversion in the second case (or, in either case, to the appropriate base class subobject of the object). — Otherwise, [...]
If the overload resolution fails in the second case, the program should continue
to check other conditions and the program is NOT ill-formed at this point. But
the code here sets the program to ill-formed state.