diff options
Diffstat (limited to '')
-rw-r--r-- | libft/src/ft_isspace.c | 1 | ||||
-rw-r--r-- | libft/src/ft_iswhitespace.c | 25 |
2 files changed, 25 insertions, 1 deletions
diff --git a/libft/src/ft_isspace.c b/libft/src/ft_isspace.c index b9b653f..8454c7c 100644 --- a/libft/src/ft_isspace.c +++ b/libft/src/ft_isspace.c @@ -11,7 +11,6 @@ /* ************************************************************************** */ #include <libft.h> -#include <inttypes.h> t_bool ft_isspace(int c) diff --git a/libft/src/ft_iswhitespace.c b/libft/src/ft_iswhitespace.c new file mode 100644 index 0000000..3bb5868 --- /dev/null +++ b/libft/src/ft_iswhitespace.c @@ -0,0 +1,25 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* ft_iswhitespace.c :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: rbousset <marvin@42.fr> +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/02/14 17:06:40 by rbousset #+# #+# */ +/* Updated: 2020/02/14 17:06:40 by rbousset ### ########lyon.fr */ +/* */ +/* ************************************************************************** */ + +#include <libft.h> + +t_bool + ft_iswhitespace(int c) +{ + if (c == '\t' || + c == '\v' || + c == '\f' || + c == '\r' || + c == ' ') + return (TRUE); + return (FALSE); +} |