change common module to parser

This commit is contained in:
Eric 2024-02-08 07:12:11 +11:00
parent f8260e9154
commit 1a506be83a
No known key found for this signature in database
3 changed files with 6 additions and 6 deletions

View File

@ -1,11 +1,11 @@
import ./json/common
import ./json/parser
import ./json/deserializer
import ./json/stdjson
import ./json/pragmas
import ./json/serializer
import ./json/types
export common
export parser
export deserializer
export stdjson
export pragmas

View File

@ -12,13 +12,13 @@ import pkg/stint
import pkg/questionable
import pkg/questionable/results
import ./common
import ./parser
import ./errors
import ./stdjson
import ./pragmas
import ./types
export common
export parser
export chronicles except toJson
export stdjson
export pragmas
@ -281,11 +281,11 @@ proc fromJson*(
_: type JsonNode,
jsn: string
): ?!JsonNode =
return common.parseJson(jsn)
return parser.parseJson(jsn)
proc fromJson*[T: ref object or object](
_: type T,
jsn: string
): ?!T =
let jsn = ? common.parseJson(jsn) # full qualification required in-module only
let jsn = ? parser.parseJson(jsn) # full qualification required in-module only
T.fromJson(jsn)