Fix MSVC DLL build.

pull/2923/head
Feng Xiao 8 years ago
parent fab8812cc1
commit fe97d79abf
  1. 4
      src/google/protobuf/extension_set.h
  2. 4
      src/google/protobuf/extension_set_heavy.cc
  3. 2
      src/google/protobuf/generated_message_reflection.h
  4. 2
      src/google/protobuf/generated_message_util.h
  5. 2
      src/google/protobuf/map_entry.h
  6. 4
      src/google/protobuf/map_entry_lite.h

@ -438,9 +438,7 @@ class LIBPROTOBUF_EXPORT ExtensionSet {
// SpaceUsed()).
size_t SpaceUsedExcludingSelfLong() const;
int SpaceUsedExcludingSelf() const {
return internal::FromIntSize(SpaceUsedExcludingSelfLong());
}
int SpaceUsedExcludingSelf() const;
private:

@ -340,6 +340,10 @@ bool ExtensionSet::ParseMessageSet(io::CodedInputStream* input,
}
}
int ExtensionSet::SpaceUsedExcludingSelf() const {
return internal::FromIntSize(SpaceUsedExcludingSelfLong());
}
size_t ExtensionSet::SpaceUsedExcludingSelfLong() const {
size_t total_size =
extensions_.size() * sizeof(ExtensionMap::value_type);

@ -255,7 +255,7 @@ struct MigrationSchema {
// of whatever type the individual field would be. Strings and
// Messages use RepeatedPtrFields while everything else uses
// RepeatedFields.
class GeneratedMessageReflection PROTOBUF_FINAL : public Reflection {
class LIBPROTOBUF_EXPORT GeneratedMessageReflection PROTOBUF_FINAL : public Reflection {
public:
// Constructs a GeneratedMessageReflection.
// Parameters:

@ -177,7 +177,7 @@ LIBPROTOBUF_EXPORT inline const ::std::string& GetEmptyString() {
return GetEmptyStringAlreadyInited();
}
size_t StringSpaceUsedExcludingSelfLong(const string& str);
LIBPROTOBUF_EXPORT size_t StringSpaceUsedExcludingSelfLong(const string& str);
// True if IsInitialized() is true for all elements of t. Type is expected

@ -83,7 +83,7 @@ namespace internal {
template <typename Derived, typename Key, typename Value,
WireFormatLite::FieldType kKeyFieldType,
WireFormatLite::FieldType kValueFieldType, int default_enum_value>
class LIBPROTOBUF_EXPORT MapEntry
class MapEntry
: public MapEntryImpl<Derived, Message, Key, Value, kKeyFieldType,
kValueFieldType, default_enum_value> {
public:

@ -92,7 +92,7 @@ struct MoveHelper<false, false, true, T> { // strings and similar
template <typename Derived, typename Base, typename Key, typename Value,
WireFormatLite::FieldType kKeyFieldType,
WireFormatLite::FieldType kValueFieldType, int default_enum_value>
class LIBPROTOBUF_EXPORT MapEntryImpl : public Base {
class MapEntryImpl : public Base {
protected:
// Provide utilities to parse/serialize key/value. Provide utilities to
// manipulate internal stored type.
@ -537,7 +537,7 @@ class LIBPROTOBUF_EXPORT MapEntryImpl : public Base {
template <typename Key, typename Value, WireFormatLite::FieldType kKeyFieldType,
WireFormatLite::FieldType kValueFieldType, int default_enum_value>
class LIBPROTOBUF_EXPORT MapEntryLite
class MapEntryLite
: public MapEntryImpl<MapEntryLite<Key, Value, kKeyFieldType,
kValueFieldType, default_enum_value>,
MessageLite, Key, Value, kKeyFieldType,

Loading…
Cancel
Save