mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-11-06 13:31:35 +08:00
changed tabs into spaces, added error if compiler is not supported
This commit is contained in:
@@ -146,6 +146,8 @@ public:
|
|||||||
return __sync_lock_test_and_set(&lready, false);
|
return __sync_lock_test_and_set(&lready, false);
|
||||||
#elif defined ( __GNUC__ )
|
#elif defined ( __GNUC__ )
|
||||||
return __atomic_exchange_n (&lready, false, __ATOMIC_SEQ_CST);
|
return __atomic_exchange_n (&lready, false, __ATOMIC_SEQ_CST);
|
||||||
|
#else
|
||||||
|
# error "This compiler is not supported"
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -155,6 +157,8 @@ public:
|
|||||||
__sync_lock_release(&ready);
|
__sync_lock_release(&ready);
|
||||||
#elif defined ( __GNUC__ )
|
#elif defined ( __GNUC__ )
|
||||||
__atomic_store_n (&ready, true, __ATOMIC_SEQ_CST);
|
__atomic_store_n (&ready, true, __ATOMIC_SEQ_CST);
|
||||||
|
#else
|
||||||
|
# error "This compiler is not supported"
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -164,6 +168,8 @@ public:
|
|||||||
__sync_lock_release(&ready);
|
__sync_lock_release(&ready);
|
||||||
#elif defined ( __GNUC__ )
|
#elif defined ( __GNUC__ )
|
||||||
__atomic_store_n (&ready, true, __ATOMIC_SEQ_CST);
|
__atomic_store_n (&ready, true, __ATOMIC_SEQ_CST);
|
||||||
|
#else
|
||||||
|
# error "This compiler is not supported"
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user