siffler en travaillant ! =*

libft cleanup
This commit is contained in:
Tanguy MAZE
2019-03-23 17:13:46 +01:00
parent 699dcef577
commit 9f04f49de6
118 changed files with 156 additions and 12 deletions

25
srcs/ft_lstiter.c Normal file
View File

@@ -0,0 +1,25 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_lstiter.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: tmaze <tmaze@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2018/04/08 19:48:44 by tmaze #+# #+# */
/* Updated: 2018/04/08 19:51:33 by tmaze ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
void ft_lstiter(t_list *lst, void (*f)(t_list *elem))
{
t_list *tmp;
tmp = lst;
while (tmp)
{
(*f)(tmp);
tmp = tmp->next;
}
}