Updated parser/src/scanner.c to be splitted

This commit is contained in:
Maieul BOYER 2024-09-02 17:43:53 +02:00
parent 78a595ef60
commit b2440780fb
No known key found for this signature in database
11 changed files with 415 additions and 363 deletions

View file

@ -6,7 +6,7 @@
/* By: maiboyer <maiboyer@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/09/02 13:22:04 by maiboyer #+# #+# */
/* Updated: 2024/09/02 13:27:44 by maiboyer ### ########.fr */
/* Updated: 2024/09/02 17:40:15 by maiboyer ### ########.fr */
/* */
/* ************************************************************************** */
@ -65,11 +65,17 @@ struct s_heredoc_scan_state
typedef bool (*t_heredoc_content_func)(struct s_heredoc_scan_state *state);
bool advance_word(TSLexer *lexer, t_string *unquoted_word);
bool check_scan_concat(t_scanner *scanner, TSLexer *lexer, const bool *valid_symbols);
bool scan(t_scanner *scanner, TSLexer *lexer, const bool *valid_symbols);
bool scan_bare_dollar(TSLexer *lexer);
bool scan_concat(t_scanner *scanner, TSLexer *lexer, const bool *valid_symbols);
bool scan_double_hash(t_scanner *scanner, TSLexer *lexer, const bool *valid_symbols);
bool scan_expansion_word(t_scanner *scanner, TSLexer *lexer, const bool *valid_symbols);
bool scan_heredoc_content(t_scanner *scanner, TSLexer *lexer, enum e_token_type middle_type, enum e_token_type end_type);
bool scan_heredoc_end(t_scanner *scanner, TSLexer *lexer);
bool scan_heredoc_end_identifier(t_heredoc *heredoc, TSLexer *lexer);
bool scan_heredoc_start(t_heredoc *heredoc, TSLexer *lexer);
bool scan_varname(t_scanner *scanner, TSLexer *lexer, const bool *valid_symbols);
void reset(t_scanner *scanner);
#endif