tokenizer update

This commit is contained in:
gazhonsepaskwa
2025-01-22 16:05:02 +01:00
parent 6539c3b9cb
commit 8dabbc426f
7 changed files with 44 additions and 20 deletions

View File

@@ -48,9 +48,11 @@ t_token get_token(char *str)
return (token);
}
t_pres get_pressision(char *s, t_token token)
t_pres get_pressision(char *s, t_token token, t_token last_token)
{
if (token == OPERATOR)
return (get_operator(s));
return (COMMAND);
else if (last_token == OPERATOR || last_token == UNSET)
return (COMMAND);
return (PARAMETER);
}