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

all: replace []byte with []u8

This commit is contained in:
Alexander Medvednikov
2022-04-15 15:35:35 +03:00
parent 0527ac633e
commit fb192d949b
164 changed files with 533 additions and 533 deletions

View File

@ -63,7 +63,7 @@ pub fn (mut c UdpConn) write_ptr(b &byte, len int) ?int {
return c.write_to_ptr(remote, b, len)
}
pub fn (mut c UdpConn) write(buf []byte) ?int {
pub fn (mut c UdpConn) write(buf []u8) ?int {
return c.write_ptr(buf.data, buf.len)
}
@ -87,7 +87,7 @@ pub fn (mut c UdpConn) write_to_ptr(addr Addr, b &byte, len int) ?int {
}
// write_to blocks and writes the buf to the remote addr specified
pub fn (mut c UdpConn) write_to(addr Addr, buf []byte) ?int {
pub fn (mut c UdpConn) write_to(addr Addr, buf []u8) ?int {
return c.write_to_ptr(addr, buf.data, buf.len)
}
@ -97,7 +97,7 @@ pub fn (mut c UdpConn) write_to_string(addr Addr, s string) ?int {
}
// read reads from the socket into buf up to buf.len returning the number of bytes read
pub fn (mut c UdpConn) read(mut buf []byte) ?(int, Addr) {
pub fn (mut c UdpConn) read(mut buf []u8) ?(int, Addr) {
mut addr := Addr{
addr: AddrData{
Ip6: Ip6{}