Generated-output differences

quicktype output changed between the PR base and tested PR merge revisions.
← Back to the pull request
1test cases
1files differ
0modified
0new
1deleted
65changed lines
+0 −65insertions / deletions
Base b721ef1f17dcb0e7c65a3b506fbf359cacb9f159 · PR merge d95bf1fce34798a95551dc12b9740b93e542689d · Head 611385220ccebc44727de8df1729a6843b7db20e · raw patch
Test case

test/inputs/schema/rust-cycle-breaker-union.schema

1 generated file · +0 −65
Dschema-pikedefault / TopLevel.pmod+0 −65
@@ -1,65 +0,0 @@
1-// This source has been automatically generated by quicktype.
2-// ( https://github.com/quicktype/quicktype )
3-//
4-// To use this code, simply import it into your project as a Pike module.
5-// To JSON-encode your object, you can pass it to `Standards.JSON.encode`
6-// or call `encode_json` on it.
7-//
8-// To decode a JSON string, first pass it to `Standards.JSON.decode`,
9-// and then pass the result to `<YourClass>_from_JSON`.
10-// It will return an instance of <YourClass>.
11-// Bear in mind that these functions have unexpected behavior,
12-// and will likely throw an error, if the JSON string does not
13-// match the expected interface, even if the JSON itself is valid.
14-
15-class TopLevel {
16- Next next; // json: "next"
17- string value; // json: "value"
18-
19- string encode_json() {
20- mapping(string:mixed) json = ([
21- "next" : next,
22- "value" : value,
23- ]);
24-
25- return Standards.JSON.encode(json);
26- }
27-}
28-
29-TopLevel TopLevel_from_JSON(mixed json) {
30- TopLevel retval = TopLevel();
31-
32- retval.next = json["next"];
33- retval.value = json["value"];
34-
35- return retval;
36-}
37-
38-class Node {
39- Next next; // json: "next"
40- string value; // json: "value"
41-
42- string encode_json() {
43- mapping(string:mixed) json = ([
44- "next" : next,
45- "value" : value,
46- ]);
47-
48- return Standards.JSON.encode(json);
49- }
50-}
51-
52-Node Node_from_JSON(mixed json) {
53- Node retval = Node();
54-
55- retval.next = json["next"];
56- retval.value = json["value"];
57-
58- return retval;
59-}
60-
61-typedef Node|string Next;
62-
63-Next Next_from_JSON(mixed json) {
64- return json;
65-}
No generated files match these filters.