| 1 | //===----------------------------------------------------------------------===// |
| 2 | // |
| 3 | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
| 4 | // See https://llvm.org/LICENSE.txt for license information. |
| 5 | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
| 6 | // |
| 7 | //===----------------------------------------------------------------------===// |
| 8 | |
| 9 | // UNSUPPORTED: c++03, c++11, c++14, c++17 |
| 10 | |
| 11 | // <memory> |
| 12 | |
| 13 | // shared_ptr |
| 14 | |
| 15 | // bool unique() const; // deprecated in C++17, removed in C++20 |
| 16 | |
| 17 | #include <memory> |
| 18 | |
| 19 | void f() { |
| 20 | const std::shared_ptr<int> p; |
| 21 | p.unique(); // expected-error {{no member named 'unique' in 'std::shared_ptr<int>}} |
| 22 | } |
| 23 | |