Commit Graph

16 Commits

Author SHA1 Message Date
Austin Schuh d56a4055da Add flatbuffer_cc library support (#5061)
* Add flatbuffer_cc library support

* Update flags so all the tests pass

Tests now all pass!

* Modify the tests to use the generated code

This should be a simple serialize/deserialize test of the new generated
code to make sure the bazel rules are doing something sane.

* Use generated monster_test.fb in testing/test.cpp

cmake drops it's generated code in tests/monster_test_generated.h
Instead of checking that in, let's generate it with bazel.

* Make grpc tests depend on monster_test_generated.h

* Remove redundant cmake dependency

This should address @aardappel's feedback.

* Run flatc for Android as well

This will fix the last travis.ci failure

* Add generated output folder and fix flags

* Move flatbuffers_header_build_rules to the library that uses it

* Use --cpp-ptr-type to fix android

Android was the only target using the STL emulation layer.  It needed
the --cpp-ptr-type flatbuffers::unique_ptr flag to work.  Add it!

* Roll back changes to use autogenerated monster_test_generated.

Flip tests/test.cpp to use the autogenerated file as well.
2018-12-10 12:23:40 -08:00
Kamil Rojewski 30c4948541 Renamed JS generator to explicitly state it generates TS too (#5043) 2018-12-06 11:12:06 -08:00
Austin Schuh f23009f04f Make flatbuffer C++ tests work when vendored with bazel (#5040)
Tests for third_party code are run out of the main workspace.  This
isn't an issue when the main workspace is the
com_github_google_flatbuffers workspace, but is an issue when you are
running the tests from another repository.

To reproduce, use "git_repository" to add flatbuffers to a project and
then run:
  bazel test @com_github_google_flatbuffers//:flatbuffers_test
2018-11-16 09:19:34 -08:00
iceboy 241e87d143 add :runtime_cc target (#4994) 2018-10-15 12:18:15 -07:00
Frank Benkstein cb5422c398 fix #4974 (#4989) 2018-10-11 12:40:41 -07:00
Sumant Tambe 49fed8c4f6 Add FlatBufferBuilder move semantics tests to the main test suite (#4902)
* Add FlatBufferBuilder move semantics tests to main

Do not eagerly delete/reset allocators in release and release_raw functions
Update android, vs2010 build files
New tests for various types of FlatBufferBuilders and move semantics

* Improve test failure output with function names
2018-09-24 12:03:31 -07:00
Robert 3c54fd964b Port FlatBuffers to Rust (#4898)
This is a port of FlatBuffers to Rust. It provides code generation and a
runtime library derived from the C++ implementation. It utilizes the
Rust type system to provide safe and fast traversal of FlatBuffers data.

There are 188 tests, including many fuzz tests of roundtrips for various
serialization scenarios. Initial benchmarks indicate that the canonical
example payload can be written in ~700ns, and traversed in ~100ns.

Rustaceans may be interested in the Follow, Push, and SafeSliceAccess
traits. These traits lift traversals, reads, writes, and slice accesses
into the type system, providing abstraction with no runtime penalty.
2018-09-02 18:26:55 -07:00
iceboy 12e5cf0b29 Remove FLATBUFFERS_COPTS from bazel BUILD (#4872)
fixes #4868
2018-08-10 13:43:48 -07:00
iceboy b9f1103b8a Add licenses to BUILD (#4867)
This allows to build flatbuffers from third_party directory.
2018-08-10 08:21:17 -07:00
aardappel 4898809eca FlatBuffers implementation for the Lobster programming language
Language, see: http://strlen.com/lobster/ and https://github.com/aardappel/lobster
2018-07-29 13:23:00 -07:00
Evan Moran a2603ec27e Add missing public header `minireflect.h` to bazel build (#4832) 2018-07-23 16:28:49 -07:00
Evan Moran 5f1b1ad42c Fixing bazel build's missing lua file (#4831) 2018-07-23 16:28:09 -07:00
Dan Field 88912640d0 Add [Dart] support (#4676)
* Add [Dart] support

* fix enum vectors

* Allow for opt out of string interning

* fix comment style, make interning opt in

* remove Offset<T>, prefer int

* avoid creating unnecessary vtable objects

* start work on tests - do not generate builder if struct has 0 fields - add int64

* support reading structs properly

* correctly handle reading vectors of structs, dartfmt

* support structs, fix unnecessary prepares

* fix bool customizations

* undo unintentional removal of file

* docs updates, complete tutorial, bug fix for codegen

* more documentation

* Update docs, add to doxygen file

* update package structure, add samples script/code

* rearrange sample

* Tests

* Add readme for pub

* cleanup package for pub

* update docs for renamed file

* remove custom matcher, use `closeTo` instead

* remove unintentional file

* remove unintended file checkin

* use auto, move method, cleanup

* refactor to ObjectBuilders, add Builders

* Update tests, examples

* Add files missing from previous commit

* documentation and example updates

* Update LICENSE, make dartanalyzer happy, fix minor bugs, get rid of duplicate files, publish script

* fix sample for slightly different schema

* Update pubspec.yaml
2018-05-18 11:06:15 -07:00
Andreas Bergmeier c0a6e5120d [C++, Go, Bazel]: Fix up Bazel support (#4672)
* Add Bazel support for Go library

* Make flatc compile again.

Was missing java_generator, which is now referenced from source.
2018-03-15 12:31:16 -07:00
Nik Hemmings fb94af8899 Protobufs: Added '--oneof-union' option. (#4647)
* Added '--oneof-union' option.

Used with the .proto -> .fbs converter, will translate protobuff oneofs to flatbuffer unions.
Updated proto test to check both methods of converting oneofs.

* Added '--oneof-union' option.

Used with the .proto -> .fbs converter, will translate protobuff oneofs to flatbuffer unions.
Updated proto test to check both methods of converting oneofs.

* FlatBuffers: Moved MakeCamel() into idl_parser.cpp

Removes library dependency on Java/C# generator code.
2018-03-05 08:45:25 -08:00
Joe Schafer c696422558 Add initial Bazel WORKSPACE and BUILD (#4608)
For #4574.

To test:

    bazel test --verbose_failures //:flatbuffers_test
2018-02-05 10:23:15 -08:00