You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The section dcl.init.ref of the C++ standard contains rules for initialization of references. However, the case when the initializer is a function lvalue seem to be covered twice: first time implicitly in [dcl.init.ref]/5.1.1:
If [...] the initializer expression
is an lvalue (but is not a bit-field), and “cv1 T1” is reference-compatible with “cv2 T2”, or [...]
Otherwise, if the initializer expression is an rvalue (but not a bit-field) or function lvalue and “cv1 T1” is reference-compatible with “cv2 T2”, or [...].
Moreover, the second instance is hidden behind otherwise, and so cannot apply to anything.
is this intentional?
The text was updated successfully, but these errors were encountered:
The section dcl.init.ref of the C++ standard contains rules for initialization of references. However, the case when the initializer is a function lvalue seem to be covered twice: first time implicitly in [dcl.init.ref]/5.1.1:
and second time explicitly in [dcl.init.ref]/5.3.1:
Moreover, the second instance is hidden behindotherwise
, and so cannot apply to anything.is this intentional?
The text was updated successfully, but these errors were encountered: