diff options
Diffstat (limited to 'clang/qa/data/rename-move-from-global.cxx')
-rw-r--r-- | clang/qa/data/rename-move-from-global.cxx | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/clang/qa/data/rename-move-from-global.cxx b/clang/qa/data/rename-move-from-global.cxx new file mode 100644 index 0000000..b7d1c1c --- /dev/null +++ b/clang/qa/data/rename-move-from-global.cxx @@ -0,0 +1,32 @@ +class C; + +class C { +public: + C(); + ~C(); + void foo(); + inline C bar(); + inline C& operator += (int x); +}; + +C::C() {} + +C::~C() {} + +void C::foo() {} + +inline C C::bar() +{ + return C(); +} + +inline C& C::operator +=(int /*x*/) +{ + return *this; +} + +int main() { + C c; + c.foo(); + return 0; +} |