Commit Graph

3548 Commits

Author SHA1 Message Date
Josh Haberman
d419ca10b4 Updated upb and simplified ruby code a bit with new upb method. 2016-04-22 14:12:10 -07:00
Feng Xiao
4057447997 Merge pull request #1444 from mbrtargeting/master
Added serialVersionUID to ExtendableMessage.
2016-04-22 11:45:31 -07:00
Tony Allevato
385755e13b Add initial design document for Swift protocol buffers. (#1442)
* Add initial design doc for Swift protocol buffers.
2016-04-22 12:15:14 -04:00
Jakub Kukul
db93833bc6 Added serialVersionUID to ExtendableMessage. 2016-04-22 16:04:27 +02:00
Feng Xiao
034294bfb0 Merge pull request #1438 from xfxyjwf/docs
Add a docs directory and move the third-party add-ons page here.
2016-04-21 11:45:58 -07:00
Petr Prokhorenkov
f4f9aec52f Fix bug with silent message corruption in LITE_RUNTIME.
A protobuf message will be corrupted in the following scenario:
  1. Use LITE_RUNTIME.
  2. Have an optional enum field following some other field.
  3. Update protocol by adding new values to the enum.
  4. Have an old client parse and serialize a message having enum field
      set to a value the client does not understand.
  5. Field preceeding the enum is now corrupted.

The bug is due to the fact that optimized fallthrough in parser code
does not update variablle 'tag' when jumping to the parser code for the
next field.
2016-04-21 09:27:33 +03:00
Feng Xiao
0ad204845f Merge pull request #1416 from cwhipkey/master
Change protobuf CPP proto generator to support the 'lite' option in
2016-04-20 17:15:16 -07:00
Feng Xiao
8052dc75a9 Add a docs directory and move the third-party add-ons page here. 2016-04-20 15:49:45 -07:00
Feng Xiao
f00300d7f0 Merge pull request #1414 from xyzzyz/googletest
Remove googletest.h header from stringprintf.cc
2016-04-20 11:20:34 -07:00
Thomas Van Lenten
1ccb4ca8ba Merge pull request #1434 from jskeet/regenerate
Regenerate descriptor/well-known types for C#
2016-04-20 14:15:51 -04:00
Jon Skeet
c588ac42a2 Regenerate well-known types for C#
(There are documentation changes and new fields in descriptor.proto that have resulted
in changes to the serialized descriptor, but no breaking changes for C#.)
2016-04-20 17:19:42 +01:00
Thomas Van Lenten
e539e9820e Merge pull request #1433 from thomasvl/check_wkt
ObjC support for failing the build in the generated WKTs are out of date
2016-04-20 11:58:18 -04:00
Thomas Van Lenten
511f28b73a ObjC support for failing the build in the generated WKTs are out of date
- Always generated into a temp directory so we can see if things changed.
- Add a flag to control exiting with error when stale vs updating.

This should let the continuous builds error out when ObjC needs to have the
checked in sources updated.
2016-04-20 10:14:18 -04:00
Jon Skeet
f265fb8152 Merge pull request #1401 from jskeet/enum-casing
Enum casing in C#
2016-04-20 09:01:58 +01:00
Joshua Haberman
36978c3938 Merge pull request #1417 from seishun/windows2
Support Windows in gulpfile.js
2016-04-19 23:42:06 -07:00
Jon Skeet
d90d615f71 Attempt to fix AppVeyor build by exporting GetEnumValueName 2016-04-20 03:46:03 +01:00
Jon Skeet
790f4c8e37 Use the original name in JSON formatting.
(JSON parsing already does the right thing.)
2016-04-20 03:46:02 +01:00
Jon Skeet
84ea2c7a81 Regenerate all C# code and make it compile
JSON tests fail, as we're not using OriginalNameAttribute yet.
2016-04-20 03:46:00 +01:00
Jon Skeet
75626ed79c Add C# codegen changes to enum value names (mostly C++)
Overview of changes:
- A new C#-specific command-line option, legacy_enum_values to revert to the old behavior
- When legacy_enum_values isn't specified, we strip the enum name as a prefix, and PascalCase the value name
- A new attribute within the C# code so that we can always tell the original in-proto name

Regenerating the C# code with legacy_enum_values leads to code which still compiles and works - but
there's more still to do.
2016-04-20 03:45:59 +01:00
Jisi Liu
1dc81948f5 Merge pull request #1428 from pherl/master
Add missing includes in field mask test
2016-04-19 15:21:37 -07:00
Jisi Liu
1b0ff34b90 Add missing includes in field mask test 2016-04-19 15:14:31 -07:00
Thomas Van Lenten
52825bf91a Merge pull request #1426 from thomasvl/fix_comment_typo
Fix comments typo and update WKTs
2016-04-19 14:17:49 -04:00
Thomas Van Lenten
e664aa6d91 Regenerate the WKT to pick up current changes to the proto files. 2016-04-19 13:13:04 -04:00
Feng Xiao
83a7a5e885 Merge pull request #1402 from davidzchen/py2and3
Add missing PY2AND3 srcs_versions attributes to Python Bazel build targets
2016-04-19 10:01:29 -07:00
Thomas Van Lenten
3633bcd5e4 Fix comment typo 2016-04-19 12:40:37 -04:00
Jisi Liu
072296f186 Merge pull request #1422 from pherl/master
Update file list to include the missing extension lite file.
2016-04-18 15:34:21 -07:00
Jisi Liu
1f4f3e26bd Update file list to include the missing extension lite file. 2016-04-18 14:12:08 -07:00
Nikolai Vavilov
7ff229fa4e Support Windows in gulpfile.js 2016-04-16 00:30:59 +03:00
Joshua Haberman
ca9bbd71d5 Merge pull request #1413 from haberman/updateupb
Updated upb: JSON parser now accepts both camelCase and original case, and flag to choose on output.
2016-04-15 12:57:39 -07:00
Chad Whipkey
baf52bd79e Change protobuf CPP proto generator to support the 'lite' option in
proto3.

Added a couple unit test proto3 files, for arena_lite and lite. Cloned
the proto3_arena_unittest to test some of the basics of generated code
(and to ensure that the generated proto3 test files are used by some
test).
2016-04-15 09:23:50 -07:00
Josh Haberman
e67ef3d449 Bugfix for JSON error case. 2016-04-14 20:27:45 -07:00
Josh Haberman
800e986012 Remove no longer applicable documentation from README.md. 2016-04-14 18:42:22 -07:00
Josh Haberman
194ad621bb Ruby JSON: always accept both camelCase and original field names.
For JSON encoding we provide a new option to decide at
encode time whether to use camelCase or original proto field
names:

  json = MapMessage.encode_json(m, :preserve_proto_fieldnames => true)
2016-04-14 18:33:17 -07:00
Adam Michalik
1b912fceee Remove googletest.h header from stringprintf.cc
It doesn't seem to be necessary here, and it pulls other testing headers
during compilation of release protobuf.
2016-04-14 15:54:31 -07:00
Josh Haberman
90c7f6e55e Documented the JSON change and compatibility flags. 2016-04-14 12:48:41 -07:00
Josh Haberman
94e54b39c8 Updated upb: picked up legacy JSON flags to help Ruby users migrate.
The flags are:

  UPB_JSON_ACCEPT_LEGACY_FIELD_NAMES
  UPB_JSON_WRITE_LEGACY_FIELD_NAMES

The first just allows the parser to accept the old field names.
The second makes the printer print the old field names.

These flags are intended to be temporary, as a migration aid
for users.
2016-04-14 12:06:09 -07:00
Joshua Haberman
814685ca2c Merge pull request #1397 from google/internal-merge
Internal merge
2016-04-11 23:37:42 -07:00
Josh Haberman
3c4ce528c6 Fix for gulpfile.js. 2016-04-11 15:53:25 -07:00
Jon Skeet
2a197b3eb0 Use 0 as the default value for all enums, rather than finding the actual enum value name
This will make it easier to change the enum value names, as it reduces the number of places they're used.
2016-04-11 06:47:43 +01:00
Jan Tattermusch
3ffbdd712f Merge pull request #1400 from jskeet/fix-internal
Fix to csharp_options - initialize internal_access to false.
2016-04-10 17:33:18 -07:00
David Z. Chen
5ebeefb94c Add missing PY2AND3 srcs_versions attributes to Python Bazel build targets. 2016-04-08 13:30:13 -07:00
Jon Skeet
0a902ee0ac Fix to csharp_options - initialize internal_access to false. 2016-04-08 09:57:32 +01:00
Josh Haberman
2cd79bf3a8 Removed duplicated operator delete from merge conflict. 2016-04-07 14:26:59 -07:00
Josh Haberman
4465daa57a Merge branch 'master' into internal-merge 2016-04-07 14:10:19 -07:00
Jon Skeet
667f4a6282 Merge pull request #1393 from gvaish/master
Added support for internal_access for C#
2016-04-07 22:05:40 +01:00
Josh Haberman
15239361e3 Fix for CommonJS tests. 2016-04-07 14:04:55 -07:00
Jie Luo
09292d5759 Merge pull request #1392 from anandolee/master
Sync the manually integrate changes in google3/third_party
2016-04-07 11:05:05 -07:00
Gaurav Vaish
a6e39316a7 Added support for internal_access for C# 2016-04-07 10:33:21 -07:00
Jon Skeet
cef46e115a Merge pull request #1390 from jskeet/tidy-up
Tidy up for C# codegen
2016-04-07 08:49:27 +01:00
Jie Luo
c61207492e sync the Manually integrate changes in google3/third_party 2016-04-06 14:32:30 -07:00