summaryrefslogtreecommitdiff
path: root/xs_json.h
diff options
context:
space:
mode:
authordefault <nobody@localhost>2022-09-25 22:57:18 +0200
committerdefault <nobody@localhost>2022-09-25 22:57:18 +0200
commitd86f6ee27f63b120fce952e0905a8c627861ba81 (patch)
tree30b2eeb88f5f2838cc8ebc0719c74c11cbf4b3aa /xs_json.h
parent424557fcb8a70df8ab84cdab270057259664aa8f (diff)
Backported from xs.
Diffstat (limited to 'xs_json.h')
-rw-r--r--xs_json.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/xs_json.h b/xs_json.h
index 8aa3f16..4915a62 100644
--- a/xs_json.h
+++ b/xs_json.h
@@ -111,7 +111,7 @@ d_char *_xs_json_dumps(d_char *s, char *data, int level, int indent)
}
break;
- case XSTYPE_SOL:
+ case XSTYPE_LIST:
s = xs_str_cat(s, "[");
while (xs_list_iter(&data, &v)) {
@@ -129,7 +129,7 @@ d_char *_xs_json_dumps(d_char *s, char *data, int level, int indent)
break;
- case XSTYPE_SOD:
+ case XSTYPE_DICT:
s = xs_str_cat(s, "{");
while (xs_dict_iter(&data, &k, &v)) {
@@ -171,7 +171,7 @@ d_char *xs_json_dumps_pp(char *data, int indent)
xstype t = xs_type(data);
d_char *s = NULL;
- if (t == XSTYPE_SOL || t == XSTYPE_SOD) {
+ if (t == XSTYPE_LIST || t == XSTYPE_DICT) {
s = xs_str_new(NULL);
s = _xs_json_dumps(s, data, 0, indent);
}