xiaoxiang781216 commented on code in PR #21057:
URL: https://github.com/apache/nuttx/pull/21057#discussion_r4396125158


##########
include/nuttx/compiler.h:
##########
@@ -1538,14 +1655,123 @@
  * keep some non-standard names free for its own use.  Then the headers do
  * not define ERROR and OK (sys/types.h), set_errno() and get_errno()
  * (errno.h), zalloc() (stdlib.h), O_TEXT (fcntl.h) and the helper macros
- * below.  The other headers do not use these names.
+ * of this file below, such as memory_barrier() and UNUSED().  The headers
+ * that a program includes do not use these names.  A definition that the
+ * program made before is restored (saved at the start of this file).
  */
 
 #ifdef NUTTX_NO_EXTENSIONS
 #  undef weak_alias
 #  undef visibility_hidden
 #  undef visibility_default
 #  undef unused_data
+#  undef PRAGMA
+#  undef unroll_loop

Review Comment:
   why not use pop for all macro?



##########
include/nuttx/compiler.h:
##########
@@ -261,7 +261,8 @@
                                  extern __inline__ no_builtin(#fn) \
                                  __attribute__((__always_inline__, \
                                                 __gnu_inline__, 
__artificial__))
-#  elif defined(__OPTIMIZE__) && __OPTIMIZE__ > 0 && defined(__has_builtin)
+#  elif defined(__OPTIMIZE__) && __OPTIMIZE__ > 0 && \
+         defined(__has_builtin) && !defined(NUTTX_NO_EXTENSIONS)

Review Comment:
   why not use push/pop instead



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to