1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

vlib,cgen: cleanup array inits using `.repeat() instead of new init syntax

This commit is contained in:
Emily Hudson
2020-06-27 20:46:04 +01:00
committed by GitHub
parent 2669610be9
commit c84bafbdae
31 changed files with 52 additions and 53 deletions

View File

@ -26,7 +26,7 @@ fn mt19937_basic_test() {
fn gen_randoms(seed_data []u32, bound int) []u64 {
bound_u64 := u64(bound)
mut randoms := [u64(0)].repeat(20)
mut randoms := []u64{len:(20)}
mut rnd := mt19937.MT19937RNG{}
rnd.seed(seed_data)
for i in 0 .. 20 {