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 // template<class T> 12 // requires is_object_v<T> 13 // class non-propagating-cache; 14 15 #include <ranges> 16 17 template<template<class...> class T, class ...Args> 18 concept well_formed = requires { 19 typename T<Args...>; 20 }; 21 22 struct T { }; 23 static_assert( well_formed<std::ranges::__non_propagating_cache, int>); 24 static_assert( well_formed<std::ranges::__non_propagating_cache, T>); 25 static_assert( well_formed<std::ranges::__non_propagating_cache, void (*)()>); 26 static_assert(!well_formed<std::ranges::__non_propagating_cache, void>); 27 static_assert(!well_formed<std::ranges::__non_propagating_cache, T&>); 28 static_assert(!well_formed<std::ranges::__non_propagating_cache, void()>); 29