From 668e3f664f1632ec7ef97afb4fbe467d02be85d9 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 7 Aug 2012 23:43:36 +0200 Subject: [PATCH] locate: add "pure" attributes --- src/locate.c | 2 ++ src/locate.h | 3 +++ 2 files changed, 5 insertions(+) diff --git a/src/locate.c b/src/locate.c index dd6902e3f..ef746213a 100644 --- a/src/locate.c +++ b/src/locate.c @@ -104,6 +104,7 @@ locate_item_list_parse(char *argv[], int argc, bool fold_case) return list; } +gcc_pure static bool locate_tag_search(const struct song *song, enum tag_type type, const char *str) { @@ -164,6 +165,7 @@ locate_song_search(const struct song *song, return true; } +gcc_pure static bool locate_tag_match(const struct song *song, enum tag_type type, const char *str) { diff --git a/src/locate.h b/src/locate.h index 25ca790eb..5682679d1 100644 --- a/src/locate.h +++ b/src/locate.h @@ -48,6 +48,7 @@ struct locate_item_list { struct locate_item items[1]; }; +gcc_pure int locate_parse_type(const char *str); @@ -67,11 +68,13 @@ gcc_nonnull(1) void locate_item_list_free(struct locate_item_list *list); +gcc_pure gcc_nonnull(1,2) bool locate_song_search(const struct song *song, const struct locate_item_list *criteria); +gcc_pure gcc_nonnull(1,2) bool locate_song_match(const struct song *song,