[rtems commit] basdefs.h: Add RTEMS_PURE

Sebastian Huber sebh at rtems.org
Mon Oct 26 08:13:51 UTC 2015


Module:    rtems
Branch:    master
Commit:    a3ba5b3798c5f02641b1d1f25109fc5ca99361a8
Changeset: http://git.rtems.org/rtems/commit/?id=a3ba5b3798c5f02641b1d1f25109fc5ca99361a8

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Fri Oct 16 08:17:20 2015 +0200

basdefs.h: Add RTEMS_PURE

---

 cpukit/score/include/rtems/score/basedefs.h | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/cpukit/score/include/rtems/score/basedefs.h b/cpukit/score/include/rtems/score/basedefs.h
index 5575a06..9e6bc0a 100644
--- a/cpukit/score/include/rtems/score/basedefs.h
+++ b/cpukit/score/include/rtems/score/basedefs.h
@@ -171,12 +171,14 @@
  *  variables.
  */
 #ifdef __GNUC__
-  #define RTEMS_COMPILER_PURE_ATTRIBUTE \
-     __attribute__ ((pure))
+  #define RTEMS_PURE __attribute__((__pure__))
 #else
-  #define RTEMS_COMPILER_PURE_ATTRIBUTE
+  #define RTEMS_PURE
 #endif
 
+/* Provided for backward compatibility */
+#define RTEMS_COMPILER_PURE_ATTRIBUTE RTEMS_PURE
+
 /**
  *  Instructs the compiler to issue a warning whenever a variable or function
  *  with this attribute will be used.




More information about the vc mailing list