Bill Yi
05b6a7be8a
am 9dde6a6d: am ddeaf256: Merge commit \'ba89934bdae7f4256c94a0a24992903a114e764f\' into HEAD
...
* commit '9dde6a6d6b6f8e0a96fd3634f7e033fc30bc11e5':
11 years ago
Bill Yi
12214c58ec
am ddeaf256: Merge commit \'ba89934bdae7f4256c94a0a24992903a114e764f\' into HEAD
...
* commit 'ddeaf25683a5aa4d6e7ef784c7380c9332cdb3ce':
11 years ago
Bill Yi
af802cd274
Merge commit 'ba89934bdae7f4256c94a0a24992903a114e764f' into HEAD
11 years ago
Jeff Davidson
46bf9261af
resolved conflicts for merge of 592b6078 to master
...
Change-Id: I4c9cebcc6922a970daca2af002c96bc7e8e102b8
11 years ago
Jeff Davidson
3eafa87ab8
am 33a6680a: Merge "Support generation of Parcelable nano messages."
...
* commit '33a6680ab98977cd5b9b7b03f4875b9265cfec3b':
Support generation of Parcelable nano messages.
11 years ago
Jeff Davidson
a2724e7cf3
Merge "Support generation of Parcelable nano messages."
11 years ago
Jeff Davidson
ec4b1ce0b6
Support generation of Parcelable nano messages.
...
This CL adds the "parcelable_messages" option. When enabled, all
generated message classes will conform to the Android Parcelable
contract. This is achieved by introducing a new parent class for
generated classes which implements the required functionality.
Since the store_unknown_fields option also makes use of a superclass,
ExtendableMessageNano, we have two versions of the new Parcelable
superclass: one extending MessageNano, and one extending
ExtendableMessageNano. These classes are otherwise identical.
As these classes depend on Android framework jars, they are not
included in the host .jar build of the nanoproto library.
Finally, add a test suite for running tests of Android-specific
functionality, as this cannot be done on a desktop JVM.
Change-Id: Icc2a257f03317e947f7078dbb9857c3286857497
11 years ago
Max Cai
e278b645a2
am 43365182: am 829f6c01: Merge "Adds --ignore_service nano proto compiler flag"
...
* commit '43365182bcd23a011476fb5e57930f1829da41fa':
Adds --ignore_service nano proto compiler flag
11 years ago
Max Cai
5cc8a31ea1
am 829f6c01: Merge "Adds --ignore_service nano proto compiler flag"
...
* commit '829f6c014ce69d04593d30652c8acc2f7a793851':
Adds --ignore_service nano proto compiler flag
11 years ago
Max Cai
f1019531a6
Merge "Adds --ignore_service nano proto compiler flag"
11 years ago
Jie Dai
d9425a6218
Adds --ignore_service nano proto compiler flag
...
Nano proto compiler normally throws an error if any service is
defined. If --ignore-services=true is set, no error is thrown and the
service is simply skipped.
Change-Id: Id82583555085cc55550d03a485d3f0189885240b
11 years ago
Max Cai
a4b3e9d2b8
am 0391f00b: am ea68d73c: Merge "Don\'t reset cachedSize to 0 in getSerializedSize"
...
* commit '0391f00be135d1a52052d50171c38e9f0129031d':
Don't reset cachedSize to 0 in getSerializedSize
11 years ago
Max Cai
09f640ef43
am ea68d73c: Merge "Don\'t reset cachedSize to 0 in getSerializedSize"
...
* commit 'ea68d73c08b3b9319faef8ef9cd283e773a6ef20':
Don't reset cachedSize to 0 in getSerializedSize
11 years ago
Max Cai
56cba8eeae
Merge "Don't reset cachedSize to 0 in getSerializedSize"
11 years ago
Dave Hawkey
598087ef53
Don't reset cachedSize to 0 in getSerializedSize
...
This avoids a race-condition when cachedSize is momentarily set to 0
for non-empty messages if multiple threads call getSerializedSize
(e.g. during serialization).
This is a retry of https://android-review.googlesource.com/#/c/88570/ .
getSerializedSize() has been kept non-final so that messages generated
with a previous version of the compiler will not break.
Change-Id: I8d8154a10938cde579ae19c55eae55b1e70e0bda
11 years ago
Wink Saville
68f721bfb3
am 8a9fc09c: am ce2f5991: Merge "Revert "Don\'t reset cachedSize to 0 in getSerializedSize""
...
* commit '8a9fc09c92cf0b1f08186c9339952e47eddee74b':
Revert "Don't reset cachedSize to 0 in getSerializedSize"
11 years ago
Wink Saville
6ba01e2439
am ce2f5991: Merge "Revert "Don\'t reset cachedSize to 0 in getSerializedSize""
...
* commit 'ce2f59915e0b41c935e3f72a2b7b71b6c19b6860':
Revert "Don't reset cachedSize to 0 in getSerializedSize"
11 years ago
Wink Saville
1e92850c47
am ce2f5991: Merge "Revert "Don\'t reset cachedSize to 0 in getSerializedSize""
...
* commit 'ce2f59915e0b41c935e3f72a2b7b71b6c19b6860':
Revert "Don't reset cachedSize to 0 in getSerializedSize"
11 years ago
Wink Saville
dc2ab87569
Merge "Revert "Don't reset cachedSize to 0 in getSerializedSize""
11 years ago
Wink Saville
b7dd7d9294
Revert "Don't reset cachedSize to 0 in getSerializedSize"
...
This reverts commit c6e12c6702ca764486f952654ba1568f00efe813.
11 years ago
Wink Saville
546ed9afaa
Revert "am 5b931dc7: am ec0b12c3: Merge "Don\'t reset cachedSize to 0 in getSerializedSize""
...
This reverts commit f213b0c6a86503ad752139f04f343578df45db07, reversing
changes made to 1a4b1d52e44104f2e10d0cdc585dde88602843d2.
11 years ago
Wink Saville
cf7ff1aa6c
am 5b931dc7: am ec0b12c3: Merge "Don\'t reset cachedSize to 0 in getSerializedSize"
...
* commit '5b931dc798d882754f3e7a876fc6d820fa371e95':
Don't reset cachedSize to 0 in getSerializedSize
11 years ago
Wink Saville
d76d44f529
am ec0b12c3: Merge "Don\'t reset cachedSize to 0 in getSerializedSize"
...
* commit 'ec0b12c34a6329d2f98003e9102fe2d75726c797':
Don't reset cachedSize to 0 in getSerializedSize
11 years ago
Wink Saville
9d89464330
am ec0b12c3: Merge "Don\'t reset cachedSize to 0 in getSerializedSize"
...
* commit 'ec0b12c34a6329d2f98003e9102fe2d75726c797':
Don't reset cachedSize to 0 in getSerializedSize
11 years ago
Wink Saville
ddc98d6dd0
Merge "Don't reset cachedSize to 0 in getSerializedSize"
11 years ago
Dave Hawkey
5090f19ea7
Don't reset cachedSize to 0 in getSerializedSize
...
This avoids a race-condition when cachedSize is momentarily set to 0
for non-empty messages if multiple threads call getSerializedSize
(e.g. during serialization).
Change-Id: I15a8ded92edbf41bf1c8d787960c5bbbc8a323c5
11 years ago
Wink Saville
66ec7d4151
am 51ef8f39: Merge "Fix compile error on mac 10.9"
...
* commit '51ef8f39de376fe71ce5d2c682abe4f974cf8074':
Fix compile error on mac 10.9
11 years ago
Max Cai
e73c4a02a9
am afc1553a: Merge "Extension overhaul."
...
* commit 'afc1553a9eb56eff742828c9c819eafa363cdcc9':
Extension overhaul.
11 years ago
Max Cai
b97d258c9f
am 447f664a: Merge changes I9fecff3c,I2c1eb07f
...
* commit '447f664aef6694bb9fb3db85d6166d908cde8a8d':
Fix repeated packed field merging code for non-packed data.
Add validation when parsing enum fields.
11 years ago
Wink Saville
b99eb7f559
am 00310299: am 51ef8f39: Merge "Fix compile error on mac 10.9"
...
* commit '0031029939c440e42e8e43cea3401f135c1af7d6':
Fix compile error on mac 10.9
11 years ago
Wink Saville
a9c3868123
am 51ef8f39: Merge "Fix compile error on mac 10.9"
...
* commit '51ef8f39de376fe71ce5d2c682abe4f974cf8074':
Fix compile error on mac 10.9
11 years ago
Max Cai
841521c666
am 214997ce: am afc1553a: Merge "Extension overhaul."
...
* commit '214997cefa5554c3670ea76293bbf751111704e4':
Extension overhaul.
11 years ago
Max Cai
0ad269ef2f
am afc1553a: Merge "Extension overhaul."
...
* commit 'afc1553a9eb56eff742828c9c819eafa363cdcc9':
Extension overhaul.
11 years ago
Max Cai
3a2109246f
Merge "Extension overhaul."
11 years ago
Max Cai
cddcfeaa11
am 5d33d23d: am 447f664a: Merge changes I9fecff3c,I2c1eb07f
...
* commit '5d33d23ded77a145f59a915f19044aa14335d93b':
Fix repeated packed field merging code for non-packed data.
Add validation when parsing enum fields.
11 years ago
Max Cai
6d7dfd31c2
am 447f664a: Merge changes I9fecff3c,I2c1eb07f
...
* commit '447f664aef6694bb9fb3db85d6166d908cde8a8d':
Fix repeated packed field merging code for non-packed data.
Add validation when parsing enum fields.
11 years ago
Max Cai
a2d72a5853
Merge changes I9fecff3c,I2c1eb07f
...
* changes:
Fix repeated packed field merging code for non-packed data.
Add validation when parsing enum fields.
11 years ago
Max Cai
74959d4796
Fix repeated packed field merging code for non-packed data.
...
Enum fix is already included in the previous commit.
Bug: https://code.google.com/p/android/issues/detail?id=64893
Change-Id: I9fecff3c8822918a019028eb57fa39b361a2c960
11 years ago
Max Cai
e005be6554
Add validation when parsing enum fields.
...
Invalid values from the wire are silently ignored.
Unlike full/lite, the invalid values are not stored into the
unknown fields, because there's no way to get them out from
Nano's unknown fields without a matching Extension.
Edited README and slightly moved it towards a standalone
section for Nano, independent of the Micro section.
Change-Id: I2c1eb07f4d6d8f3aea242b8ddd95b9c966f3f177
11 years ago
Max Cai
7a83099859
am d5219df3: am a8af729b: Merge "Allow whitespace in nano codegen options."
...
* commit 'd5219df3ce036d4f43262bbda1016097a59a0c81':
Allow whitespace in nano codegen options.
11 years ago
Max Cai
14ae5639b3
am a8af729b: Merge "Allow whitespace in nano codegen options."
...
* commit 'a8af729b5ef822971f025a7e8ff197545986910d':
Allow whitespace in nano codegen options.
11 years ago
Max Cai
a793c09b6f
Merge "Allow whitespace in nano codegen options."
11 years ago
Max Cai
bc8eec3d2b
Allow whitespace in nano codegen options.
...
So we don't need to keep all option in a single line in the .mk files.
Change-Id: I786b879b334cac4cd13b32fabcb76efe53b4ac80
11 years ago
Max Cai
7057fa59c5
am 1be96c57: am 4b5874fa: Merge "Correctness: floating point equality using bits instead of ==."
...
* commit '1be96c579a34924bd20f19a0911b101ade08b0f3':
Correctness: floating point equality using bits instead of ==.
11 years ago
Max Cai
4d58373e06
am 538abc5b: am d6aeae14: Merge "Don\'t serialize required fields whose \'has\' flags are unset."
...
* commit '538abc5b6514460fce1e72da9f49591c6d4ba2e0':
Don't serialize required fields whose 'has' flags are unset.
11 years ago
Max Cai
d44a519d8f
am 4b5874fa: Merge "Correctness: floating point equality using bits instead of ==."
...
* commit '4b5874fad099faefb469c632e4c7b854cea733ae':
Correctness: floating point equality using bits instead of ==.
11 years ago
Max Cai
eeda36e47c
am d6aeae14: Merge "Don\'t serialize required fields whose \'has\' flags are unset."
...
* commit 'd6aeae143cde31b79a2d57a3ee0e41d9083d232d':
Don't serialize required fields whose 'has' flags are unset.
11 years ago
Max Cai
0eecf0b83f
Merge "Correctness: floating point equality using bits instead of ==."
11 years ago
Max Cai
2fb3cdf9bb
Merge "Don't serialize required fields whose 'has' flags are unset."
11 years ago
Max Cai
79b311c163
Correctness: floating point equality using bits instead of ==.
...
Special values for float and double make it inaccurate to test the equality with ==.
The main Java library uses the standard Object.equals() implementation for all fields,
which for floating point fields means Float.equals() or Double.equals(). They define
equality as bitwise equality, with all NaN representations normalized to the same bit
sequence (and therefore equal to each other). This test checks that the nano
implementation complies with Object.equals(), so NaN == NaN and +0.0 != -0.0.
Change-Id: I97bb4a3687223d8a212c70cd736436b9dd80c1d7
11 years ago