Skip to content

Commit 9d0961a

Browse files
owentcopybara-github
authored andcommitted
Add dllexport_decl for generated default instance. (#13085)
Fixes #13084 Closes #13085 COPYBARA_INTEGRATE_REVIEW=#13085 from owent:add_dllexport_decl_for_generated_default_instance a46d4e8 PiperOrigin-RevId: 540938351
1 parent e8a5627 commit 9d0961a

File tree

3 files changed

+35
-35
lines changed

3 files changed

+35
-35
lines changed

src/google/protobuf/compiler/cpp/file.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,7 @@ void FileGenerator::GenerateSourceDefaultInstance(int idx, io::Printer* p) {
562562
};
563563
};
564564
565-
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
565+
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT$ dllexport_decl$
566566
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const $type$ $name$;
567567
)cc");
568568
}
@@ -590,7 +590,7 @@ void FileGenerator::GenerateSourceDefaultInstance(int idx, io::Printer* p) {
590590
};
591591
};
592592
593-
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
593+
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT$ dllexport_decl$
594594
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 $type$ $name$;
595595
)cc");
596596
} else {
@@ -609,7 +609,7 @@ void FileGenerator::GenerateSourceDefaultInstance(int idx, io::Printer* p) {
609609
};
610610
};
611611
612-
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
612+
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT$ dllexport_decl$
613613
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 $type$ $name$;
614614
)cc");
615615
}

src/google/protobuf/compiler/plugin.pb.cc

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/google/protobuf/descriptor.pb.cc

Lines changed: 28 additions & 28 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)