ETLCPP / etl

Embedded Template Library
https://www.etlcpp.com
MIT License
2.05k stars 372 forks source link

Strange expression in volatile atomic operator -- #855

Closed Chuvi-w closed 2 months ago

Chuvi-w commented 3 months ago

https://github.com/ETLCPP/etl/blob/a98d387a118281eb6bcd45ebbbf002ddc6626fe7/include/etl/atomic/atomic_gcc_sync.h#L170 Probably __atomic_fetch_sub(&value, 1), etl::memory_order_seq_cst; should be replaced to __atomic_fetch_sub(&value, 1, etl::memory_order_seq_cst);

I doubt this is a mistake. That's why I created an issue, not a pull request.

jwellbelove commented 3 months ago

You are correct, it is a mistake. I'm surprised that it doesn't show up in the syntax check test script.

jwellbelove commented 2 months ago

Fixed 20.38.11