WIP parsing expansions

This commit is contained in:
LuckyLaszlo
2021-11-07 04:41:17 +01:00
parent b9fc6a9bc4
commit 0a5c7545c1
18 changed files with 631 additions and 355 deletions

View File

@@ -6,7 +6,7 @@
/* By: lperrey <lperrey@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/10/08 02:59:58 by lperrey #+# #+# */
/* Updated: 2021/11/02 14:03:51 by hulamy ### ########.fr */
/* Updated: 2021/11/07 04:13:53 by lperrey ### ########.fr */
/* */
/* ************************************************************************** */
@@ -29,12 +29,13 @@ void shell_script(t_all *c);
t_token *input_to_tokens(char *input);
// Parser
t_cmd **parsing(t_token *token_list, char **envp);
t_cmd **parsing(t_token *token_list);
int valid_syntax(t_token *token_list);
int valid_token(t_token **token_list, enum e_token_id token_id);
int valid_command_separator(const t_token *token_list);
t_cmd **fill_cmd(t_token *token, char **envp);
void cmd_expansion(t_cmd **cmd_arr, char **envp);
size_t count_pipes(t_token *token);
t_cmd **alloc_cmd_array(size_t cmd_nbr);
int words_expansions(t_token *t);
// Builtins
int builtin_env(int argc, char *argv[], t_all *c);
@@ -55,5 +56,6 @@ char **ft_dup_2d_char_arr(char **ptr);
void *ft_resize_2d_arr(void *ptr, size_t add_nbr);
void print_matrix(char **matrix, char *sep);
t_list *ft_lstbeforelast(t_list *lst);
t_list *ft_lstnew_generic(size_t lst_sizse, size_t content_size);
#endif