[PowerPC][NFC] Cleanup PPCCTRLoopsVerify pass
[llvm-project.git] / libcxx / test / std / containers / container.adaptors / queue / queue.ops / eq.pass.cpp
blob8e7825b3fef176b4fa0ed4930c675f290cbc9b05
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 //===----------------------------------------------------------------------===//
9 // <queue>
11 // template <class T, class Container>
12 // bool operator==(const queue<T, Container>& x,const queue<T, Container>& y);
14 // template <class T, class Container>
15 // bool operator!=(const queue<T, Container>& x,const queue<T, Container>& y);
17 #include <queue>
18 #include <cassert>
20 #include "test_macros.h"
22 template <class C>
24 make(int n)
26 C c;
27 for (int i = 0; i < n; ++i)
28 c.push(i);
29 return c;
32 int main(int, char**)
34 std::queue<int> q1 = make<std::queue<int> >(5);
35 std::queue<int> q2 = make<std::queue<int> >(10);
36 std::queue<int> q1_save = q1;
37 std::queue<int> q2_save = q2;
38 assert(q1 == q1_save);
39 assert(q1 != q2);
40 assert(q2 == q2_save);
42 return 0;