Commit Graph

63 Commits (main)

Author SHA1 Message Date
Protobuf Team Bot d3b2fc52a4 Auto-generate files after cl/630090538 2024-05-02 17:02:37 +00:00
Protobuf Team Bot c9eeb1c8a7 Internal changes.
PiperOrigin-RevId: 630090538
2024-05-02 09:50:54 -07:00
Eric Salo 7a1c926ef3 upb: begin to delete the old Dart v2 plugin code
PiperOrigin-RevId: 628090572
2024-04-25 08:56:02 -07:00
Mike Kruskal 88e4ec9ea8 Fix Windows 2019 linker error due to bootstrap/staleness issues
PiperOrigin-RevId: 623824344
2024-04-11 07:52:40 -07:00
Eric Salo 9b8f41c595 upb: rewrite the Dart code generator in C++
PiperOrigin-RevId: 623367386
2024-04-09 21:24:09 -07:00
Protobuf Team Bot ac32c97fbf Auto-generate files after cl/623355801 2024-04-10 03:30:05 +00:00
Eric Salo 9118be944d upb: extension/basefield setters are now public functions
PiperOrigin-RevId: 623355801
2024-04-09 20:18:28 -07:00
Protobuf Team Bot d7f032ad15 Move private definitions out of //bazel
This is needed to make protobuf/bazel package minimal for other proto rules.

Keep 4 public bzl files in upb/bazel. They end up under protobuf/bazel, and they are legitimately used by other repositories.

