25 lines · cpp
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-exception6//7//===----------------------------------------------------------------------===//8 9// UNSUPPORTED: c++03, c++11, c++14, c++1710 11// <ranges>12 13// struct view_base { };14 15#include <ranges>16#include <type_traits>17 18static_assert(std::is_empty_v<std::ranges::view_base>);19static_assert(std::is_trivially_copyable_v<std::ranges::view_base>);20static_assert(std::is_trivially_default_constructible_v<std::ranges::view_base>);21 22// Make sure we can inherit from it, as it's intended (that wouldn't be the23// case if e.g. it was marked as final).24struct View : std::ranges::view_base { };25