|
Minishell 1.0
42 School Minishell Project - A simple shell implementation
|
Lexer (Sözcüksel Analiz) modülü Ayrıntılar...
Bu dosyanın kaynak koduna git.
Fonksiyonlar | |
| int | process_next_token (t_shell *shell, int i) |
| Bir sonraki token'ı işler. | |
| static int | handle_newline (t_shell *shell, int *i, int *token_end) |
| Ardışık newline ve whitespace'leri atlayıp TOKEN_NEWLINE üretir. | |
| int | lexer (t_shell *shell) |
| Lexer ana fonksiyonu — komut satırını token'lara ayırır. | |
Lexer (Sözcüksel Analiz) modülü
Kullanıcı girişini token'lara ayırır. Shell pipeline'ının ilk aşaması. Girdi: shell->cmd_line (string) Çıktı: shell->token_list (linked list of t_token)
lexer.c dosyasında tanımlanmıştır.
| int process_next_token | ( | t_shell * | shell, |
| int | i ) |
Bir sonraki token'ı işler.
| shell | Shell yapısı |
| i | Mevcut indeks |
lexer.c dosyasının 31 numaralı satırında tanımlanmıştır.
Referanslar assess_char_category(), category_dispatcher() ve s_shell::cmd_line.
Referans veren lexer().
|
static |
Ardışık newline ve whitespace'leri atlayıp TOKEN_NEWLINE üretir.
lexer.c dosyasının 45 numaralı satırında tanımlanmıştır.
Referanslar append_token(), s_shell::cmd_line, QUOTE_NONE ve TOKEN_NEWLINE.
Referans veren lexer().
| int lexer | ( | t_shell * | shell | ) |
Lexer ana fonksiyonu — komut satırını token'lara ayırır.
lexer.c dosyasının 60 numaralı satırında tanımlanmıştır.
Referanslar append_token(), s_shell::cmd_line, handle_newline(), mark_last_token_adjacent(), process_next_token(), QUOTE_NONE, skip_whitespace() ve TOKEN_EOF.
Referans veren process_line().