add `{.raises.}` annotation to `writeValue` (#88)
Tag `writeValue` override with `{.raises: [IOError].}`.
This commit is contained in:
parent
3c7c1cfc76
commit
d784b823be
|
@ -14,7 +14,7 @@ proc init*(T: type WinregWriter,
|
|||
result.hKey = hKey
|
||||
result.path = path
|
||||
|
||||
proc writeValue*(w: var WinregWriter, value: auto) =
|
||||
proc writeValue*(w: var WinregWriter, value: auto) {.raises: [IOError].} =
|
||||
mixin enumInstanceSerializedFields, writeValue, writeFieldIMPL
|
||||
# TODO: reduce allocation
|
||||
|
||||
|
|
|
@ -47,7 +47,8 @@ type
|
|||
proc readValue(r: var WinregReader, value: var ValidIpAddress) =
|
||||
r.readValue(value.value)
|
||||
|
||||
proc writeValue(w: var WinregWriter, value: ValidIpAddress) =
|
||||
proc writeValue(
|
||||
w: var WinregWriter, value: ValidIpAddress) {.raises: [IOError].} =
|
||||
w.writeValue(value.value)
|
||||
|
||||
suite "optional fields test suite":
|
||||
|
|
Loading…
Reference in New Issue