Skip to content

Commit

Permalink
Add missing PROTOBUF_EXPORT to _table_ static data members for MS…
Browse files Browse the repository at this point in the history
…VC shared library builds.

PiperOrigin-RevId: 530907946
  • Loading branch information
protobuf-github-bot authored and copybara-github committed May 10, 2023
1 parent 95c5ed2 commit 64cf6ff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/google/protobuf/compiler/cpp/parse_function_generator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ void ParseFunctionGenerator::GenerateDataDecls(io::Printer* printer) {
auto field_num_to_entry_table = MakeNumToEntryTable(ordered_fields_);
format(
"friend class ::$proto_ns$::internal::TcParser;\n"
"static const ::$proto_ns$::internal::"
"PROTOBUF_EXPORT static const ::$proto_ns$::internal::"
"TcParseTable<$1$, $2$, $3$, $4$, $5$> _table_;\n",
tc_table_info_->table_size_log2, ordered_fields_.size(),
tc_table_info_->aux_entries.size(),
Expand Down Expand Up @@ -406,7 +406,7 @@ void ParseFunctionGenerator::GenerateTailCallTable(Formatter& format) {
// unknown fields and potentially an extension range.
auto field_num_to_entry_table = MakeNumToEntryTable(ordered_fields_);
format(
"constexpr ::_pbi::TcParseTable<$1$, $2$, $3$, $4$, $5$> "
"PROTOBUF_EXPORT constexpr ::_pbi::TcParseTable<$1$, $2$, $3$, $4$, $5$> "
"$classname$::_table_ = "
"{\n",
tc_table_info_->table_size_log2, ordered_fields_.size(),
Expand Down

0 comments on commit 64cf6ff

Please sign in to comment.