Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Implement json decoding for Any message.
type url may not appear as the first value in json. As a result,
other data cannot be resolved before resolving type url. To solve that,
this change caches the start and end position of unparsed values and
resolve them in end_any_object when type url has been resolved.
* Handle Any in switch
* Update json parser size
* Fix comments
* Sync upstream
* Add dependency on upb_pb for upb_json
* Debug failed test
* Fix cmake
* Update test generated files
* Remove debug tests
|
|
|
|
* Fix json ignore unknown
Previously, there were several problems with ignoring unknown in json.
1) After finding a field is unknown, the parser's state is not changed. Thus, there is no way to distinguish whether the parser is dealing with an unknown field or it's just a top level message.
2) Several method didn't respect unknown field, e.g., start_object, end_bool, start_array.
* Update json parser size
* Update json parser size
|
|
* Fix mac use local timezone for strptime by default.
* Fix comments
* Check len == UPB_TIMESTAMP_BASE_SIZE
* Fix comment
|
|
* Fix json encoding for wrappers, ListValue, Struct and Value.
* Add well_known_type field in upb_msgdef to specify type of well known messages.
* Remove comma at end of enum definition.
* Group number wrappers
* Fix comments
* Refactoring to use is_wellknown_{msg/field}
|
|
|
|
After this CL, upb passes all existing proto3 conformance tests.
However the conformance suite is missing a lot of cases and should
be fleshed out.
|
|
|
|
|
|
Changed C API to only define structs, a table, and a few minimal inline function.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
functions.
|
|
* Fix json encoding/decoding for duration.
* Use lld for int64_t
* Cast int64_t to long
|
|
The reason for typecasting size_t to unint32_t is that size_t is 8 bytes and uint32_t is only 4 bytes.
If not typecasted Memcpy fails to copy the *correct* four bytes in big endian platforms.
|
|
* Fix json parsing for timestamp
* Fix json encoding for timestamp
* Implement timestamp_machine to parse timestamp
* Remove comparision for size_t and 0
* Increase defined printer size
* Increase size
* Increase parser size
* Mark json_en_timestamp_machine unused
|
|
Also got rid of the premature "v1" business that was attempting
to create a binary compatibility story.
Also added an in-progress CMakeLists.txt file.
|
|
|
|
A lot of this code was experimental or temporarily
useful, but is no longer needed.
|
|
|
|
These are still being used by the proto2 bindings.
|
|
upb_msg was trying to be general enough that it could either live in
an arena or be allocated with malloc()/free(). This was too much
complexity for too little benefit. We should commit to just saying
that upb_msg is arena-only.
I also ripped out the code to glue upb_msg to the existing
handlers-based encoder/decoder. upb_msg has its own, small, simple
encoder/decoder. I'm trying to whittle down upb_msg to a small
and simple core.
I updated the Lua extension for these changes. Lua needs some more
work to properly create arenas per message. For now I just created
a single global arena.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This reverts commit f30dd0ff0cead9bb1f8f3b1b295392d75705486b.
|
|
|
|
|
|
|
|
|
|
Fix parsing sub-message field.
|