You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by Allen George <al...@gmail.com> on 2021/02/27 18:00:33 UTC

Significant changes to Rust Thrift enum code generation

Hi -

To address:

1. [THRIFT-5314]: https://issues.apache.org/jira/browse/THRIFT-5314
2. [THRIFT-4101]: https://issues.apache.org/jira/browse/THRIFT-4101

I've had to make some pretty significant changes to enum code generation
(too large for a 0.14.1 IMO). To summarize, instead of using Rust enums I'm
using the newtype idiom and associated constants as suggested in JIRA; it
uses the same approach as the Flatbuffer implementation here:
https://github.com/google/flatbuffers/pull/6098

The changes are here: https://github.com/apache/thrift/pull/2337 I'm pretty
confident in it, and have run it through cross-tests, etc. If someone wants
to take a look at it before I merge it, please do.

Thanks,
Allen