diff --git a/ast/include/ast/ast.h b/ast/include/ast/ast.h index 07bee2dd..b0a780e2 100644 --- a/ast/include/ast/ast.h +++ b/ast/include/ast/ast.h @@ -6,7 +6,7 @@ /* By: maiboyer +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/06/11 14:23:40 by maiboyer #+# #+# */ -/* Updated: 2024/07/22 16:52:19 by rparodi ### ########.fr */ +/* Updated: 2024/07/26 12:29:39 by rparodi ### ########.fr */ /* */ /* ************************************************************************** */ @@ -19,11 +19,11 @@ enum e_ast_node_kind { AST_ARITHMETIC_BINARY, - AST_ARITHMETIC_EXPANSION, //RAPH - AST_ARITHMETIC_LITTERAL, //RAPH - AST_ARITHMETIC_POSTFIX, //RAPH - AST_ARITHMETIC_TERNARY, //RAPH - AST_ARITHMETIC_UNARY, //RAPH + AST_ARITHMETIC_EXPANSION, + AST_ARITHMETIC_LITTERAL, + AST_ARITHMETIC_POSTFIX, + AST_ARITHMETIC_TERNARY, + AST_ARITHMETIC_UNARY, AST_CASE, AST_CASE_ITEM, AST_COMMAND, @@ -54,11 +54,11 @@ enum e_ast_node_kind union u_ast_node_data { t_ast_arithmetic_binary arithmetic_binary; - t_ast_arithmetic_literal arithmetic_literal; //RAPH - t_ast_arithmetic_expansion arithmetic_expansion; //RAPH - t_ast_arithmetic_postfix arithmetic_postfix; //RAPH - t_ast_arithmetic_ternary arithmetic_ternary; //RAPH - t_ast_arithmetic_unary arithmetic_unary; //RAPH + t_ast_arithmetic_literal arithmetic_literal; + t_ast_arithmetic_expansion arithmetic_expansion; + t_ast_arithmetic_postfix arithmetic_postfix; + t_ast_arithmetic_ternary arithmetic_ternary; + t_ast_arithmetic_unary arithmetic_unary; t_ast_case case_; t_ast_case_item case_item; t_ast_command command; diff --git a/ast/include/ast/ast_raw_structs.h b/ast/include/ast/ast_raw_structs.h index 5698a8ff..4b08da8b 100644 --- a/ast/include/ast/ast_raw_structs.h +++ b/ast/include/ast/ast_raw_structs.h @@ -6,7 +6,7 @@ /* By: maiboyer +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/06/14 17:46:58 by maiboyer #+# #+# */ -/* Updated: 2024/07/24 15:40:23 by maiboyer ### ########.fr */ +/* Updated: 2024/07/26 12:29:16 by rparodi ### ########.fr */ /* */ /* ************************************************************************** */ @@ -401,7 +401,7 @@ struct s_ast_heredoc_redirection /// $@ /// ``` -struct s_ast_expansion +struct s_ast_expansion { t_str var_name; bool len_operator; diff --git a/ast/include/function_declaration.h b/ast/include/function_declaration.h index 213bc7f2..596e8a54 100644 --- a/ast/include/function_declaration.h +++ b/ast/include/function_declaration.h @@ -6,24 +6,23 @@ /* By: rparodi +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/07/26 11:30:24 by rparodi #+# #+# */ -/* Updated: 2024/07/26 11:38:39 by rparodi ### ########.fr */ +/* Updated: 2024/07/26 12:59:29 by rparodi ### ########.fr */ /* */ /* ************************************************************************** */ #ifndef FUNCTION_DECLARATION_H # define FUNCTION_DECLARATION_H -#include "ast/ast.h" -#include "me/types.h" -#include +# include "ast/ast.h" +# include "me/types.h" +# include -#define NOT_DONE \ - { \ - printf("function `%s` isn't done !\n", __func__); \ - (void)(self); \ +#define NOT_DONE \ + { \ + printf("function `%s` isn't done !\n", __func__); \ + (void)(self); \ } - void ast_print_node(t_ast_node self); void ast_print_node_command(t_ast_node self); @@ -50,15 +49,15 @@ void ast_print_node_list(t_ast_node self); /*^^^ DONE ^^^*/ /*vvv NOT DONE vvv*/ -void ast_print_node_if(t_ast_node self) NOT_DONE; -void ast_print_node_case(t_ast_node self) NOT_DONE; -void ast_print_node_case_item(t_ast_node self) NOT_DONE; -void ast_print_node_elif(t_ast_node self) NOT_DONE; -void ast_print_node_else(t_ast_node self) NOT_DONE; -void ast_print_node_for(t_ast_node self) NOT_DONE; -void ast_print_node_until(t_ast_node self) NOT_DONE; -void ast_print_node_while(t_ast_node self) NOT_DONE; -void ast_print_node_heredoc_redirection(t_ast_node self) NOT_DONE; +void ast_print_node_if(t_ast_node self); +void ast_print_node_case(t_ast_node self); +void ast_print_node_case_item(t_ast_node self); +void ast_print_node_elif(t_ast_node self); +void ast_print_node_else(t_ast_node self); +void ast_print_node_for(t_ast_node self); +void ast_print_node_until(t_ast_node self); +void ast_print_node_while(t_ast_node self); +void ast_print_node_heredoc_redirection(t_ast_node self); /// HELPER_FUNCS