internal change

PiperOrigin-RevId: 619038132
pull/16304/head
Jie Luo 8 months ago committed by Copybara-Service
parent 0f2ad6db5a
commit a2cc9f7b62
  1. 7
      python/google/protobuf/link_error_fast_cpp.cc
  2. 7
      python/google/protobuf/link_error_pure_python.cc
  3. 2
      python/google/protobuf/link_error_upb.cc

@ -4,15 +4,16 @@ namespace google {
namespace protobuf { namespace protobuf {
namespace python { namespace python {
// This exists solely to cause a build/link time error when both // This exists solely to cause a build/link time error when more than one of
// :use_fast_cpp_protos and :use_pure_python are specified in a build.; // :use_upb_protos, :use_fast_cpp_protos and :use_pure_python are specified
// in a build.;
extern "C" { extern "C" {
// MUST match link_error_pure_python.cc's function signature. // MUST match link_error_pure_python.cc's function signature.
__attribute__((noinline)) __attribute__((optnone)) int __attribute__((noinline)) __attribute__((optnone)) int
go_SLASH_build_deps_on_BOTH_use_fast_cpp_protos_AND_use_pure_python() { go_SLASH_build_deps_on_multiple_python_proto_backends() {
return 1; return 1;
} }

@ -4,15 +4,16 @@ namespace google {
namespace protobuf { namespace protobuf {
namespace python { namespace python {
// This exists solely to cause a build/link time error when both // This exists solely to cause a build/link time error when more than one of
// :use_fast_cpp_protos and :use_pure_python are specified in a build.; // :use_upb_protos, :use_fast_cpp_protos and :use_pure_python are specified
// in a build.;
extern "C" { extern "C" {
// MUST match link_error_pure_python.cc's function signature. // MUST match link_error_pure_python.cc's function signature.
__attribute__((noinline)) __attribute__((optnone)) int __attribute__((noinline)) __attribute__((optnone)) int
go_SLASH_build_deps_on_BOTH_use_fast_cpp_protos_AND_use_pure_python() { go_SLASH_build_deps_on_multiple_python_proto_backends() {
return 0; return 0;
} }

@ -13,7 +13,7 @@ extern "C" {
// MUST match link_error_pure_python.cc's function signature. // MUST match link_error_pure_python.cc's function signature.
__attribute__((noinline)) __attribute__((optnone)) int __attribute__((noinline)) __attribute__((optnone)) int
go_SLASH_build_deps_on_BOTH_use_fast_cpp_protos_AND_use_pure_python() { go_SLASH_build_deps_on_multiple_python_proto_backends() {
return 2; return 2;
} }

Loading…
Cancel
Save