mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
all: automatic error propagation in place of "or { return(err) }"
This commit is contained in:
@@ -261,9 +261,7 @@ $config.content'
|
||||
$if debug_net_socket_client ? {
|
||||
eprintln('sending:\n$message')
|
||||
}
|
||||
client.send(message.str, message.len) or {
|
||||
return error(err)
|
||||
}
|
||||
client.send(message.str, message.len)?
|
||||
bytes, blen := client.recv(4096)
|
||||
received := unsafe {bytes.vstring_with_len(blen)}
|
||||
$if debug_net_socket_client ? {
|
||||
|
Reference in New Issue
Block a user