Commit Graph

690 Commits

Author SHA1 Message Date
Wouter van Oortmerssen bf07c37a53 Merge branch 'master' of https://github.com/google/flatbuffers 2016-01-19 15:56:26 -08:00
Wouter van Oortmerssen 2ab7ebc82b Merge pull request #3510 from jaakristioja/patch-1
Fixed comment typo
2016-01-19 15:36:45 -08:00
Mark Klara 0ece042162 Silenced unused variable warnings.
When built for release, builds were failing with unused
variable warnings, since they were only used in `assert()`
calls.

I added explicit void casting to any potentially unused variables.

Change-Id: I9947ba46891fdda5aa925caa950642dedd4e009f
2016-01-19 15:30:41 -08:00
Mark Klara 69a31b807a Revamping the FlatBuffers docs.
Adding an API reference for the supported languages.

General docs cleanup, including a new `tutorial` section that
supports all of the supported languages.

Added samples for each supported language to mirror the new
tutorial page.

Cleaned up all the links by making them `@ref` style links,
instead of referencing the names of the generated `.html` files.

Removed all generated files that were unnecessarily committed.

Also fixed the C# tests (two were failing due to a missing file).

Bug: b/25801305

Tested: Tested all samples on Ubuntu, Mac, and Android. Docs were
generated using doxygen and viewed on Chrome.

Change-Id: I2acaba6e332a15ae2deff5f26a4a25da7bd2c954
2016-01-19 14:31:17 -08:00
Wouter van Oortmerssen d75d29e2fe Merge branch 'master' of https://github.com/google/flatbuffers 2016-01-19 14:10:49 -08:00
Wouter van Oortmerssen 049f3f7907 Added support for parsing JSON null value.
These cause the field in question to be skipped.

Bug: 16550393
Change-Id: Id05104e89818ee773b8a91fdcc86e18061b9a82f
Tested: on Linux.
2016-01-19 14:05:27 -08:00
Wouter van Oortmerssen e848137ded Added min/max values for enums/unions.
Bug: 21642898
Change-Id: Ifaf0b3c4274fe30ef29507ba1c1216d700efe85b
Tested: on Linux.
2016-01-19 14:05:27 -08:00
Wouter van Oortmerssen f8c1980fdf Added schema evolution examples to the docs.
Bug: 26296711
Change-Id: I225067d82ac0f8bd71b2b97b1672517ca86cc3b9
Tested: on Linux.
2016-01-19 12:29:53 -08:00
Wouter van Oortmerssen 7d70082590 Merge pull request #3706 from evolutional/fix-3506
Check (& skip) of the utf-8 byte order mark
2016-01-19 11:10:07 -08:00
Wouter van Oortmerssen 8472b5f224 Merge pull request #3513 from evolutional/fix-3500
Java/C#: generation of typed helpers when using nested_flatbuffers
2016-01-19 10:40:02 -08:00
Wouter van Oortmerssen 6136dd490a Merge pull request #3498 from ncpenke/gcc-4.4.3-support
Gcc 4.4.3 support
2016-01-19 10:27:57 -08:00
Rene Fichter 3de82050ce Fix build error when flatc binary is missing in PATH. 2016-01-19 13:02:25 +01:00
Oli Wilkinson f1ab30a490 Added Visual Studio transient files to .gitignore 2016-01-18 20:54:22 +00:00
Oli Wilkinson cbe8747b59 Added check (& skipping) of the utf-8 byte order mark (0xEF BB BF) at the beginning of the file 2016-01-18 20:14:39 +00:00
Oli Wilkinson eaa2b414b2 Added generation of typed helpers when using nested_flatbuffers in Java/C#. Fixes #3500 2016-01-18 15:23:14 +00:00
Jaak Ristioja 77a6a786b8 Fixed comment typo 2016-01-13 15:30:27 +02:00
Chandra Penke b63ebad49d Fix #3497: Add support for compiling in g++ 4.4 and 4.5
- Removed uses of lambda expressions

- Added custom defines for constexpr and nullptr

- Removed trailing comma of last value from generated enums
2016-01-09 06:30:50 -06:00
Wouter van Oortmerssen 42c20d7a69 Make flatc check for binary files to avoid accidental parsing.
Binary file arguments to flatc have to be preceded by -- to
identify them, forgetting this however results in them being
attempted to be parsed as schema/json, with cryptic errors.
This instead gives an error if 0 bytes are contained in your
text file.

Bug: 22069056
Change-Id: I226bf651dcb016f18d7c8ffadcf23466a1fc0b87
Tested: on Linux.
2016-01-08 13:10:25 -08:00
Wouter van Oortmerssen 63b526db52 Ensured code is not generated directly from .proto files.
The parser state generated from the .proto conversion process is
not exactly the same as what you get by parsing the generated
schema, which can cause problems. This check enforces that you
first convert the .proto, then generate code from the new schema.

