ppx_deriving_yojson icon indicating copy to clipboard operation
ppx_deriving_yojson copied to clipboard

to_json / of_yojson attribute example doesn't compile

Open gs0510 opened this issue 5 years ago • 1 comments

The compilation of the example here fails with

File "_none_", line 1:
Error: Unbound value StringMap.to_yojson

My workaround right now is to define:

type attrs = string StringMap.t
let attrs_to_json m = StringMap.bindings m |> [%to_yojson: (string * string) list]

gs0510 avatar Feb 06 '20 14:02 gs0510

same problem with ppx_deriving_yojson 3.5.1

RCmerci avatar Mar 14 '20 12:03 RCmerci