1 //===----------------------------------------------------------------------===//
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
7 //===----------------------------------------------------------------------===//
11 // template <class UIntType, UIntType a, UIntType c, UIntType m>
12 // class linear_congruential_engine;
14 // void discard(unsigned long long z);
19 #include "test_macros.h"
25 typedef std::linear_congruential_engine
<T
, 16807, 0, 2147483647> E
;
28 assert(e() == 1043618065);
35 typedef std::linear_congruential_engine
<T
, 48271, 0, 2147483647> E
;
38 assert(e() == 399268537);
45 typedef std::linear_congruential_engine
<T
, 48271, 123465789, 2147483647> E
;
63 rand0
<unsigned int>();
64 rand0
<unsigned long>();
65 rand0
<unsigned long long>();
68 rand
<unsigned long>();
69 rand
<unsigned long long>();
71 other
<unsigned int>();
72 other
<unsigned long>();
73 other
<unsigned long long>();