Change-Id: I04b53af9288d87e256d1cc109388332fefb3a09f
Tested: on Linux.
2016-01-08 11:39:56 -08:00
Wouter van Oortmerssen 514d274a45 Added android static library target for text parsing/generation etc.
Change-Id: If24e3eea90cef2a0d6a9d98fb503d2e3ec34ceed
Tested: on Linux.
2016-01-06 17:48:19 -08:00
Wouter van Oortmerssen 6beafd14e0 Updated docs to point to benchmark source code location.
Change-Id: If4c8fac6a421ac6436cab0dd7a0ae822a32e90bf
2016-01-06 16:51:00 -08:00
Robert b4d29970f4 Merge pull request #2098 from faizanrashid/issue-1741
[BUG] [MINOR] Use buffer for specific py versions
2016-01-06 16:13:59 -08:00
Wouter van Oortmerssen 586fdee89b Merge pull request #3494 from parnic/fix-vs2012-static-analysis
Fixed MS static analysis warnings
2016-01-06 12:34:08 -08:00
Chris Pickett 178f768f7f Changed how the SA warning is suppressed to avoid pragma stuff 2016-01-06 14:21:18 -06:00
Wouter van Oortmerssen 316854c26f Merge pull request #3495 from parnic/fix-reflection-vs2012-warnings
Fixed warning building in VS2012
2016-01-06 12:03:40 -08:00
Wouter van Oortmerssen 6532bfce34 Merge pull request #3493 from parnic/support-platforms-without-realpath
Fix build for platforms not supporting realpath
2016-01-06 11:52:37 -08:00
Chris Pickett e1e7dfa625 Fixed warning building in VS2012
src\reflection.cpp(297): warning C4267: 'argument' : conversion from 'size_t' to 'flatbuffers::uoffset_t', possible loss of data

sizeof() was promoting the type from uoffset_t to size_t.
2016-01-06 12:45:24 -06:00
Chris Pickett a3363def52 Updated comment on endif for new name 2016-01-06 12:21:17 -06:00
Chris Pickett b4fef31d84 Made requested revisions for naming and spacing 2016-01-06 12:20:38 -06:00
Chris Pickett cfd6e7dea8 Documented what the suppressed warning is about 2016-01-06 12:04:46 -06:00
Wouter van Oortmerssen 56f9b2d142 Merge pull request #3492 from parnic/fix-vs2012-warnings
Fix vs2012 warnings
2016-01-06 09:39:23 -08:00
ncpenke 01025fa22b Merge pull request #3 from google/master
Catchup
2016-01-06 10:18:04 -06:00
Chris Pickett 30013b4ff8 Fixed MS static analysis warnings
Cleaned up a few warnings to allow VS2012 to compile idl_parser and idl_gen_text (for exporting binary protobuf blobs as JSON) cleanly under static analysis.
2016-01-05 13:38:59 -06:00
Chris Pickett 4731c7e502 Fix build for platforms not supporting realpath
Added a check for a preprocessor definition that can be set if the platform you're building for doesn't support any notion of absolute path resolution/realpath()/etc.
2016-01-05 11:04:16 -06:00
Chris Pickett e0b2f81885 Fixed compile warning with VS2012
flatbuffers\src\idl_parser.cpp(1516): warning C4244: 'argument' : conversion from 'int' to 'char', possible loss of data
2016-01-05 10:58:40 -06:00
Chris Pickett 0e1601b80d Fixed compile warning with VS2012
flatbuffers\src\idl_parser.cpp(1525): warning C4127: conditional expression is constant
flatbuffers\src\idl_parser.cpp(1546): warning C4127: conditional expression is constant
2016-01-05 10:58:21 -06:00
Wouter van Oortmerssen a6a38f6035 Merge branch 'master' of https://github.com/google/flatbuffers
Fixed conflicts and added missing generated files.

Change-Id: I4321c798543292d814c2c9e8b238c203b7526c7b
2016-01-04 13:06:19 -08:00
Wouter van Oortmerssen 4e4a5142fb Clarified binary encoding with an example.
Change-Id: I60c900a2f7cbd88fe264f7b0dc78ef86b1580655
Tested: in Chrome.
2016-01-04 09:53:21 -08:00
ncpenke 17c0b677e0 Merge pull request #2 from google/master
Catchup
2016-01-02 06:59:41 +00:00
Faizan Rashid af23683311 [BUG FIX] [MINOR] Fix encoding with unicode characters.
When passing a unicode string to builder.CreateString, the
default encoding assumed all characters can be encoded
using ascii. Added a fix so a user can specify the
encoding and how to handle errors when creating strings.
2015-12-31 09:45:09 +05:00
Wouter van Oortmerssen 451272b618 Made error checking macros less prone to clashes.
Change-Id: Ieb252ce01446551699d935507bc95ee286fe1ddd
Tested: on Linux.
2015-12-29 16:33:00 -08:00
Wouter van Oortmerssen 8f13c828f5 Merge pull request #2776 from ncpenke/skip-unknown-json-fields
Fix #2775: Add parser option to skip unknown JSON fields
2015-12-29 10:29:11 -08:00
Wouter van Oortmerssen e6240f4039 Merge pull request #2790 from chobie/php-table-fix
(PHP) fixes getting indirect table, also fixes getInt method on 32bit machine
2015-12-29 10:25:21 -08:00
Shuhei Tanuma 4691558ee3 (PHP) remove duplicate test 2015-12-24 15:50:03 +09:00
Shuhei Tanuma 7fbd9b8de4 (PHP) improve indirect buffer test 2015-12-24 15:35:28 +09:00
Nalinichandra Penke f243109524 Fix #2775: Add option to flatc to skip unknown fields in JSON 2015-12-22 00:13:22 -08:00
Nalinichandra Penke 13d0594b4c Fix #2775: Add parser option to skip unknown JSON fields 2015-12-22 00:02:19 -08:00
ncpenke 6bfcb286b1 Merge pull request #1 from google/master
Catchup
2015-12-21 22:56:49 -08:00
Wouter van Oortmerssen 1891537236 Fixed reflection setting string not changing size field.
Change-Id: I3c3e88a79667d1733b6c47e43b55d8b2604ca8e2
Tested: on Linux.
2015-12-21 16:20:03 -08:00
Wouter van Oortmerssen d7d527d154 Merge branch 'master' of https://github.com/google/flatbuffers 2015-12-21 14:43:48 -08:00