flyx / NimYAML

YAML implementation for Nim
https://nimyaml.org
Other
191 stars 36 forks source link

Dumping doesn't work at compile time #138

Open flyx opened 1 year ago

flyx commented 1 year ago
import yaml
type
  Node = ref object
    name1: string = "A"
    name2: string = "B"
static:
  echo Dumper().dump(Node())

Compiler output:

Error: unhandled exception: field 'sym' is not accessible for type 'TNode' using 'kind = nkNilLit' [FieldDefect]

This seems to happen somewhere in macro execution. Not entirely sure where though.