adl icon indicating copy to clipboard operation
adl copied to clipboard

1.0 Release Features

Open timbod7 opened this issue 5 years ago • 15 comments

ADL has been actively used in a range of projects for more than 4 years. It's worked well, though usage has suggested some improvements that are difficult to make in a backwards compatible fashion. Hence it is proposed that these changes be made on the master branch leading to a 1.0 release. In the meantime, bug fixes to exist releases can be made on a release-0.x branch.

Proposed 1.0 features include:

  • [x] rename Void primitive to Unit
  • [x] Address issues with Unit type in java (https://github.com/timbod7/adl/issues/56)
  • [x] Change sys.types.Map serialization to a list of map entries (not pairs)
  • [ ] Fix java builders to avoid runtime errors on incomplete construction
  • [x] Make enums in typescript be type level strings

Feel free to propose other changes in the thread.

timbod7 avatar Jul 15 '20 04:07 timbod7

  • [x] Remove Error<T> type from sys.types (it's been replaced with Result<T,E>).

timbod7 avatar Jul 15 '20 05:07 timbod7

  • [ ] packaging system.

gmhta avatar Jul 16 '20 11:07 gmhta

packaging system

Interesting! Need's some thought and discussion...

timbod7 avatar Jul 16 '20 12:07 timbod7

  • [ ] lsp

gmhta avatar Jul 16 '20 16:07 gmhta

More options for union serialisation. I particular ability to have a unit type field of a union serialise as users choice of null, {}, [] (or the existing: field label) So that the field can change in future to become any Nullable<T>, struct or Vector<T>

PaulThompson avatar Jul 17 '20 21:07 PaulThompson

Ability to opt out of unions code-generating as an enum. It complicates generic tools because unions that generate as enum have to be treated differently and during development a type can flip between being a normal union and being an enum when a field is added/removed.

PaulThompson avatar Jul 17 '20 21:07 PaulThompson

Implement Nullable<T> for c++ (target c++17 and use std::optional)

PaulThompson avatar Jul 17 '20 22:07 PaulThompson

I have added a comment on #97 (regarding strict fields). I bring this up here, because this is something that could affect backwards compatibility.

bitc avatar Jul 21 '20 13:07 bitc

In c++ - given ADL module module aa.bb.cc {}; it should be changed (non-backwards compatible) to generate c++ code in namespaces:

namespace aa {
namespace bb {
namespace cc {
// ...
}}}

Currently it generates to namespace:

namespace ADL {
namespace aa {
namespace bb {
namespace cc {
// ...
}}}

which IIUC isn't requested or controlled by the caller.

PaulThompson avatar Aug 05 '20 05:08 PaulThompson

it should be changed (non-backwards compatible)

I don't think this needs to be a backward imcompatible change - don't we just need a flag for c++ that controls into which namespace ADL code is generated? We have equivalent flags for most other target languages.

timbod7 avatar Aug 05 '20 06:08 timbod7

Drop the baked in json support in the C++ backend, and use nlohmann json.

timbod7 avatar Nov 15 '20 22:11 timbod7

There's now a milestone for "release 1.0", which will be added to issues as they make the cut.

timbod7 avatar Nov 17 '20 06:11 timbod7

@gmhta I'm leaving:

  • lsp
  • packaging system

out of the 1.0 release milestone, as I think they can be added when time permits without breaking existing usage.

timbod7 avatar Nov 17 '20 07:11 timbod7

@paul-thompson-helix

nullable support in c++ has already landed in f42788ea4d2be23fe100dbbd9da5e8a6204a2df2

timbod7 avatar Nov 17 '20 07:11 timbod7

Also see the release-1.0 branch for progress on these issues.

timbod7 avatar Dec 18 '20 08:12 timbod7