1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00

Merge pull request #4833 from authmillenon/core/doc/why-struct

doc: atomic: provide explanation about why atomic_int_t is struct
This commit is contained in:
Joakim Nohlgård 2016-02-17 20:59:48 +01:00
commit 979a34b6ae

View File

@ -27,6 +27,9 @@ extern "C" {
/**
* @brief Integer variable for use in atomic counters.
*
* @note This type is a struct for hard type checking (let the compiler warn
* if int is assigned regularly).
*/
typedef struct atomic_int {
volatile int value; /**< the actual value */