fix: replace byte with u8

BREAKING: the V compiler removed the byte type alias in favor of u8.
This commit is contained in:
Jef Roosens 2022-04-30 11:43:06 +02:00
parent 20707f6af1
commit 7722d5a7e4
Signed by untrusted user: Jef Roosens
GPG key ID: B75D4F293C7052DB
4 changed files with 7 additions and 7 deletions

View file

@ -30,7 +30,7 @@ pub fn reader_to_file(mut reader io.BufferedReader, length int, path string) ? {
file.close()
}
mut buf := []byte{len: util.reader_buf_size}
mut buf := []u8{len: util.reader_buf_size}
mut bytes_left := length
// Repeat as long as the stream still has data
@ -60,7 +60,7 @@ pub fn hash_file(path &string) ?(string, string) {
mut sha256sum := sha256.new()
buf_size := int(1_000_000)
mut buf := []byte{len: buf_size}
mut buf := []u8{len: buf_size}
mut bytes_left := os.file_size(path)
for bytes_left > 0 {