Tim Docker

Results 134 comments of Tim Docker

Would this generated code work in older versions of typescript? Having had problems with this in the past, we test that the generate code works with typescript versions 2.9, 3.5...

FWIW, we normally turn off linting for all the generated code - there doesn't seem to be much value in lint checking code that wasn't written by humans.

You have to write the instance for `AdlValue` to implement the de/serialization to/from json. I'll extend the test to a fully worked example.

You either need to use a newtype or create an orphan instance. I don't think it would be feasible to inject the value into the [Value.hs](https://github.com/timbod7/adl/blob/master/haskell/runtime/src/ADL/Core/Value.hs) source file.

The issue with newtypes and/or orphan instances is annoying - it applies both in the haskell and the rust language backends. However, the implementation of serialization for generics current relies...

> But in the future ADL will (hopefully) develop a binary serialization See https://github.com/timbod7/adl/issues/75 I'm not against the idea, just haven't had a driving need. The json serialization has been...

> A large portion of the Haskell community is a await of the argument against using typeclasses for serialization. > ... > As mentioned, warrgonaut and sv also are typeclassless...

> I'm not sure if this is related. It is related. These newtype wrappers existing because * haskell Maybe has different serializations for adl `Nullable` and [`sys.types.Maybe`](https://github.com/timbod7/adl/blob/master/adl/stdlib/sys/types.adl#L17) * haskell Map...

> I think it would be better indeed to modify the haskell and rust code generators to use this approach, making them consistent with the other language backends. I started...