Tag `writeValue` overrides with `{.raises: [IOError].}`. The override in `writer.nim` also needs `gcsafe` to support recursion in Nim 2.0.