mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-06 21:37:36 +00:00
feat: Support union underlying type for TS/JS (#7961)
This commit is contained in:
@@ -845,7 +845,7 @@ void ParseUnionTest() {
|
||||
// Test union underlying type
|
||||
const char *source = "table A {} table B {} union U : int {A, B} table C {test_union: U; test_vector_of_union: [U];}";
|
||||
flatbuffers::Parser parser3;
|
||||
parser3.opts.lang_to_generate = flatbuffers::IDLOptions::kCpp;
|
||||
parser3.opts.lang_to_generate = flatbuffers::IDLOptions::kCpp | flatbuffers::IDLOptions::kTs;
|
||||
TEST_EQ(parser3.Parse(source), true);
|
||||
|
||||
parser3.opts.lang_to_generate &= flatbuffers::IDLOptions::kJava;
|
||||
|
||||
Reference in New Issue
Block a user