fixed david

This commit is contained in:
2024-02-06 12:36:27 +01:00
parent e46bc4e602
commit 160c02fc75
23 changed files with 360 additions and 359 deletions

View File

@@ -1,14 +1,14 @@
/* ************************************************************************** */
/******************************************************************************/
/* */
/* ::: :::::::: */
/* string.cpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: maldavid <kbz_8.dev@akel-engine.com> +#+ +:+ +#+ */
/* By: vvaas <vvaas@student.42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/01/25 15:19:30 by maldavid #+# #+# */
/* Updated: 2024/01/25 15:20:20 by maldavid ### ########.fr */
/* Updated: 2024/02/06 12:36:19 by vvaas ### ########.fr */
/* */
/* ************************************************************************** */
/******************************************************************************/
#include <unstd/string.hpp>
@@ -18,13 +18,13 @@ namespace unstd
{
std::vector<std::string> elems;
std::string token;
for(std::string::const_iterator it = s.begin(); it != s.end();)
for (std::string::const_iterator it = s.begin(); it != s.end();)
{
if(*it == delim)
if (*it == delim)
{
elems.push_back(token);
token.clear();
while(*it == delim && it != s.end())
while (*it == delim && it != s.end())
it++;
}
else