Automated Code Change

PiperOrigin-RevId: 596091728
pull/15275/head
Dmitri Gribenko 1 year ago committed by Copybara-Service
parent d6ccc70078
commit 321b817147
  1. 8
      python/google/protobuf/pyext/message.cc
  2. 10
      python/google/protobuf/pyext/message.h

@ -532,10 +532,10 @@ bool CheckAndGetInteger(PyObject* arg, T* value) {
// These are referenced by repeated_scalar_container, and must
// be explicitly instantiated.
template bool CheckAndGetInteger<int32>(PyObject*, int32*);
template bool CheckAndGetInteger<int64>(PyObject*, int64*);
template bool CheckAndGetInteger<uint32>(PyObject*, uint32*);
template bool CheckAndGetInteger<uint64>(PyObject*, uint64*);
template bool CheckAndGetInteger<int32_t>(PyObject*, int32_t*);
template bool CheckAndGetInteger<int64_t>(PyObject*, int64_t*);
template bool CheckAndGetInteger<uint32_t>(PyObject*, uint32_t*);
template bool CheckAndGetInteger<uint64_t>(PyObject*, uint64_t*);
bool CheckAndGetDouble(PyObject* arg, double* value) {
*value = PyFloat_AsDouble(arg);

@ -19,8 +19,6 @@
#include <string>
#include <unordered_map>
#include "google/protobuf/stubs/common.h"
namespace google {
namespace protobuf {
@ -338,10 +336,10 @@ bool InitProto2MessageModule(PyObject *m);
// These are referenced by repeated_scalar_container, and must
// be explicitly instantiated.
extern template bool CheckAndGetInteger<int32>(PyObject*, int32*);
extern template bool CheckAndGetInteger<int64>(PyObject*, int64*);
extern template bool CheckAndGetInteger<uint32>(PyObject*, uint32*);
extern template bool CheckAndGetInteger<uint64>(PyObject*, uint64*);
extern template bool CheckAndGetInteger<int32_t>(PyObject*, int32_t*);
extern template bool CheckAndGetInteger<int64_t>(PyObject*, int64_t*);
extern template bool CheckAndGetInteger<uint32_t>(PyObject*, uint32_t*);
extern template bool CheckAndGetInteger<uint64_t>(PyObject*, uint64_t*);
} // namespace python
} // namespace protobuf

Loading…
Cancel
Save