2021-12-10 17:44:39 +00:00
|
|
|
|
|
|
|
import
|
2021-12-10 18:16:52 +00:00
|
|
|
std/typetraits, preserves
|
2021-12-10 17:44:39 +00:00
|
|
|
|
|
|
|
type
|
2021-12-10 18:16:52 +00:00
|
|
|
Svui* {.preservesRecord: "svui".} = object
|
2021-12-10 17:44:39 +00:00
|
|
|
`svg`*: string
|
|
|
|
|
2021-12-10 18:16:52 +00:00
|
|
|
proc `$`*(x: Svui): string =
|
|
|
|
`$`(toPreserve(x))
|
2021-12-10 17:44:39 +00:00
|
|
|
|
2021-12-10 18:16:52 +00:00
|
|
|
proc encode*(x: Svui): seq[byte] =
|
|
|
|
encode(toPreserve(x))
|