[RISCV] Fix mgather -> riscv.masked.strided.load combine not extending indices (...
[llvm-project.git] / libcxx / test / std / numerics / rand / rand.util / rand.util.seedseq / initializer_list.pass.cpp
blob9bfdb4c7ad3dd49c36eecbb1897049f267468129
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 // UNSUPPORTED: c++03
11 // <random>
13 // class seed_seq;
15 // template<class T>
16 // seed_seq(initializer_list<T> il);
18 #include <random>
19 #include <cassert>
21 #include "test_macros.h"
23 int main(int, char**)
25 std::seed_seq s= {5, 4, 3, 2, 1};
26 assert(s.size() == 5);
27 unsigned b[5] = {0};
28 s.param(b);
29 assert(b[0] == 5);
30 assert(b[1] == 4);
31 assert(b[2] == 3);
32 assert(b[3] == 2);
33 assert(b[4] == 1);
35 return 0;