diff --git a/.gitignore b/.gitignore index 41cb4a6..7ab93c8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ Build -compile_commands.json \ No newline at end of file +compile_commands.json +.cache \ No newline at end of file diff --git a/Include/Fledasty/Core/LinkedList.h b/Include/Fledasty/Core/LinkedList.h index c3ccc69..82c2fc6 100644 --- a/Include/Fledasty/Core/LinkedList.h +++ b/Include/Fledasty/Core/LinkedList.h @@ -51,7 +51,7 @@ FledastyError fledasty_linked_list_insert_after_value(FledastyLinkedList *curren FledastyError fledasty_linked_list_remove_at_index(FledastyLinkedList *current_linked_list, const size_t index); FledastyError fledasty_linked_list_remove_value(FledastyLinkedList *current_linked_list, void *value); -bool fledasty_linked_list_has_value(FledastyLinkedList *current_linked_list, void *value); -static inline bool fledasty_linked_list_is_empty(FledastyLinkedList *current_linked_list) { return current_linked_list->size == 0; } +bool fledasty_linked_list_has_value(const FledastyLinkedList *current_linked_list, void *value); +static inline bool fledasty_linked_list_is_empty(const FledastyLinkedList *current_linked_list) { return current_linked_list->size == 0; } #endif diff --git a/Src/Core/LinkedList.c b/Src/Core/LinkedList.c index fa6c8e2..5b415e1 100644 --- a/Src/Core/LinkedList.c +++ b/Src/Core/LinkedList.c @@ -22,7 +22,6 @@ * ----------------------------------------------------------------------------- */ #include "../../Include/Fledasty/Core/LinkedList.h" -#include "Fledasty/Utils/Error.h" #include #include @@ -273,7 +272,7 @@ FledastyError fledasty_linked_list_remove_value(FledastyLinkedList *current_link return FLEDASTY_ERROR_NONE; } -bool fledasty_linked_list_has_value(FledastyLinkedList *current_linked_list, void *value) { +bool fledasty_linked_list_has_value(const FledastyLinkedList *current_linked_list, void *value) { if (current_linked_list == NULL || value == NULL) { return false; }