#ifndef __SMCC_LEX_PARSER_H__ #define __SMCC_LEX_PARSER_H__ #include static inline cbool lex_parse_is_endline(int ch) { return ch == '\n' || ch == '\r'; } static inline cbool lex_parse_is_whitespace(int ch) { return ch == ' ' || ch == '\t'; } int lex_parse_char(scc_probe_stream_t *input, scc_pos_t *pos); cbool lex_parse_string(scc_probe_stream_t *input, scc_pos_t *pos, scc_cstring_t *output); cbool lex_parse_number(scc_probe_stream_t *input, scc_pos_t *pos, usize *output); cbool lex_parse_identifier(scc_probe_stream_t *input, scc_pos_t *pos, scc_cstring_t *output); void lex_parse_skip_endline(scc_probe_stream_t *input, scc_pos_t *pos); void lex_parse_skip_block_comment(scc_probe_stream_t *input, scc_pos_t *pos); void lex_parse_skip_line(scc_probe_stream_t *input, scc_pos_t *pos); void lex_parse_skip_whitespace(scc_probe_stream_t *input, scc_pos_t *pos); #endif /* __SMCC_LEX_PARSER_H__ */