mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-07 05:47:36 +00:00
Add compare operator to code generated for c++ (#4940)
* Add operator== for c++ genated code New "--gen-compare" option for flatc to generate compare operators. The operators are defined based on object based api types. Inspired by issue #263. * Improve compare operator for c++. Thanks for the code review. - Improve robustness against future schema extensions - Code style - Fix --rust generation in generate_code.sh
This commit is contained in:
committed by
Wouter van Oortmerssen
parent
873a60b0d8
commit
33791dc7b0
@@ -96,6 +96,8 @@ Additional options:
|
||||
at the cost of efficiency (object allocation). Recommended only to be used
|
||||
if other options are insufficient.
|
||||
|
||||
- `--gen-compare` : Generate operator== for object-based API types.
|
||||
|
||||
- `--gen-onefile` : Generate single output file (useful for C#)
|
||||
|
||||
- `--gen-all`: Generate not just code for the current schema files, but
|
||||
|
||||
Reference in New Issue
Block a user