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 | // <random> |
10 | |
11 | // template<class Engine, size_t k> |
12 | // class shuffle_order_engine |
13 | |
14 | // explicit shuffle_order_engine(); |
15 | |
16 | #include <random> |
17 | #include <cassert> |
18 | |
19 | #include "test_macros.h" |
20 | |
21 | void |
22 | test1() |
23 | { |
24 | std::knuth_b e1; |
25 | std::knuth_b e2(std::minstd_rand0::default_seed); |
26 | assert(e1 == e2); |
27 | assert(e1() == 152607844u); |
28 | } |
29 | |
30 | int main(int, char**) |
31 | { |
32 | test1(); |
33 | |
34 | return 0; |
35 | } |
36 | |