Commit 668e3f66 authored by Max Kellermann's avatar Max Kellermann

locate: add "pure" attributes

parent 9e51733c
...@@ -104,6 +104,7 @@ locate_item_list_parse(char *argv[], int argc, bool fold_case) ...@@ -104,6 +104,7 @@ locate_item_list_parse(char *argv[], int argc, bool fold_case)
return list; return list;
} }
gcc_pure
static bool static bool
locate_tag_search(const struct song *song, enum tag_type type, const char *str) 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, ...@@ -164,6 +165,7 @@ locate_song_search(const struct song *song,
return true; return true;
} }
gcc_pure
static bool static bool
locate_tag_match(const struct song *song, enum tag_type type, const char *str) locate_tag_match(const struct song *song, enum tag_type type, const char *str)
{ {
......
...@@ -48,6 +48,7 @@ struct locate_item_list { ...@@ -48,6 +48,7 @@ struct locate_item_list {
struct locate_item items[1]; struct locate_item items[1];
}; };
gcc_pure
int int
locate_parse_type(const char *str); locate_parse_type(const char *str);
...@@ -67,11 +68,13 @@ gcc_nonnull(1) ...@@ -67,11 +68,13 @@ gcc_nonnull(1)
void void
locate_item_list_free(struct locate_item_list *list); locate_item_list_free(struct locate_item_list *list);
gcc_pure
gcc_nonnull(1,2) gcc_nonnull(1,2)
bool bool
locate_song_search(const struct song *song, locate_song_search(const struct song *song,
const struct locate_item_list *criteria); const struct locate_item_list *criteria);
gcc_pure
gcc_nonnull(1,2) gcc_nonnull(1,2)
bool bool
locate_song_match(const struct song *song, locate_song_match(const struct song *song,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment