cxx_reference_qualified_functions.cpp 125 B

1234567891011
  1. struct test{
  2. void f() & { }
  3. void f() && { }
  4. };
  5. void someFunc(){
  6. test t;
  7. t.f(); // lvalue
  8. test().f(); // rvalue
  9. }