aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorCharles <sircharlesaze@gmail.com>2020-02-17 03:36:53 +0100
committerCharles <sircharlesaze@gmail.com>2020-02-17 03:36:53 +0100
commiteb0678367c5cb09b43423f77d6f1c3063fae9a91 (patch)
treed178571f7db214e826c9c4ad7097d878fca391f2 /include
parent01b4cc91d1596cf94d709a627ed8ad64bc1e285d (diff)
downloadlibft-eb0678367c5cb09b43423f77d6f1c3063fae9a91.tar.gz
libft-eb0678367c5cb09b43423f77d6f1c3063fae9a91.tar.bz2
libft-eb0678367c5cb09b43423f77d6f1c3063fae9a91.zip
Added ft_lstlsearch and ft_lstlfind for ht manipulation
Diffstat (limited to 'include')
-rw-r--r--include/libft_ht.h4
-rw-r--r--include/libft_lst.h6
2 files changed, 7 insertions, 3 deletions
diff --git a/include/libft_ht.h b/include/libft_ht.h
index 0873e7d..ba1b3bb 100644
--- a/include/libft_ht.h
+++ b/include/libft_ht.h
@@ -6,7 +6,7 @@
/* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/01/31 10:36:09 by cacharle #+# #+# */
-/* Updated: 2020/02/16 02:23:06 by cacharle ### ########.fr */
+/* Updated: 2020/02/17 03:06:32 by cacharle ### ########.fr */
/* */
/* ************************************************************************** */
@@ -50,7 +50,7 @@ t_ftht_content *ft_htcontent_new(char *key, void *value);
*/
void ft_inter_htdelcontent_key(t_ftht_content *content);
-int ft_inter_htkey_equal(const void *ref_key,
+int ft_inter_htkey_cmp(const void *ref_key,
const void *content);
#endif
diff --git a/include/libft_lst.h b/include/libft_lst.h
index f92067d..a48c1aa 100644
--- a/include/libft_lst.h
+++ b/include/libft_lst.h
@@ -6,7 +6,7 @@
/* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/01/31 10:36:39 by cacharle #+# #+# */
-/* Updated: 2020/02/16 02:15:26 by cacharle ### ########.fr */
+/* Updated: 2020/02/17 03:05:36 by cacharle ### ########.fr */
/* */
/* ************************************************************************** */
@@ -43,6 +43,10 @@ void ft_lstremove_if(t_ftlst **lst,
t_ftdel_func del);
t_ftlst *ft_lstbsearch(t_ftlst *lst, t_ftcompar_func cmp,
const void *ref);
+t_ftlst *ft_lstlsearch(t_ftlst *lst, t_ftcompar_func cmp,
+ const void *ref);
+t_ftlst *ft_lstlfind(t_ftlst *lst, t_ftcompar_func cmp,
+ const void *ref);
void ft_lstsort(t_ftlst **begin_list, t_ftcompar_func cmp);
t_ftlst *ft_lstsorted_merge(t_ftlst *l1, t_ftlst *l2,
t_ftcompar_func cmp);