Move upb_proto_library_internal/* under bazel/private. Those are utilities used in the rules. Moving them one level deeper makes protobuf/bazel package clean for other rules.

Move build_defs.bzl and amalgamation under /upb/bazel. Those are utilities used in the build.

Move lua.BUILD and python* uner /python/dist. Those are used in the WORKSPACE dependency setup.

PiperOrigin-RevId: 621442236
2024-04-03 01:37:51 -07:00
Protobuf Team Bot 83ec410d30 Internal change
PiperOrigin-RevId: 619377672
2024-03-27 05:50:55 -07:00
Eric Salo da06505bdd upb: use mapentry() in the code generator
PiperOrigin-RevId: 616713001
2024-03-17 22:20:23 -07:00
Mike Kruskal b6032d72e3 Add basic upb cmake support.
libupb will always be statically linked, and currently doesn't ever install itself.

PiperOrigin-RevId: 615136389
2024-03-12 12:43:16 -07:00
Protobuf Team Bot 45f9158b8a Auto-generate files after cl/613970553 2024-03-08 18:35:35 +00:00
Mike Kruskal 8c0485cb68 Include minitable codegen in checked-in cmake files
PiperOrigin-RevId: 613970553
2024-03-08 10:24:31 -08:00
Protobuf Team Bot e41ffb01a2 Auto-generate files after cl/613765356 2024-03-08 02:23:54 +00:00
Mike Kruskal 58312a6f2e Check in upb bootstrap gencode for future cmake usage
PiperOrigin-RevId: 613757614
2024-03-07 17:38:35 -08:00
Protobuf Team Bot f2242d7136 Add proto full name support for tracing.
Creates a tracing helper function to associate mini tables with proto full names to use for upcoming upb metrics collectors.

PiperOrigin-RevId: 613290255
2024-03-06 11:47:25 -08:00
Protobuf Team Bot e8244da7c6 Adds mutable extension accessors to the codegen for upb C for getting mutable extension messages.
PiperOrigin-RevId: 613017999
2024-03-05 17:10:26 -08:00
Mike Kruskal e26193d168 Add no-op support for the experimental_strip_nonfunctional_codegen parameter.
This will be used for codegen tests to verify that an editions upgrade hasn't changed anything meaningful.

PiperOrigin-RevId: 608660846
2024-02-20 10:45:53 -08:00
Eric Salo dad74e2db7 upb: remove reflection:internal as a dep in upb_generator/
PiperOrigin-RevId: 601286979
2024-01-24 17:46:40 -08:00
Joshua Haberman 50d0421170 Separate MiniTable code generator into a separate library target.
This will allow it to be linked into other code generators.

PiperOrigin-RevId: 599171495
2024-01-17 07:55:32 -08:00
Eric Salo e6d8669958 upb: fix gencode bug with Map<*, bytes>
PiperOrigin-RevId: 597678769
2024-01-11 16:09:26 -08:00
Eric Salo c7f44a02eb upb: finish locking down the upb_Array internals
PiperOrigin-RevId: 597629658
2024-01-11 12:54:01 -08:00
Marcel Hlopko 36d344b63f Automated rollback of commit 0ce457f6e7.
PiperOrigin-RevId: 597327159
2024-01-10 12:42:23 -08:00
Eric Salo c026907a5d upb: replace public universal hazzer with non-universal hazzers
PiperOrigin-RevId: 597126288
2024-01-09 21:07:43 -08:00
Protobuf Team Bot 0ce457f6e7 Adds mutable extension accessors to the codegen for upb C and adds a `::protos::MutableExtension` method to upb C++ for getting a mutable extension.
PiperOrigin-RevId: 597088960
2024-01-09 17:23:42 -08:00
Eric Salo c02f943f1a upb: distinguish between fields and extensions in the public clear() accessors
PiperOrigin-RevId: 596588385
2024-01-08 07:36:16 -08:00
Eric Salo 64dbf0dba4 upb: delete the aliases for upb:hash, upb:lex, upb:reflection_internal
PiperOrigin-RevId: 594992691
2024-01-01 18:21:58 -08:00
Protobuf Team Bot 19c800c4f8 Fix warning from missing (void) on a 0-arg function.
PiperOrigin-RevId: 594080778
2023-12-27 12:35:37 -08:00
Eric Salo 2fb0b93d9d upb: tighten up and lock down upb/wire/
PiperOrigin-RevId: 593821827
2023-12-26 10:58:17 -08:00
Joshua Haberman 238538b6ce Fixed breaking ARM tests by properly aligning default options.
This char array is interpreted as a proto, so it needs pointer alignment at least.

PiperOrigin-RevId: 592935088
2023-12-21 13:17:55 -08:00
Eric Salo b997cb6d8d upb: add a non-void typedef for upb_Message
PiperOrigin-RevId: 592863926
2023-12-21 08:12:16 -08:00
Eric Salo de7f589d44 upb: eliminate :mini_table_internal
PiperOrigin-RevId: 592392732
2023-12-19 17:57:50 -08:00
Eric Salo 1f67b8dfe1 upb: tag upb_MiniTableField:offset as UPB_ONLYBITS()
PiperOrigin-RevId: 592081461
2023-12-18 20:00:21 -08:00
Eric Salo a4a98bdcc0 upb: tag upb_Array.size as UPB_ONLYBITS()
PiperOrigin-RevId: 592035282
2023-12-18 16:03:58 -08:00
Eric Salo fa62c92071 upb: stop generating hazzers for repeated fields
PiperOrigin-RevId: 591299107
2023-12-15 10:44:15 -08:00
Eric Salo 0755621dd2 Automated rollback of commit 3c75c331d3.
PiperOrigin-RevId: 588239901
2023-12-05 17:51:34 -08:00
Eric Salo 3c75c331d3 upb: inline upb_Message_New()
PiperOrigin-RevId: 588189563
2023-12-05 14:29:15 -08:00
Eric Salo b64c6e193b upb: implement upb_Message_ShallowClone()/Copy()
PiperOrigin-RevId: 588088145
2023-12-05 09:00:55 -08:00
Eric Salo 848a2bfd41 upb: tag upb_MiniTableField:number as UPB_ONLYBITS()
PiperOrigin-RevId: 587127664
2023-12-01 14:55:46 -08:00
Eric Salo 0e6607a5c9 upb: tag upb_MiniTableField:mode as UPB_ONLYBITS()
PiperOrigin-RevId: 587022805
2023-12-01 08:53:55 -08:00
Mike Kruskal cba41100fb Force plugins to specify their edition support window.
This is similar to what we did for built-in generators, and gives us the ability to create a new edition without subtley breaking generators that don't support it yet.

PiperOrigin-RevId: 586756816
2023-11-30 12:40:46 -08:00
Eric Salo bb5322a194 upb: lock down upb_MiniTable (mostly)
PiperOrigin-RevId: 586542236
2023-11-29 21:32:35 -08:00
Eric Salo d0c85637e7 upb: lock down upb_MiniTableSub
PiperOrigin-RevId: 586187469
2023-11-28 20:52:28 -08:00
Eric Salo 19ef3a58cf upb: lock down MiniTableField
PiperOrigin-RevId: 586171362
2023-11-28 19:44:00 -08:00
Eric Salo 21133d554f upb: lock down upb_MiniTableExtension
PiperOrigin-RevId: 585817227
2023-11-27 18:46:40 -08:00
Eric Salo f6b38b5838 upb: lock down upb_MiniTableEnum
PiperOrigin-RevId: 585733953
2023-11-27 12:54:22 -08:00
Eric Salo 3ce2c573b3 upb: start to lock down upb_Array
PiperOrigin-RevId: 585696951
2023-11-27 10:48:10 -08:00
Eric Salo 7fa050d8c1 upb: move IsSubMessage() and IsRepeatedOrMap() from mini_table/internal/field.h
PiperOrigin-RevId: 584082079
2023-11-20 11:30:03 -08:00
Kevin King 9b8b2760f8 Move MessageInit function to cc_library
This allows rust generator to use this function directly in order to generate symbol names for Message MiniTables.

PiperOrigin-RevId: 584054361
2023-11-20 09:55:41 -08:00
Protobuf Team Bot 2a2ae9b176 Remove unused ext_scope variable from ExtensionIdentBase.
PiperOrigin-RevId: 581979197
2023-11-13 08:55:42 -08:00