Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Define macro XBT_ATTRIB_DEPRECATED_v340.
[simgrid.git] / include / xbt / base.h
index 6f4c6b6..ceb0fb2 100644 (file)
@@ -1,4 +1,4 @@
-/* xbt.h - Public interface to the xbt (simgrid's toolbox)                  */
+/* xbt.h - Public interface to the xbt (SimGrid's toolbox)                  */
 
 /* Copyright (c) 2004-2023. The SimGrid Team. All rights reserved.          */
 
 #define XBT_ATTRIB_DEPRECATED(mesg) __attribute__((deprecated(mesg)))
 #endif
 
-#define XBT_ATTRIB_DEPRECATED_v334(mesg)                                                                               \
-  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.33)")
-#define XBT_ATTRIB_DEPRECATED_v335(mesg)                                                                               \
-  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.34)")
-#define XBT_ATTRIB_DEPRECATED_v336(mesg)                                                                               \
-  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.35)")
-#define XBT_ATTRIB_DEPRECATED_v337(mesg)                                                                               \
-  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.36)")
+#define XBT_ATTRIB_DEPRECATED_v338(mesg)                                                                               \
+  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.37)")
+#define XBT_ATTRIB_DEPRECATED_v339(mesg)                                                                               \
+  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.38)")
+#define XBT_ATTRIB_DEPRECATED_v340(mesg)                                                                               \
+  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped after v3.39)")
 
 /* Work around https://github.com/microsoft/vscode-cpptools/issues/4503 */
 #ifdef __INTELLISENSE__
 #  define XBT_ATTRIB_DESTRUCTOR(prio) __attribute__((__destructor__))
 #endif
 
-#ifndef XBT_ALWAYS_INLINE /* defined also in libsosp */
-#  if defined(__GNUC__)
-#    define XBT_ALWAYS_INLINE inline __attribute__ ((always_inline))
-#  else
-#    define XBT_ALWAYS_INLINE inline
-#  endif
+#define XBT_ATTRIB_NOINLINE __attribute__((noinline))
+
+#if defined(__GNUC__)
+#define XBT_ALWAYS_INLINE inline __attribute__((always_inline))
+#else
+#define XBT_ALWAYS_INLINE inline
 #endif
 
 /* Stringify argument. */
 #define _XBT_STRINGIFY_A_22_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_23_, __VA_ARGS__)(__VA_ARGS__)
 #define _XBT_STRINGIFY_A_23_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_24_, __VA_ARGS__)(__VA_ARGS__)
 #define _XBT_STRINGIFY_A_24_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_25_, __VA_ARGS__)(__VA_ARGS__)
-#define _XBT_STRINGIFY_A_25_(...) error_maximum_size_of_XBT_STRINGIFY_ARGS_reached
+#define _XBT_STRINGIFY_A_25_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_26_, __VA_ARGS__)(__VA_ARGS__)
+#define _XBT_STRINGIFY_A_26_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_27_, __VA_ARGS__)(__VA_ARGS__)
+#define _XBT_STRINGIFY_A_27_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_28_, __VA_ARGS__)(__VA_ARGS__)
+#define _XBT_STRINGIFY_A_28_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_29_, __VA_ARGS__)(__VA_ARGS__)
+#define _XBT_STRINGIFY_A_29_(a, ...) #a, _XBT_IF_ONE_ARG(_XBT_STRINGIFY, _XBT_STRINGIFY_A_30_, __VA_ARGS__)(__VA_ARGS__)
+#define _XBT_STRINGIFY_A_30_(...) error_maximum_size_of_XBT_STRINGIFY_ARGS_reached
 
 /* Rationale of XBT_PUBLIC:
  *   * This is for library symbols visible from the application-land.