Change deprecated type pragma syntax

Sorry that this messes with the style here, but it would be nice to have this syntax removed given how long it's been deprecated (https://github.com/nim-lang/Nim/pull/20199).
This commit is contained in:
metagn 2022-08-11 09:58:48 +03:00 committed by flyx
parent 947207dd02
commit c7d8aa6467
1 changed files with 2 additions and 3 deletions

View File

@ -54,8 +54,7 @@ type
mapStyle*: CollectionStyle
# compiler does not like Table[YamlNode, YamlNode]
YamlDocument* = object
{.deprecated: "use YamlNode with serialization API instead".}
YamlDocument* {.deprecated: "use YamlNode with serialization API instead".} = object
## Represents a YAML document.
root*: YamlNode
@ -336,4 +335,4 @@ iterator mpairs*(node: var YamlNode):
## Iterates over all key-value pairs of a mapping. *node* must be a
## *yMapping*. Values can be modified.
doAssert node.kind == yMapping
for key, value in node.fields.mpairs: yield (key, value)
for key, value in node.fields.mpairs: yield (key, value)