brintos

brintos / llvm-project-archived public Read only

0
0
Text · 759 B · 0345214 Raw
31 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// <set>10 11// class set12 13// explicit set(const key_compare& comp) const;14 15#include <set>16#include <cassert>17 18#include "test_macros.h"19#include "../../../test_compare.h"20 21int main(int, char**) {22  typedef test_less<int> C;23  const std::set<int, C> m(C(3));24  assert(m.empty());25  assert(m.begin() == m.end());26  assert(m.key_comp() == C(3));27  assert(m.value_comp() == C(3));28 29  return 0;30}31