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

@@ -40,7 +40,7 @@ fn check_read_write_pipe() {
// sys_read
// sys_close
//
buffer0 := [byte(0)].repeat(128)
buffer0 := []byte{len:(128)}
buffer := byteptr(buffer0.data)
fd := [-1, -1]
@@ -87,7 +87,7 @@ fn check_read_file() {
sys_close
sys_open
*/
buffer0 := [byte(0)].repeat(128)
buffer0 := []byte{len:(128)}
buffer := byteptr(buffer0.data)
test_file := "sample_text1.txt"