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#include <utility>
12
13template <auto>
14struct Test {};
15
16void test() {
17 // LWG 3382. NTTP for pair and array
18 // https://cplusplus.github.io/LWG/issue3382
19#if !defined(_LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR)
20 constexpr std::pair<int, long> a{};
21 [[maybe_unused]] Test<a> test1{};
22#endif
23}
24

source code of libcxx/test/std/utilities/utility/pairs/pairs.pair/lwg3382.compile.pass.cpp