brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.0 KiB · fbea248 Raw
36 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// UNSUPPORTED: no-filesystem11 12// <filesystem>13 14// class recursive_directory_iterator15 16// bool operator==(default_sentinel_t) const noexcept {           // since C++2017//   return *this == recursive_directory_iterator();18// }19 20#include <cassert>21#include <iterator>22 23#include <filesystem>24#include "test_comparisons.h"25namespace fs = std::filesystem;26 27int main(int, char**) {28  AssertEqualityAreNoexcept<fs::recursive_directory_iterator>();29  AssertEqualityReturnBool<fs::recursive_directory_iterator>();30 31  fs::recursive_directory_iterator i;32  assert(testEquality(i, std::default_sentinel, true));33 34  return 0;35}36