zhangyu-duck opened a new pull request, #19866:
URL: https://github.com/apache/nuttx/pull/19866

   ## Summary
   
   Two header-only fixes to make `<nuttx/atomic.h>` portable across compilers 
(including Tasking which lacks `__has_include`):
   
   1. Add `__has_include(x)` fallback macro in `compiler.h` for toolchains that 
don't define it.
   2. Simplify the `__ATOMIC_xxx` memory order constant guards in `atomic.h` so 
each constant has its own `#ifndef` block, independent of `ATOMIC_FUNC`.
   
   ## Stacked PR chain
   
   This is PR 1 of 3 in the atomic rework chain:
   - PR 1 (this): atomic.h header fixes
   - PR 2: multi-backend atomic implementation (IRQ + hwspinlock + arch)
   - PR 3: toolchain builtin atomic + API rename `atomic_fetch_xxx` -> 
`atomic_xxx`
   
   ## Test
   
   CI testbuild across ARM/RISC-V/SIM targets.


-- 
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