Eric Salo
f6307877d3
move portability stuff into upb/port/
...
Also delete redundant system #includes that are already pulled in by port/def.inc
PiperOrigin-RevId: 486398989
2 years ago
Eric Salo
46699b72ad
move message set enums into upb/wire/ (and use them)
...
PiperOrigin-RevId: 486366363
2 years ago
Eric Salo
fd040a8bff
create collections/map_internal.h and collections/map_gencode_util.h
...
Move the map-related functions from msg_internal.h that are only used in generated code into map_gencode_util.h. Then move the rest of the map-related functions from msg_internal.h into map_internal.h.
PiperOrigin-RevId: 486299140
2 years ago
Protobuf Team Bot
a4779ef5f8
internal change
...
PiperOrigin-RevId: 486275169
2 years ago
Protobuf Team Bot
0f4fffef16
Update config_setting visibility in support of --incompatible_config_setting_private_default_visibility.
...
For https://github.com/bazelbuild/bazel/issues/12933 .
PiperOrigin-RevId: 486230747
2 years ago
Eric Salo
fd14316f38
create collections/ subdir for all array and map code
...
PiperOrigin-RevId: 486013554
2 years ago
Eric Salo
d9b6f13cde
remove upb_MtDataEncoder from the public surface
...
PiperOrigin-RevId: 485928803
2 years ago
Eric Salo
0bb466356d
create text/ subdir for all text-format code
...
Currently all we have is an encoder but eventually a decoder will also go here.
PiperOrigin-RevId: 485911424
2 years ago
Eric Salo
e137175092
create wire/ subdir for all wire-format code
...
PiperOrigin-RevId: 485898080
2 years ago
Eric Salo
f409c9985b
create mem/ subdir for all arena code
...
PiperOrigin-RevId: 485884460
2 years ago
Mike Kruskal
5ba0d84c88
Internal Change
...
PiperOrigin-RevId: 485726227
2 years ago
Eric Salo
c033eff26f
split apart mini_table.c into a new subdir
...
PiperOrigin-RevId: 484352293
2 years ago
Protobuf Team Bot
be98a91367
Add aspect hints for kotlin native compilation.
...
PiperOrigin-RevId: 480421756
2 years ago
Protobuf Team Bot
04363f7bae
Update workspace_deps.bzl protobuf main commit
...
PiperOrigin-RevId: 479635174
2 years ago
Eric Salo
44916d7d27
create reflection_internal library
...
internal declarations are now physically removed from the public headers
PiperOrigin-RevId: 478921131
2 years ago
Joshua Haberman
32c6e9baab
A few more fixes for PHP and the 32-bit build
...
PiperOrigin-RevId: 478530302
2 years ago
Eric Salo
0f585c69af
stop requiring extension fields to have a synthetic oneof
...
https://github.com/protocolbuffers/upb/issues/812
PiperOrigin-RevId: 478527073
2 years ago
Eric Salo
259183b1f0
split out the mapsorter functions into their own .c & .h
...
also refactor _upb_mapsorter_push() to use a static table instead of a switch()
PiperOrigin-RevId: 478408815
2 years ago
Joshua Haberman
82c6c48761
Fix a few minor things to unblock the Ruby sync
...
PiperOrigin-RevId: 478113032
2 years ago
Mike Kruskal
e1b11b67a0
Internal change
...
PiperOrigin-RevId: 478067337
2 years ago
Eric Salo
b8bec58e01
pull the mini descriptor encoders into their proper .c files
...
Performance neutral but it simplifies the code, shrinks the public surface,
and makes logical sense
PiperOrigin-RevId: 478038589
2 years ago
Joshua Haberman
81e716d459
Fixed to add missing table targets.
2 years ago
Eric Salo
8cc3e07735
move (most of) the json code into its own subdir
...
Continuing the trend of giving individual build targets their own subdirs
where appropriate, and leaving behind temporary stub headers for compatibility.
JSON is a particularly good choice for this because of how little interaction
it has with the rest of upb.
PiperOrigin-RevId: 476792865
2 years ago
Eric Salo
edecfd5eb0
upb: use the new reflection headers
...
Reflection headers now live in upb/reflection/ so update our include statements to
reflect this. (See what I did there?)
PiperOrigin-RevId: 474596615
2 years ago
Eric Salo
00765002ff
- All of reflection now lives in upb/reflection/
...
- Each def type has its own .c file and its own .h file
- Functions that require a builder context are declared in def_builder.h
- The mini descriptor encoders have also been pulled into upb/reflection/
- upb/def.h, upb/def.hpp, upb/reflection.h, and upb/reflection.hpp are now deprecated stubs that point to the new headers
PiperOrigin-RevId: 474459500
2 years ago
Eric Salo
4215bc82ea
fix the json parser to handle floats very near overflow
...
Instead of bounds-testing a double value to guess whether it will overflow,
just convert it to a float and check whether the result is +/- infinity.
PiperOrigin-RevId: 472811865
2 years ago
Eric Salo
85534bbb1e
remove unused #includes from reflection.h
...
The functions declared in reflection.h use neither arrays nor maps, so (a) stop including the array and map definitions, and (b) update the handful of other source files which were relying on that transitivity.
PiperOrigin-RevId: 472627278
2 years ago
Joshua Haberman
ccd88d5a63
Updated staleness test and amalgamator to work cross-repo.
2 years ago
Xavier Bonaventura
9a02d16cee
Remove patter that does not glob anything
...
This pattern does not glob anything because inside the upbc folder there is a BUILD file.
Removing this allows to build upb with the flag incompatible_disallow_empty_glob
2 years ago
Eric Salo
c67021f84a
split out the json string-to-int functions for general use
...
PiperOrigin-RevId: 469509635
2 years ago
Eric Salo
24f567b64a
clean up the public api for mini descriptors
...
push the gory details down into internal/ where they belong
PiperOrigin-RevId: 461264404
2 years ago
Mike Kruskal
17b6451684
Bumping protobuf dependency to newer commit
...
PiperOrigin-RevId: 460811319
2 years ago
Eric Salo
9b3e87307d
upb: upb_EnumDefs are now built using mini descriptors
...
Added upb_EnumDef_IsSorted() as an optimization for presorted enum protos
PiperOrigin-RevId: 460564949
2 years ago
Eric Salo
410143b265
split out some unicode logic from the json decoder
...
Also fixed a bug in the json decoder which caused it to break on a code point value of exactly 0x10ffff
PiperOrigin-RevId: 459856813
2 years ago
Protobuf Team Bot
ff46379efe
Prepare build for C++ generator.
...
PiperOrigin-RevId: 459265699
2 years ago
Protobuf Team Bot
8c44f04697
create and lock down upb/internal/array.h
...
Internal array functions are now implemented in upb/internal/array.c and declared in
upb/internal/array.h, which only has local visibility.
PiperOrigin-RevId: 458260144
2 years ago
Joshua Haberman
125db89ff5
Added fuzz tests for mini table building and binary format parsing/serialization.
...
PiperOrigin-RevId: 458240180
2 years ago
Protobuf Team Bot
ca08ff5b74
lock down upb/internal/decode.h
...
PiperOrigin-RevId: 457116753
2 years ago
Protobuf Team Bot
033859ff5d
rename internal/upb.h as internal/encode.h
...
add build target for upb/internal/encode.h and lock down its visibility
PiperOrigin-RevId: 457087638
2 years ago
Protobuf Team Bot
15596be402
move table.c into upb/internal
...
PiperOrigin-RevId: 457044228
2 years ago
Protobuf Team Bot
7975945e61
clean up the dependency graph some more
...
PiperOrigin-RevId: 456890270
2 years ago
Protobuf Team Bot
e153b52394
split out upb_StringView from upb.h
...
PiperOrigin-RevId: 456858455
2 years ago
Protobuf Team Bot
8d0d13f2bc
Fix the dependency chain for internal/arena.h
...
Clean up a few other superfluous #include's and forward declarations
PiperOrigin-RevId: 456851942
2 years ago
Protobuf Team Bot
b174d9d5a0
split out the internal arena defs from internal/upb.h
...
PiperOrigin-RevId: 456584853
2 years ago
Protobuf Team Bot
7b05f25b98
split out the alloc code from the arena code
...
PiperOrigin-RevId: 456531002
2 years ago
Protobuf Team Bot
e4635f223e
match file names to type names
...
Lots of changes but it's all just moving things around.
Backward-compatible stub #include's have been provided for now.
upb_Arena/upb_Status have been split out from upb/upb.?
upb_Array/upb_Map/upb_MessageValue have been split out from upb/collections.?
upb_ExtensionRegistry has been split out from upb/msg.?
upb/decode_internal.h is now upb/internal/decode.h
upb/mini_table_accessors_internal.h is now upb/internal/mini_table_accessors.h
upb/table_internal.h is now upb/internal/table.h
upb/upb_internal.h is now upb/internal/upb.h
PiperOrigin-RevId: 456297617
2 years ago
Protobuf Team Bot
bb38fc9c4d
First implementation of protoc-gen-upbdev plugin
...
PiperOrigin-RevId: 454243195
3 years ago
Protobuf Team Bot
6e1aa9f136
add json encoder option to render enums as ints
...
PiperOrigin-RevId: 453724657
3 years ago
Protobuf Team
e5f2601836
use constraints values in @platforms instead of @bazel_tools//platforms https://github.com/bazelbuild/bazel/issues/8622
...
PiperOrigin-RevId: 452387904
3 years ago
Joshua Haberman
4ffeaa6a58
Fixed Python Tests by disabling the numpy test for now.
...
PiperOrigin-RevId: 452357087
3 years ago