mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-09 06:30:54 +00:00
Optionally generate Python type annotations (#7858)
* optionally generate type prefixes and suffixes for python code * fix codegen error when qualified name is empty * WIP: Python typing * more progress towards python typing * Further iterate on Python generated code typing * clang-format * Regenerate code * add documentation for Python type annotations option * generate code with Python type annotations * handle forward references * clang-format
This commit is contained in:
@@ -698,6 +698,7 @@ struct IDLOptions {
|
||||
bool require_json_eof;
|
||||
bool keep_proto_id;
|
||||
bool python_no_type_prefix_suffix;
|
||||
bool python_typing;
|
||||
ProtoIdGapAction proto_id_gap_action;
|
||||
|
||||
// Possible options for the more general generator below.
|
||||
@@ -808,6 +809,7 @@ struct IDLOptions {
|
||||
require_json_eof(true),
|
||||
keep_proto_id(false),
|
||||
python_no_type_prefix_suffix(false),
|
||||
python_typing(false),
|
||||
proto_id_gap_action(ProtoIdGapAction::WARNING),
|
||||
mini_reflect(IDLOptions::kNone),
|
||||
require_explicit_ids(false),
|
||||
|
||||
Reference in New Issue
Block a user