more [[gnu::...]] attributes

This commit is contained in:
Max Kellermann
2021-10-13 11:28:04 +02:00
parent 1c4b484a56
commit f510564d9d
135 changed files with 361 additions and 514 deletions

View File

@@ -326,7 +326,7 @@ public:
*/
std::unique_ptr<DetachedSong> LockReadTaggedSong() noexcept;
gcc_pure
[[gnu::pure]]
PlayerStatus LockGetStatus() noexcept;
PlayerState GetState() const noexcept {
@@ -338,7 +338,7 @@ public:
bool has_next_song;
};
gcc_pure
[[gnu::pure]]
SyncInfo LockGetSyncInfo() const noexcept {
const std::lock_guard<Mutex> protect(mutex);
return {state, next_song != nullptr};