Commit Graph

7013 Commits

Author SHA1 Message Date
Sydney Acksman
6da14fa94d Add GeneratedMessageTest.Proto2.cs to EXTRA_DIST 2019-08-23 17:29:59 -05:00
Sydney Acksman
0436b8db85 GetOrRegisterExtension -> GetOrInitializeExtension
Add comment explaining IExtensionMessage instability
2019-08-23 17:29:59 -05:00
Sydney Acksman
c5fa0e08c7 Fix comment on IExtendableMessage.GetOrRegisterExtension 2019-08-23 17:29:59 -05:00
Sydney Acksman
79cf8a8bae Fix readability in FieldCodec.ForMessage/Group factories 2019-08-23 17:29:59 -05:00
Sydney Acksman
3237ad39f8 Rename ExtensionRegistry.Add(IEnumerable<Extension>) overload to AddRange 2019-08-23 17:29:58 -05:00
Sydney Acksman
930db675ca Revert changes for FieldPresenceAccessor 2019-08-23 17:29:58 -05:00
Sydney Acksman
29141f482c Fix default extension values being unused in FieldCodec 2019-08-23 17:29:58 -05:00
Sydney Acksman
47f2017cf3 Review changes
* Add Syntax enum and make file syntax checks check the enum
 * Made IsPacked a normal get method without ternary op
 * Moved IFieldAccessor.HasValue to IFieldPresenceAccessor
 * Change naming of GetIsExtensionsInitialized
 * Fixed stray text in summary text
