Skip to content

Commit

Permalink
Add dllexport_decl for generated default instance. (#13085)
Browse files Browse the repository at this point in the history
Fixes #13084

Closes #13085

COPYBARA_INTEGRATE_REVIEW=#13085 from owent:add_dllexport_decl_for_generated_default_instance a46d4e8
PiperOrigin-RevId: 540938351
  • Loading branch information
owent authored and copybara-github committed Jun 16, 2023
1 parent e8a5627 commit 9d0961a
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 35 deletions.
6 changes: 3 additions & 3 deletions src/google/protobuf/compiler/cpp/file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,7 @@ void FileGenerator::GenerateSourceDefaultInstance(int idx, io::Printer* p) {
};
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT$ dllexport_decl$
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const $type$ $name$;
)cc");
}
Expand Down Expand Up @@ -590,7 +590,7 @@ void FileGenerator::GenerateSourceDefaultInstance(int idx, io::Printer* p) {
};
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT$ dllexport_decl$
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 $type$ $name$;
)cc");
} else {
Expand All @@ -609,7 +609,7 @@ void FileGenerator::GenerateSourceDefaultInstance(int idx, io::Printer* p) {
};
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT$ dllexport_decl$
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 $type$ $name$;
)cc");
}
Expand Down
8 changes: 4 additions & 4 deletions src/google/protobuf/compiler/plugin.pb.cc

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

56 changes: 28 additions & 28 deletions src/google/protobuf/descriptor.pb.cc

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 9d0961a

Please sign in to comment.