diff options
| author | Charles <sircharlesaze@gmail.com> | 2019-11-13 09:30:24 +0100 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2019-11-13 09:30:24 +0100 |
| commit | 80f5c6a1cef114cd5006431149506bb5d87403b6 (patch) | |
| tree | 8462dbd3c0421755b84892a69102ecaef2c94fea | |
| parent | 3f2ef05278d42233f0a9ee9652e152824a7103e4 (diff) | |
| download | ft_printf-80f5c6a1cef114cd5006431149506bb5d87403b6.tar.gz ft_printf-80f5c6a1cef114cd5006431149506bb5d87403b6.tar.bz2 ft_printf-80f5c6a1cef114cd5006431149506bb5d87403b6.zip | |
Removed double, normed
| -rw-r--r-- | Makefile | 6 | ||||
| -rw-r--r-- | header.h | 4 | ||||
| -rw-r--r-- | main.c | 14 | ||||
| -rw-r--r-- | printer.c | 4 | ||||
| -rwxr-xr-x | test | bin | 28784 -> 23144 bytes |
5 files changed, 11 insertions, 17 deletions
@@ -6,14 +6,14 @@ # By: cacharle <marvin@42.fr> +#+ +:+ +#+ # # +#+#+#+#+#+ +#+ # # Created: 2019/10/28 17:41:14 by cacharle #+# #+# # -# Updated: 2019/11/09 01:06:42 by cacharle ### ########.fr # +# Updated: 2019/11/13 09:27:01 by cacharle ### ########.fr # # # # **************************************************************************** # LIBFT_ROOT = ./libft CC = gcc -CCFLAGS = -Wall -Wextra -g #-Werror +CCFLAGS = -Wall -Wextra -Werror LDFLAGS = -L. -lftprintf INCFLAGS = -I$(LIBFT_ROOT) @@ -25,7 +25,7 @@ NAME = libftprintf.a SRC = ft_printf.c utils.c printer.c parse.c list.c extract.c \ convert_int.c convert_uint.c convert_char.c convert_str.c \ convert_ptr.c convert_hex.c convert_percent.c convert_written.c \ - convert_none.c length_modifier.c parse_double.c convert_double.c + convert_none.c length_modifier.c OBJ = $(SRC:.c=.o) INCLUDE = header.h @@ -6,7 +6,7 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2019/10/29 00:06:46 by cacharle #+# #+# */ -/* Updated: 2019/11/13 08:57:56 by cacharle ### ########.fr */ +/* Updated: 2019/11/13 09:29:23 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -64,7 +64,7 @@ typedef struct s_flist t_pformat *content; } t_flist; -typedef struct +typedef struct s_printf_status { va_list ap; t_flist *flist; @@ -6,7 +6,7 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2019/10/28 04:25:09 by cacharle #+# #+# */ -/* Updated: 2019/11/13 08:50:26 by cacharle ### ########.fr */ +/* Updated: 2019/11/13 09:27:58 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -72,17 +72,13 @@ int main() ft_printf("left adjusted |%*d|\n", -5, 43); printf("left adjusted |%*d|\n", -5, 43); - ft_printf("overwrite |%*3d|\n", 5, 43); - printf("overwrite |%*3d|\n", 5, 43); - ft_printf("overwrite neg |%*-1d|\n", 0, 43); - printf("overwrite neg |%*-1d|\n", 0, 43); + /* ft_printf("overwrite |%*3d|\n", 5, 43); */ + /* printf("overwrite |%*3d|\n", 5, 43); */ + /* ft_printf("overwrite neg |%*-1d|\n", 0, 43); */ + /* printf("overwrite neg |%*-1d|\n", 0, 43); */ ft_printf("pointer field width |%15p|\n", &test); printf("pointer field width |%15p|\n", &test); - ft_printf("pointer precision |%.15p|\n", &test); - printf("pointer precision |%.15p|\n", &test); - ft_printf("pointer precision/width |%20.15p|\n", &test); - printf("pointer precision/width |%20.15p|\n", &test); ft_printf("bonjour%n", &test); printf("%d\n", test); @@ -6,7 +6,7 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2019/10/28 23:19:24 by cacharle #+# #+# */ -/* Updated: 2019/11/09 01:00:20 by cacharle ### ########.fr */ +/* Updated: 2019/11/13 09:28:35 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -59,8 +59,6 @@ char *convert_specifier(va_list ap, t_pformat *pformat) return (convert_percent(ap, pformat)); if (pformat->specifier == 'n') return (convert_written(ap, pformat)); - if (pformat->specifier == 'f') - return (convert_double(ap, pformat)); else return (convert_none(ap, pformat)); return (NULL); Binary files differ |
