Change Rust generated file defaults (#7101)

* Change Rust generated file defaults

After #6731, flatc changed its default behavior
for generating rust code to fix some importing issues.
This was a breaking change which invlidated the patch release,
`flatc 2.0.5` (#7081). This PR reverses the default so we can
release a patch update. However, does break Rust users who work at
HEAD.

* Bump flatc patch version (2.0.6)

Co-authored-by: Casper Neo <cneo@google.com>
This commit is contained in:
Casper
2022-02-15 11:48:42 -05:00
committed by GitHub
parent 3413c33004
commit 615616cb55
26 changed files with 35 additions and 26 deletions

View File

@@ -125,12 +125,13 @@ CPP_17_OPTS = NO_INCL_OPTS + [
"--cpp-static-reflection",
"--gen-object-api",
]
RUST_OPTS = BASE_OPTS + ["--rust", "--gen-all", "--gen-name-strings"]
RUST_OPTS = BASE_OPTS + ["--rust", "--gen-all", "--gen-name-strings", "--rust-module-root-file"]
RUST_SERIALIZE_OPTS = BASE_OPTS + [
"--rust",
"--gen-all",
"--gen-name-strings",
"--rust-serialize",
"--rust-module-root-file",
]
TS_OPTS = ["--ts", "--gen-name-strings"]
LOBSTER_OPTS = ["--lobster"]
@@ -449,4 +450,4 @@ if not args.skip_gen_reflection:
"reflection_generated.h")
# Python Reflection
flatc_reflection(["-p"], "python/flatbuffers", "reflection")
flatc_reflection(["-p"], "python/flatbuffers", "reflection")