Directories ¶
Path | Synopsis |
---|---|
Extend Display so that it can display maps whose keys are structs or arrays
|
Extend Display so that it can display maps whose keys are structs or arrays |
Modify the S-expression encoder (§12.4) and decoder (§12.6) so that they honr the sexpr:"..." field tag in a similar manner to encoding/json.
|
Modify the S-expression encoder (§12.4) and decoder (§12.6) so that they honr the sexpr:"..." field tag in a similar manner to encoding/json. |
Make display safe to use on cyclic data structures by bounding the number of steps it takes before abandoning the recursion.
|
Make display safe to use on cyclic data structures by bounding the number of steps it takes before abandoning the recursion. |
Implement the missing cases of the encode function.
|
Implement the missing cases of the encode function. |
Modify encode to pretty-print the S-expression in the style shown above
|
Modify encode to pretty-print the S-expression in the style shown above |
Adapt encode to emit JSON instead of S-expressions.
|
Adapt encode to emit JSON instead of S-expressions. |
Adapt encode so that as an optimization, it does not encode a field whose value is the zero value of its type
|
Adapt encode so that as an optimization, it does not encode a field whose value is the zero value of its type |
Exercise 12.8: The sexpr.Unmarshal function, like json.Marshal, requires the complete input in a byte slice before it can begin decoding.
|
Exercise 12.8: The sexpr.Unmarshal function, like json.Marshal, requires the complete input in a byte slice before it can begin decoding. |
Click to show internal directories.
Click to hide internal directories.