CMake/Tests/CompileFeatures/cxx_reference_qualified_fun...

12 lines
125 B
C++

struct test{
void f() & { }
void f() && { }
};
void someFunc(){
test t;
t.f(); // lvalue
test().f(); // rvalue
}