[gegl] gegl-parallel: don't include C++ bits for C++98/03



commit 95e107b694a3149fc6821cd0d98ee3c72a46d709
Author: Ell <ell_se yahoo com>
Date:   Fri Jul 19 20:07:04 2019 +0300

    gegl-parallel: don't include C++ bits for C++98/03
    
    The C++ bits of gegl-parallel.h require C++11 (they use lambdas);
    avoid including them for older versions of C++.
    
    We already condition our own C++ compilation on the availability of
    C++14, but since gegl-parallel.h is a public header, it should be
    possible to include it (even if not use its C++ interface) in
    older C++ versions.  We *could* make the C++ interface compatible
    with older versions, but laziness...

 gegl/gegl-parallel.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gegl/gegl-parallel.h b/gegl/gegl-parallel.h
index 493ccdc5e..a8d201c73 100644
--- a/gegl/gegl-parallel.h
+++ b/gegl/gegl-parallel.h
@@ -120,7 +120,7 @@ void   gegl_parallel_distribute_area  (const GeglRectangle             *area,
                                        gpointer                         user_data);
 
 
-#ifdef __cplusplus
+#if __cplusplus >= 201103
 
 extern "C++"
 {
@@ -193,7 +193,7 @@ gegl_parallel_distribute_area (const GeglRectangle        *area,
 
 }
 
-#endif /* __cplusplus */
+#endif /* __cplusplus >= 201103 */
 
 
 G_END_DECLS


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]