Mercurial > repos > tabletprog
annotate modules/json.tp @ 368:0673ccbc7379
Add clone bethod to bytearray module
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Sun, 09 Aug 2015 20:00:08 -0700 |
parents | e2c1309ab750 |
children |
rev | line source |
---|---|
154 | 1 { |
2 startArr <- "[" byte: 0 | |
3 endArr <- "]" byte: 0 | |
4 startObj <- "{" byte: 0 | |
5 endObj <- "}" byte: 0 | |
6 quote <- "\"" byte: 0 | |
7 esc <- "\\" byte: 0 | |
8 zero <- "0" byte: 0 | |
9 nine <- "9" byte: 0 | |
10 neg <- "-" byte: 0 | |
11 space <- " " byte: 0 | |
12 comma <- "," byte: 0 | |
169
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
13 period <- "." byte: 0 |
167
5a6a55592c45
Fix some JSON parser bugs
Mike Pavone <pavone@retrodev.com>
parents:
166
diff
changeset
|
14 tab <- " " byte: 0 |
166
e7642715d575
Handle newlines and carriage returns in JSON decoder
Mike Pavone <pavone@retrodev.com>
parents:
165
diff
changeset
|
15 nl <- "\n" byte: 0 |
e7642715d575
Handle newlines and carriage returns in JSON decoder
Mike Pavone <pavone@retrodev.com>
parents:
165
diff
changeset
|
16 cr <- "\r" byte: 0 |
154 | 17 colon <- ":" byte: 0 |
165
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
18 t <- "t" byte: 0 |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
19 f <- "f" byte: 0 |
154 | 20 |
365
3d36d69aab7f
Fix JSON decoder to align with language changes
Michael Pavone <pavone@retrodev.com>
parents:
329
diff
changeset
|
21 parseNumAt <- :str at { |
154 | 22 num <- 0 |
23 l <- str length | |
24 minus <- false | |
25 aft <- -1 | |
169
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
26 ignore <- false |
154 | 27 while: { at < l } do: { |
28 b <- str byte: at | |
29 if: b = neg { | |
30 minus <- true | |
31 } else: { | |
169
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
32 if: b = period { |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
33 ignore <- true |
154 | 34 } else: { |
169
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
35 if: b >= zero && b <= nine { |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
36 if: (not: ignore) { |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
37 num <- num * 10 + (str byte: at) - zero |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
38 } |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
39 } else: { |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
40 aft <- at |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
41 at <- l |
9d8ae39e8e67
Handle floating point numbers in JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
167
diff
changeset
|
42 } |
154 | 43 } |
44 } | |
45 at <- at + 1 | |
46 } | |
47 if: aft < 0 { | |
48 aft <- at | |
49 } | |
50 if: minus { | |
51 num <- 0 - num | |
52 } | |
53 #{ | |
54 value <- num | |
55 after <- aft | |
56 } | |
57 } | |
58 | |
365
3d36d69aab7f
Fix JSON decoder to align with language changes
Michael Pavone <pavone@retrodev.com>
parents:
329
diff
changeset
|
59 parseStrAt <- :src at { |
367
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
60 //TODO: Deal with unicode escapes |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
61 bslash <- "\\" byte: 0 |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
62 quote <- "\"" byte: 0 |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
63 escapes <- dict hash |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
64 escapes set: bslash "\\" |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
65 escapes set: quote "\"" |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
66 escapes set: ("n" byte: 0) "\n" |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
67 escapes set: ("t" byte: 0) "\t" |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
68 escapes set: ("r" byte: 0) "\r" |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
69 i <- at + 1 |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
70 chunks <- #[] |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
71 start <- i |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
72 continue <- true |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
73 while: { continue && i < (src byte_length) } do: { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
74 b <- src byte: i |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
75 if: b = bslash { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
76 if: i > start { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
77 chunks append: (src from: start withLength: i-start) |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
78 } |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
79 if: i + 1 < (src byte_length) { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
80 i <- i + 1 |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
81 b <- src byte: i |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
82 start <- i + 1 |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
83 escapes ifget: b :v { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
84 chunks append: v |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
85 } else: { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
86 //not a recognized escape, just copy it raw |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
87 chunks append: (src from: i-1 withLength: 2) |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
88 } |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
89 } |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
90 } else: { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
91 if: b = quote { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
92 if: i > start { |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
93 chunks append: (src from: start withLength: i-start) |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
94 } |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
95 continue <- false |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
96 } |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
97 } |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
98 i <- i + 1 |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
99 } |
154 | 100 #{ |
367
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
101 value <- chunks join: "" |
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
102 after <- i |
154 | 103 } |
104 } | |
105 | |
106 _decode:at <- :text :cur { | |
107 ret <- false | |
108 b <- text byte: cur | |
109 if: b = neg || b >= zero && b <= nine { | |
365
3d36d69aab7f
Fix JSON decoder to align with language changes
Michael Pavone <pavone@retrodev.com>
parents:
329
diff
changeset
|
110 parseNumAt: text cur |
154 | 111 } else: { |
112 if: b = quote { | |
365
3d36d69aab7f
Fix JSON decoder to align with language changes
Michael Pavone <pavone@retrodev.com>
parents:
329
diff
changeset
|
113 parseStrAt: text cur |
154 | 114 } else: { |
115 if: b = startArr { | |
116 len <- text length | |
117 val <- #[] | |
118 cur <- cur + 1 | |
119 aft <- -1 | |
120 while: { cur < len } do: { | |
121 b <- text byte: cur | |
122 if: b = endArr { | |
123 aft <- cur + 1 | |
124 cur <- len | |
125 } else: { | |
166
e7642715d575
Handle newlines and carriage returns in JSON decoder
Mike Pavone <pavone@retrodev.com>
parents:
165
diff
changeset
|
126 if: b = comma || b = space || b = tab || b = nl || b = cr { |
154 | 127 cur <- cur + 1 |
128 } else: { | |
129 el <- _decode: text at: cur | |
130 cur <- el after | |
131 val append: (el value) | |
132 } | |
133 } | |
134 } | |
135 #{ | |
136 value <- val | |
137 after <- aft | |
138 } | |
139 } else: { | |
140 if: b = startObj { | |
141 len <- text length | |
367
e2c1309ab750
Use dict hash instead of dict linear in JSON parser. Implement basic string escapes in JSON parser.
Michael Pavone <pavone@retrodev.com>
parents:
365
diff
changeset
|
142 val <- dict hash |
154 | 143 cur <- cur + 1 |
144 aft <- -1 | |
145 expectKey <- true | |
146 key <- "" | |
147 while: { cur < len } do: { | |
148 b <- text byte: cur | |
166
e7642715d575
Handle newlines and carriage returns in JSON decoder
Mike Pavone <pavone@retrodev.com>
parents:
165
diff
changeset
|
149 if: b = comma || b = space || b = tab || b = colon || b = nl || b = cr { |
154 | 150 cur <- cur + 1 |
151 } else: { | |
152 if: expectKey { | |
153 if: b = endObj { | |
154 aft <- cur + 1 | |
155 cur <- len | |
156 } else: { | |
157 kd <- _decode: text at: cur | |
158 key <- kd value | |
159 cur <- kd after | |
167
5a6a55592c45
Fix some JSON parser bugs
Mike Pavone <pavone@retrodev.com>
parents:
166
diff
changeset
|
160 |
154 | 161 expectKey <- false |
162 } | |
163 } else: { | |
164 el <- _decode: text at: cur | |
165 val set: key (el value) | |
166 cur <- el after | |
167 expectKey <- true | |
168 } | |
169 } | |
170 } | |
171 #{ | |
172 after <- aft | |
173 value <- val | |
174 } | |
175 } else: { | |
165
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
176 if: b = t && (text from: cur withLength: 4) = "true" { |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
177 #{ |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
178 value <- true |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
179 after <- cur + 4 |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
180 } |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
181 } else: { |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
182 if: b = f && (text from: cur withLength: 5) = "false" { |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
183 #{ |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
184 value <- false |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
185 after <- cur + 5 |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
186 } |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
187 } else: { |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
188 #{ |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
189 value <- "foobar" |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
190 after <- (text length) |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
191 } |
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
192 } |
154 | 193 } |
165
fe816637fcc4
Add support for parsing true and false to JSON parser
Mike Pavone <pavone@retrodev.com>
parents:
154
diff
changeset
|
194 |
154 | 195 } |
196 } | |
197 } | |
198 } | |
199 } | |
200 #{ | |
201 decode <- :text { | |
202 (_decode: text at: 0) value | |
203 } | |
271
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
204 |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
205 encode <- :value { |
329
eef8a5cea812
Use a smarter algorithm for calculating module init order and break some circular module dependencies in the standard library
Michael Pavone <pavone@retrodev.com>
parents:
286
diff
changeset
|
206 jsonEncoder encode: value |
271
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
207 } |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
208 |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
209 main <- { |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
210 o <- #{ |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
211 foo <- "bar" |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
212 baz <- ["fizz" "buzz" "buzzzz"] |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
213 qux <- ((dict hash) set: "fo" "shizzle") set: "my" "nizzle" |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
214 arr <- #["pirate" "booty"] |
286
ddf38b66b2e2
Finish support for floating point numbers in C backend
Michael Pavone <pavone@retrodev.com>
parents:
272
diff
changeset
|
215 numbers <- [1 2 3 42 (0-1337) 3.14159] |
272
bb2b4613fdc8
Added support for encoding integers and booleans as JSON
Michael Pavone <pavone@retrodev.com>
parents:
271
diff
changeset
|
216 booleans <- [ |
286
ddf38b66b2e2
Finish support for floating point numbers in C backend
Michael Pavone <pavone@retrodev.com>
parents:
272
diff
changeset
|
217 true |
272
bb2b4613fdc8
Added support for encoding integers and booleans as JSON
Michael Pavone <pavone@retrodev.com>
parents:
271
diff
changeset
|
218 false |
bb2b4613fdc8
Added support for encoding integers and booleans as JSON
Michael Pavone <pavone@retrodev.com>
parents:
271
diff
changeset
|
219 ] |
271
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
220 } |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
221 print: (encode: o) . "\n" |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
222 0 |
bb4723fec05e
Support for encoding objects, dictionaries, lists and arrays to JSON in json module
Michael Pavone <pavone@retrodev.com>
parents:
169
diff
changeset
|
223 } |
154 | 224 } |
225 } |