2019-08-23 17:29:58 -05:00
Sydney Acksman
29d5186867 Regenerate testprotos.pb 2019-08-23 17:29:58 -05:00
Sydney Acksman
2b9d0fdfba Add missing files to Makefile.am 2019-08-23 17:16:37 -05:00
Sydney Acksman
6b90ac13e0 Reorganize some tests 2019-08-23 17:16:37 -05:00
Sydney Acksman
bf4f6c5431 Make extension reflection helper use GetOrRegisterExtension 2019-08-23 17:16:37 -05:00
Sydney Acksman
9163a6f1ad Add tests for extension accessor 2019-08-23 17:16:37 -05:00
Sydney Acksman
0c80570a8b Add ExtensionSet tests and add checks that non-message extension fields don't fail initialization checks 2019-08-23 17:16:37 -05:00
Sydney Acksman
f4cfd2def3 Remove dead HasValue code for ExtensionValue and add null-checks to ExtensionSet.Set 2019-08-23 17:16:37 -05:00
Sydney Acksman
8dc69ede45 Remove unnecessary check in GetIsExtensionsInitialized 2019-08-23 17:16:37 -05:00
Sydney Acksman
b78330b21d Fix RepeatedExtensionValue.IsInitialized 2019-08-23 17:16:37 -05:00
Sydney Acksman
ebf0bfaed8 Add private "_Extensions" property to speed up IsInitialized checks 2019-08-23 17:16:37 -05:00
Sydney Acksman
134242bc46 Change input message to UnknownFieldSet tests to proto2 test message to test groups. 2019-08-23 17:16:37 -05:00
Sydney Acksman
cd65535423 Added group roundtrip tests and fixed any issues discovered 2019-08-23 17:16:37 -05:00
Sydney Acksman
011427c9d8 Fix issues from interactive rebase and regenerate code 2019-08-23 17:16:37 -05:00
Sydney Acksman
5b2f2c5292 file descriptors and the syntax field are really weird with proto2 2019-08-23 17:16:37 -05:00
Sydney Acksman
8e917d1688 Added FieldDescriptor.IsExtension and sealed ExtensionCollection 2019-08-23 17:16:37 -05:00
Sydney Acksman
8b7fb7d0f4 Add tests for field presence and default values
Adjust APIs for extensions to properly return default values for extensions
Fix issues with IsInitialized and proto2 field reflection
2019-08-23 17:16:36 -05:00
Sydney Acksman
a976158b1c Fix incorrect code gen for string fields with default values 2019-08-23 17:16:36 -05:00
Sydney Acksman
8a57ec847b Add test protos to test project
Fix generated group code missing end group tag case
Fix generated field classes searching for presence index for extensions
2019-08-23 17:16:36 -05:00
Sydney Acksman
6e7c43fc68 Add checks to make sure values retrieved from CustomOptions match extension values 2019-08-23 17:16:36 -05:00
Sydney Acksman
43619bb6b2 Uncomment option code in OneofDescriptor 2019-08-23 17:16:36 -05:00
ObsidianMinor
03872044b1 Make extension container classes public and modify conformance to test proto2 messages 2019-08-23 17:16:36 -05:00
Sydney Acksman
05712c6791 Reapply custom option accessors from previous PR along with CustomOptions accessor deprecations 2019-08-23 17:16:36 -05:00
Sydney Acksman
4be0394686 Remove proto2 check from generator 2019-08-23 17:16:36 -05:00
Sydney Acksman
5caa44e056 Remove internal constraint on descriptor proto 2019-08-23 17:16:36 -05:00
Rafi Kamal
1be79eefd5
Merge pull request #6557 from elharo/patch-3
Update versions to 3.9.1
2019-08-23 15:12:38 -07:00
Joshua Haberman
06d26df704
Merge pull request #6559 from haberman/notypedef
Removed ByteCountInt64.  This is a transitional typedef that should n…
2019-08-23 12:25:44 -07:00
Paul Yang
6c9d7ecfa4
Test singular fields are encoded in canonical way (#6553)
* Test singular fields are encoded in canonical way

* Defautl values in proto3 should not be encoded.
* Values should be converted to the canonical representation (e.g.,
long int64 value may be truncated for int32 field)

* Update failure list

* Update failure list
2019-08-23 12:20:19 -07:00
Joshua Haberman
6b2fc3c2c9 Removed ByteCountInt64. This is a transitional typedef that should not be released. 2019-08-23 11:10:02 -07:00
Mohamed Heikal
f8a2deafd5 Add ovrride keyword for overriden functions 2019-08-23 09:52:29 -07:00
Mohamed Heikal
db5b2bd13a clang-cl requires fully qualified name for friend class declarations 2019-08-23 09:48:52 -07:00
Mohamed Heikal
402b5772d5 Fix order of export and capability macros on WrappedMutex
clang-cl requires the order to be the opposite of what it currently is.
It should not affect other compilers since this is the only compiler
that has both macros defined.
2019-08-23 09:47:41 -07:00
Rafi Kamal
2228af689f
Merge pull request #6556 from rafi-kamal/201908221610
Down integrate internal changes to GitHub
2019-08-22 22:04:52 -07:00
Rafi Kamal
2cc432fcfd
Merge pull request #6542 from elharo/patch-2
Update to Truth 1.0
2019-08-22 17:57:16 -07:00
Elliotte Rusty Harold
2048a6f442
Update versions to 3.9.1 2019-08-22 20:36:31 -04:00
Rafi Kamal
4f02f056b5 Down integrate to GitHub 2019-08-22 17:33:01 -07:00
Paul Yang
893a7d31e1
No need to have a separate ruby conformance test on Mac (#6555)
The previous issue of mktime doesn't work on Mac has been fixed.
2019-08-22 16:17:37 -07:00
Joshua Haberman
780b050975 Fix for GC of Ruby map frames. (#6533)
We were creating a map decoding frame when starting the *map*,
but clearing the GC slot when finishing each *map entry*.  This
means that the decoding frame could be collected in the meantime.
2019-08-22 14:36:27 -07:00
Julio Monteiro
8c3a2ce198 Add source code URI to the Ruby gemspec file (#6466)
* Add source code URI to the Ruby gemspec file

As a developer, I would like to easily find the source code origin for this gem when browsing through https://rubygems.org/gems/google-protobuf.
In order to solve this, I've followed instructions at https://guides.rubygems.org/specification-reference/#metadata by adding the source_code_uri metadata key pair.

* Use git tag instead of fixed "master" string

* Substitute the string, not the Gem::Version
2019-08-22 14:32:06 -07:00
Paul Yang
d79d368ff1
Remove stale comment (#6552)
Proto2 has been tested for invalid cases. Check implementation of
ExpectParseFailureForProto (https://github.com/protocolbuffers/protobuf/blob/master/conformance/binary_json_conformance_suite.cc#L322)
2019-08-22 13:25:19 -07:00
Joshua Haberman
3e3407af49 Re-add memset() that seemed redundant but is necessary in case of GC. 2019-08-21 18:39:25 -07:00
Joshua Haberman
b9131f0aab Removed commented-out code. 2019-08-21 18:05:20 -07:00
Joshua Haberman
cf07d3c1b2 layout_init() optimization works! 2019-08-21 17:58:37 -07:00