Skip to content

Commit d7c1704

Browse files
authored
add FMT_INSTANTIATION_DEF_API for msvc
This should fix fmtlib#2228 To fix difference dllexport requirements msvc: dllexport at template instantiation definition in format.cc clang: dllexport at template instantiation declaration (extern template) in format.h
1 parent a1c6bfd commit d7c1704

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/format.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ vformat_to(buffer<char>&, string_view,
5757

5858
// Clang doesn't allow dllexport on template instantiation definitions:
5959
// https://reviews.llvm.org/D61118.
60-
template struct detail::basic_data<void>;
60+
template struct FMT_INSTANTIATION_DEF_API detail::basic_data<void>;
6161

6262
// Workaround a bug in MSVC2013 that prevents instantiation of format_float.
6363
int (*instantiate_format_float)(double, int, detail::float_specs,

0 commit comments

Comments
 (0)