This project helped you? Give it a 🌟!
Version: 15. Bonus included.
I did my best to create a codebase that is as clean and efficient as possible, while also maximizing the reuse of basic functions in more complex ones.
In libft_docs.md
some personal notes that delve into specific aspects of my implementation and detailed theoretical explanations. Special mention for an argument about why atoi
should not handle overflow.
Most of the explanations were generated by GPT-4, with edits by me.
This repo is an extended version my libft.
The original project is stored in the .tar archive.
Change log:
- Makefile create obj/ directory.
- Functions classified in directories.
- Header in a new include/ directory.
- Implementation of
ft_strcmp
. - Implementation of
ft_write_fd
(asft_putstr_fd
, but return the write syscall return). - Now, linked lists are doubly linked. Nodes have a 'prev' pointer in addition to 'next'.
- Modification of
ft_lstclear
andft_lstdelone
to accept aNULL
pointer as delete function. Useful to delete the structure list without it's content. Use with caution, if the content of the list has not been kept somewhere, it may lead to leaks! ft_lstclear
set thelst
pointer toNULL
to avoid dangling pointer.
Tested by moulinette (125%) and the following tester, in their strictest version.