int print_syntax_error(t_syntax_error err)
Print an error message to STDERR.
char * join_connected_delim(t_token **tokens, int *quoted)
Join connected tokens in a single string.
int count_word_tokens(t_token *tokens)
Count consecutive word token groups.
t_ast * parse_pipeline(t_token **tokens)
Parse a pipeline of commands connected by pipes.
t_ast * parse_simple_command(t_token **tokens)
Parse a simple command from consecutive word tokens.
t_ast * parse(t_token *tokens)
Parse a token list into an AST.
int is_redirection(t_token_type type)
Check if a token type is a redirection operator.
char ** collect_args(t_token **tokens, int *argc)
Collect consecutive word tokens into an arguments array.
t_ast * reverse_redir_chain(t_ast *node)
Reverse a redirection chain for left to right execution order.
t_ast * parse_command(t_token **tokens)
Parse a command with all its redirections.
int validate_syntax(t_token *tokens)
Run all validation checks on a token list.
Central type definitions for mandatory part.
t_syntax_error
Syntax error codes (for parser)
t_token_type
Token types produced by Lexer.
Lexer token (singly linked list)