add raises annotation
This commit is contained in:
parent
b68d33cef2
commit
76004d35af
|
@ -71,7 +71,7 @@
|
|||
## more requests will be needed for a lookup (adding bandwidth and latency).
|
||||
## This might be a concern for mobile devices.
|
||||
|
||||
{.push raises: [Defect].}
|
||||
{.push raises: [].}
|
||||
|
||||
import
|
||||
std/[tables, sets, options, math, sequtils, algorithm, strutils],
|
||||
|
|
|
@ -36,7 +36,7 @@ type
|
|||
proc sendToA(t: Transport, a: Address, data: seq[byte]) =
|
||||
let ta = initTAddress(a.ip, a.port)
|
||||
let f = t.transp.sendTo(ta, data)
|
||||
f.callback = proc(data: pointer) {.gcsafe.} =
|
||||
f.callback = proc(data: pointer) {.gcsafe, raises: [].} =
|
||||
if f.failed:
|
||||
# Could be `TransportUseClosedError` in case the transport is already
|
||||
# closed, or could be `TransportOsError` in case of a socket error.
|
||||
|
|
Loading…
Reference in New Issue