summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2023-01-03[Go]Add go.mod (#7720)Michael Le1-0/+3
Co-authored-by: Derek Bailey <derekbailey@google.com>
2023-01-03Fix "'flatbuffers::FieldDef* field' shadows a parameter" (#7740)Robin Giese1-1/+3
2022-12-22Add link to building guide (#7733)RishabhDeep Singh1-1/+1
2022-12-22[TS] Fix getFullyQualifiedName codegen for typescript (#7730)James Kuszmaul54-83/+104
#7451 caused getFullyQualifiedName to return a name with underscores, not periods. Because the fully qualified name is a property of FlatBuffers, not the language being codegen'd for, it should use periods. Fixes #7564. Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-22Fixed test cases (#7732)RishabhDeep Singh49-1/+97
* Fix Cannot find symbol and test case * Add generated tests Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-22Perform nil check on string fields when packing (#7719)Michael Le3-4/+13
Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-22Add CI step to build with -DFLATBUFFERS_NO_FILE_TESTS. (#7729)engedy2-0/+13
* Add CI step to build with -DFLATBUFFERS_NO_FILE_TESTS * Fix cmake syntax * Further fix cmake argumetns * Add workaround for unused-parameter. * Remove build matrix Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-21Add include guards around DoNotRequireEofTest (#7728)engedy1-0/+3
Guard DoNotRequireEofTest against -Wunused-function on platforms without file tests.
2022-12-15Fix Rust codegen escaping field in tables. (#7659)Casper7-6/+469
* Fix Rust codegen escaping field in tables. * other gencode * gencode * removed a debug print * regen code Co-authored-by: Casper Neo <cneo@google.com> Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-14Add clang-tidy, fix some bugpron problems. (#7708)Saman2-0/+348
* Add clang-tidy, fix some bugpron problems. * Fix more issues * Fix some more issues :)) * Minimal pr to just add clang-tidy Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-14[C++] Fix clang `-Wnewline-eof` warning (#7711)mogemimi17-16/+17
* Fix clang -Wnewline-eof warning * Enable -Wnewline-eof warning Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-14Add CI job to build linux and run unit test on s390x (#7707)Wen Sun1-0/+35
* create job to build linux and run unit test on s390x * update * update * update * update * update * print out machine type * create regression test to build a big endian arch and run unit tests daily * rename and schedule run on pr merged and on request * udpate Co-authored-by: Wen Sun <sunwen@google.com> Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-14Add Ref.AsStringBytes to flatbuffers.flexbuffers Python API (#7713)Jared Junyoung Lim1-0/+9
* Add Ref.AsStringBytes to flatbuffers.flexbuffers Python API * Append Bytes to AsStringBytes return value Co-authored-by: Jared Junyoung Lim <jaredlim@google.com>
2022-12-12[Go] Fix bug where `bytes` wasn't being imported when using --gen-onefile ↵Michael Le2-9/+15
flag (#7706) * Fix bug one file import bug * Create reset import function and add braces
2022-12-12fix clang format plus implicit cast error. (#7704)Saman1-3/+2
2022-12-12Fix a bug where a floating point number was cast to int and the value was ↵Maxim Zaks3-1/+6
stored incorrectly because of low byte width. (#7703) Reported in https://github.com/google/flatbuffers/issues/7690
2022-12-08[Rust] Restore public visibility of previously-public fields (#7700)Max Burke1-0/+10
* Restore public visibility of previously-public fields * code review feedback
2022-12-06FlatBuffers Version 22.12.06 (#7702)Derek Bailey161-238/+242
2022-12-06inline initialize byte_widthDerek Bailey1-3/+4
2022-12-06fix: byte_width_ = 1U << static_cast<BitWidth>(packed_type & 3) implicit ↵郭浩伟1-1/+1
conversion loses integer precision: 'unsigned int' to 'uint8_t' (aka 'unsigned char') [-Werror,-Wimplicit-int-conversion] (#7697) Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-06[C++] Update to address comparator failure in big endian (#7681)Wen Sun3-30/+46
* update unit test and generated file to test is extra endianswap can help resolve issue * remove EndianScalar wrapper from Get method * remove endianscalar wrapper * update * update * use Array instead * clang format * address error * clang * update * manually generate * Move Nim to completed language * Add swift link * address comments * update unit test * address comment * address comment * regenerate file * use auto instead of size_t * use uint32_t instead * update * format * delete extra whitespace Co-authored-by: Wen Sun <sunwen@google.com> Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-06Fix "Download Doxygen" URL (#7699)Michael Mickelson1-1/+1
2022-12-05Upgrade rules_go for Bazel 7.0 support (#7691)James Kuszmaul1-3/+3
Fixes: #7664 (hopefully) Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-12-06Refactor src/idl_gen_cpp.cpp (#7693)RishabhDeep Singh1-253/+186
* Refactor for loops and simplify code * Refactor for loops and simplify code * Fix for loop and reformat * reformat code
2022-12-05Add LICENSE.txt to python (#7692)RishabhDeep Singh2-0/+5
* Add LICENSE.txt to python * Remove LICENSE.txt from python path and used the root LICENSE.txt file
2022-12-02Add swift linkDerek Bailey1-1/+1
2022-12-02Move Nim to completed languageDerek Bailey1-4/+1
2022-12-01Fix confrom failure for nullptr dereference. (#7688)Derek Bailey3-17/+36
2022-12-01Update missing C# namespace to Google.FlatBuffersDerek Bailey4-6/+6
2022-11-30Remove --gen-name-strings flag from cmake command for generating ↵Michael Le1-1/+1
union_vector_generated.h (#7684) * Sync make outputs with master * Remove --gen-name-string flag from CMAKE
2022-11-30tests/reflection_test.h: add missing <stdint.h> include (#7680)Sergei Trofimovich1-0/+1
Without the change build fails on weekly `gcc-13` snapshots as: In file included from /build/flatbuffers/tests/reflection_test.cpp:1: tests/reflection_test.h:9:57: error: 'uint8_t' has not been declared 9 | void ReflectionTest(const std::string& tests_data_path, uint8_t *flatbuf, size_t length); | ^~~~~~~
2022-11-29Fix PHP byte validation and reenable builds (#7670)Louis Laugesen3-5/+24
* Fix PHP byte validation and reenable builds * Use checkout@v3 Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-29chore: emit more reasonable error message when using incomplete type in ↵sssooonnnggg2-0/+10
struct (#7678) Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-29Use FinshedBytes() in go-echo example instead of manually encoding offset ↵Michael Le2-20/+3
(#7660) Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-28Fix java import wild card (#7672)Saman48-190/+672
* Fix java import wild card * fix java include * Fix some import problems * clang-format * Sort imports Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-28`build.yml`: MacOs Build Inplace (#7677)Derek Bailey1-19/+17
* `build.yml`: MacOs Build Inplace * Update build.yml
2022-11-28`build.yml` Update dependencies (#7674)Derek Bailey1-34/+35
* `build.yml` Update dependencies * Update build.yml * Update build.yml * `build.yml`: Use macos-11 * Update build.yml
2022-11-23add buildkite badgeDerek Bailey1-0/+1
2022-11-23Rurel (#7663)Casper2-2/+7
* Update release script to update Rust version (it still needs to be published after) * Also update rust while I'm at it Co-authored-by: Casper Neo <cneo@google.com>
2022-11-23Specify min android SDK version of 14Derek Bailey1-0/+1
2022-11-23FlatBuffers Version 22.11.23 (#7662)Derek Bailey159-212/+212
2022-11-22FlatBuffers Version 22.11.22Derek Bailey161-250/+456
2022-11-22Add --go-module-name flag to support generating Go module compatible code ↵Michael Le13-2/+419
(#7651) * Add --go-module-name flag to support generating code for go modules * Rename echo example folder * Grammar * Update readme for go-echo example * Update readme for go-echo example * Re-enable go modules after test is done
2022-11-22Add key lookup support for tables in Go (#7644)Michael Le10-7/+365
* Add support for key lookup for tables in Go * Run clang format * Run go fmt on tests * Remove TODO in tests * Update LookupByKey API * Update LookupByKey API * Don't use resolvePointer in expectEq * Use generated getters instead of reading values directly from buffer * Fix typo Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-22Fix go generator undefined Package name, also throwing exception (#7632)Saman9-39/+264
* Fix go generator undefined Package, also throw exception in specific examples. * Add test for go generator import problem * Add new version of generated go file. Fix conflict. * Add executable permission to generate_code.py script. * Improve test quality, remove unwanted generated files, better naming * Fix comments * clang format Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-22updated method call (#7642)TJKoury1-2/+1
2022-11-22Fixed the BytesConsumed function, which was pointing slightly ahead. (#7657)Alex Ames3-7/+10
The BytesConsumed function uses the `cursor_` to determine how many bytes have been consumed by the parser, in case the user of the Parser object wants to step over the parsed flatbuffer that is embedded in some larger string. However, the `cursor_` is always one token ahead, so that it can determine how to consume it. It points at the token that is about to be consumed, which is ahead of the last byte consumed. For example, if you had a string containing these two json objects and parsed them... "{\"key\":\"value\"},{\"key\":\"value\"}" ...then the `cursor_` would be pointing at the comma between the two tables. If you were to hold a pointer to the beginning of the string and add `BytesConsumed()` to it like so: const char* json = // ... parser.ParseJson(json); json += parser.BytesConsumed(); then the pointer would skip over the comma, which is not the expected behavior. It should only consume the table itself. The solution is simple: Just hold onto a previous cursor location and use that for the `BytesConsumed()` call. The previous cursor location just needs to be set to the cursor_ location each time the cursor_ is about to be updated. This will result in `BytesConsumed()` returning the correct number of bytes without the off-by-one-token error. Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-22[C#] Fix collision of member if union name is "Value" (#7648)tira-misu1-5/+12
* Fix C/C++ Create<Type>Direct with sorted vectors If a struct has a key the vector has to be sorted. To sort the vector you can't use "const". * Changes due to code review * Improve code readability * Add generate of JSON schema to string to lib * option indent_step is supported * Remove unused variables * Fix break in test * Fix style to be consistent with rest of the code * [TS] Fix reserved words as arguments (#6955) * [TS] Fix generation of reserved words in object api (#7106) * [TS] Fix generation of object api * [TS] Fix MakeCamel -> ConvertCase * [C#] Fix collision of field name and type name * [TS] Add test for struct of struct of struct * Update generated files * Add missing files * [TS] Fix query of null/undefined fields in object api * [C#] Fix collision of member if enum name is "Value" * Fix due to style guide Co-authored-by: Derek Bailey <derekbailey@google.com>
2022-11-18Add support for using array of scalar as key field in Cpp (#7623)Wen Sun15-62/+471
* add support for using array of scalar as key field * update cmakelist and test.cpp to include the tests * update bazel rule * address comments * clang format * delete comment * delete comment * address the rest of the commnets * address comments * update naming in test file * format build file * buildifier * make keycomparelessthan call keycomparewithvalue * update to use flatbuffer array instead of raw pointer * clang * format * revert format * revert format * update * run generate_code.py * run code generator * revert changes by generate_code.py * fist run make flatc and then run generate_code.py Co-authored-by: Wen Sun <sunwen@google.com>
2022-11-17Fix schema to binary test, when build and run from all directories. ↵Saman1-1/+1
specially when add to other projects. (#7650)