From 52b32081f95a4ecbf27d0b7b5244097b9ccfce35 Mon Sep 17 00:00:00 2001 From: Cameron Angus Date: Wed, 24 Jul 2024 14:25:23 +0100 Subject: [PATCH] Wrap private module fragment content within conditional extern "C++", to match declarations. (#4083) --- src/fmt.cc | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/fmt.cc b/src/fmt.cc index fb514ad7..0a838bb1 100644 --- a/src/fmt.cc +++ b/src/fmt.cc @@ -127,9 +127,17 @@ extern "C++" { module :private; #endif +#ifdef FMT_ATTACH_TO_GLOBAL_MODULE +extern "C++" { +#endif + #if FMT_HAS_INCLUDE("format.cc") # include "format.cc" #endif #if FMT_OS && FMT_HAS_INCLUDE("os.cc") # include "os.cc" #endif + +#ifdef FMT_ATTACH_TO_GLOBAL_MODULE +} +#endif