https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91844

--- Comment #1 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
As a consequence, this program will become invalid:

int &f (const int *&&);

void
fn (int *p)
{
  const int *&&r = p;
  f (p);
}

With this DR, "const int *" and "int *" are reference-related, and 5.4.4. says
that in that case, if the reference is an rvalue reference, the initializer
expression shall not be an lvalue.

Reply via email to