Commit Graph

3338 Commits

Author SHA1 Message Date
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
Jon Skeet
0a902ee0ac Fix to csharp_options - initialize internal_access to false. 2016-04-08 09:57:32 +01: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
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
Thomas Van Lenten
28c5c25397 Merge pull request #1391 from thomasvl/string_tweaks
ObjC String followups: one test case only addition, behavior change for invalid UTF-8
2016-04-06 15:52:17 -04:00
Geoffrey Wiseman
f98d2f5147 Updating Xcode Settings to use iOS 9.3
Update the simulators used for some tests under Xcode 7.3 to be iOS 9.3.
2016-04-06 15:29:52 -04:00
Jon Skeet
2a18bb5a33 Add more documentation for csharp_options.h
This also renames generate_directories to base_namespace_specified; generating directories is the
immediate *effect* of specifying a base namespace, but with this change the options reflect what has been
specified rather than the effect. (There may be other effects in the future, of course.)
2016-04-06 10:30:19 +01:00
Jon Skeet
bfd1c84a3d Line-wrapping changes only for C# generator code
This should have no behavioral changes at all.

This doesn't strictly enforce an 80-column limit, but removes the most egregious violations.
The indentation in the C# generator code is inconsistent in general, unfortunately - if we have
any good tools that can be trusted to reformat, I'd be happy to apply them.
2016-04-06 10:17:13 +01:00
Thomas Van Lenten
c9167f2acd Error during parsing for invalid UTF-8 instead of dropping dropping data.
This seems to be some code evolution side effects. Back when there was a custom
string class, we couldn't really error when we finally saw the string was bad
so we had to return the empty string, but now that full validation is done
up front, it can error out.
2016-04-05 17:16:33 -04:00
Thomas Van Lenten
f3f5b3fb64 Add tests to ensure we read strings with BOMs so we don't forget about lessons of the past. 2016-04-05 17:16:33 -04:00
Jon Skeet
89719f07a3 Merge pull request #1349 from gvaish/master
Added CLI option internal_access for types (C#)
2016-04-05 20:52:17 +01:00
Feng Xiao
f3fe75bae5 Merge pull request #1386 from andrewharp/patch-2
Do not link in pthread library for Android builds.
2016-04-05 10:40:28 -07:00
Gaurav Vaish
74d8b0bebc Added access_level for types
* `csharp_options`: Added `Options` to encapsulate generator options.
   Supported options for now - file_extension, base_namespace
* `{Blah}Generator`: Now accept `Options*` as parameter to constructor
* `csharp_generator.cc`: Parse and populate options
* `Makefile.am`: Added `csharp_options.h`
* `extract_includes.bat.in`: Added `csharp_options.h`

Refactoring code to two commits. This is the first commit
2016-04-05 09:47:11 -07:00
Andrew Harp
3b4e7dcf29 Update BUILD 2016-04-04 16:13:31 -04:00
Andrew Harp
b56b461e49 Do not link in pthread library for Android builds.
This is required to allow Tensorflow to build on Android without hacks. Currently we create a dummy pthread library just to satisfy this dependency for a library that does not exist on Android. See https://github.com/google/protobuf/issues/1373 for more context.
2016-04-04 15:13:30 -04:00
Thomas Van Lenten
a771c9e11c Merge pull request #852 from qzix/master
Added deprecated option handling to objective-c
2016-04-04 11:38:22 -04:00
Oleg Vereshko
268ce2818f Added deprecated option handling for objective-c generator 2016-04-04 18:13:30 +03:00
Joshua Haberman
452e2b2c5c Merge pull request #1353 from keveman/master
Linking the cpp implementation extension statically with libprotobuf
2016-04-01 16:14:52 -07:00
Manjunath Kudlur
cf828deb9b Linking the cpp implementation extension statically with libprotobuf 2016-04-01 15:58:48 -07:00
Jon Skeet
9d7a1727e5 Merge pull request #1377 from jskeet/remove-duplicate-tests
Remove duplicate test cases.
2016-04-01 21:28:56 +01:00
Thomas Van Lenten
a293180541 Merge pull request #1378 from thomasvl/manual_stream_parsing_helpers
Add -position and -isAtEnd for use when manually parsing input streams.
2016-04-01 12:37:05 -04:00
Thomas Van Lenten
331cee5022 Add -position and -isAtEnd for use when manually parsing input streams. 2016-04-01 12:26:15 -04:00
Jon Skeet
46e088e2b6 Remove duplicate test cases.
(NCrunch noticed these.)
2016-04-01 17:18:45 +01:00
Jan Tattermusch
099ff1ea14 Merge pull request #1369 from jskeet/tools-nuspec
Introduce a new nuget package, Google.Protobuf.Tools, basically to contain protoc on multiple platforms.
2016-03-31 17:44:40 -07:00
Joshua Haberman
81eb84c029 Merge pull request #1371 from keveman/oversize_protos
Added an API to allow oversize protos when using C++ extension in Python
2016-03-31 14:31:05 -07:00
Manjunath Kudlur
1283625b0f Added an API to allow oversize protos when using C++ extension in Python 2016-03-31 14:14:58 -07:00
Feng Xiao
5c63266ed3 Merge pull request #1366 from xyzzyz/int128_ostream
Replace #include <iostream> with #include <ostream> in int128.cc
2016-03-31 13:29:29 -07:00
Jon Skeet
dfd47600d1 Remove duplicate line 2016-03-31 10:46:55 +01:00
Jon Skeet
ca0461c186 Introduce a new nuget package, Google.Protobuf.Tools, basically to contain protoc on multiple platforms.
I've moved both protoc.exe and the proto files out of Google.Protobuf.
The .proto files aren't a slam-dunk, but it feels like they belong with protoc as you'd *use* them with protoc.
It's not clear to me whether we really need both an x86 and x64 version of protoc.exe, as x86 would work on 64-bit Windows anyway. Discuss :)
2016-03-31 07:12:17 +01:00
Jan Tattermusch
a16c8a50f0 Merge pull request #1362 from jskeet/tweak_json_name
Refactoring of FieldDescriptor
2016-03-30 20:30:51 -07:00
Adam Michalik
955841e620 Replace #include <iostream> with #include <ostream>
iostream is not actually necessary here, and it introduces unnecessary
static initializers.
2016-03-30 12:54:40 -07:00
Jisi Liu
a25e9964b1 Merge pull request #1360 from pherl/master
Use the T() instead of NULL for the default value.
2016-03-30 11:28:54 -07:00
Joshua Haberman
34d0cc220b Merge pull request #1295 from haberman/docker
Add support for running on Jenkins
2016-03-30 10:51:26 -07:00
Jon Skeet
71e8dca083 Refactoring of FieldDescriptor
This makes no externally visible behavioral changes. Internally and non-behaviorally:

- We use a field (compiler-generated) to store the JsonName to avoid recomputing it repeatedly
- The documentation for JsonName is updated to reflect the meaning better
- Readonly autoprops and expression-bodied properties used where possible
2016-03-30 09:42:37 +01:00
Jon Skeet
261fde1707 Merge pull request #1326 from the-alien/csharp_json_name
csharp: add support for the json_name option
2016-03-30 09:11:59 +01:00
Josh Haberman
a15b916c41 Merge branch 'master' into docker 2016-03-29 16:24:35 -07:00
Jisi Liu
e164f1083f Use the T() instead of NULL for the default value.
The template can be specialized on primitives, e.g. double, where
converting NULL will trigger a warning.
2016-03-29 15:25:49 -07:00
alien
af34538aca Merge branch 'master' of https://github.com/google/protobuf into csharp_json_name 2016-03-29 20:58:23 +03:00
alien
6f8dd2115b Code review fixes 2016-03-29 20:56:32 +03:00
Thomas Van Lenten
261ee021f6 Merge pull request #1358 from thomasvl/travis_tweaks
Mark iOS tests as able to fail.
2016-03-29 11:55:04 -04:00
Thomas Van Lenten
8d47d7873e Mark iOS tests as able to fail.
Travis updated their images to include an xctool that can randomly kill
tests, so mark them as flaky to avoid turning things red.
2016-03-29 09:21:50 -04:00
Thomas Van Lenten
9240acd179 Merge pull request #1350 from thomasvl/over_release
The message was autoreleased, the -releases are an over release.
2016-03-24 15:28:53 -04:00
Thomas Van Lenten
3f917447e7 The message was autoreleased, the -releases are an over release. 2016-03-24 15:25:21 -04:00
Feng Xiao
812691227d Merge pull request #1345 from smparkes/smparkes/well-known-protos
export well known protos
2016-03-23 11:36:00 -07:00
Steven Parkes
d5a573274d export well known protos 2016-03-22 17:56:07 -07:00
Feng Xiao
34eeeff640 Merge pull request #1344 from topillar/patch-1
Update coded_stream.h
2016-03-22 10:19:42 -07:00