1//===----------------------------------------------------------------------===//
2//
3//                     The LLVM Compiler Infrastructure
4//
5// This file is dual licensed under the MIT and the University of Illinois Open
6// Source Licenses. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
10
11// UNSUPPORTED: c++98, c++03
12
13//  Tuples of smart pointers; based on bug #18350
14//  auto_ptr doesn't have a copy constructor that takes a const &, but tuple does.
15
16#include <tuple>
17#include <memory>
18
19int main () {
20    {
21    std::tuple<std::unique_ptr<char>> up;
22    std::tuple<std::shared_ptr<char>> sp;
23    std::tuple<std::weak_ptr  <char>> wp;
24//     std::tuple<std::auto_ptr  <char>> ap;
25    }
26    {
27    std::tuple<std::unique_ptr<char[]>> up;
28    std::tuple<std::shared_ptr<char[]>> sp;
29    std::tuple<std::weak_ptr  <char[]>> wp;
30//     std::tuple<std::auto_ptr  <char[]>> ap;
31    }
32    {
33    std::tuple<std::unique_ptr<char[5]>> up;
34    std::tuple<std::shared_ptr<char[5]>> sp;
35    std::tuple<std::weak_ptr  <char[5]>> wp;
36//     std::tuple<std::auto_ptr  <char[5]>> ap;
37    }
38}