diff --git a/py/lexer.c b/py/lexer.c index 6c8ac9aeed..458fba0900 100644 --- a/py/lexer.c +++ b/py/lexer.c @@ -792,7 +792,9 @@ void mp_lexer_to_next(mp_lexer_t *lex) { mp_lexer_next_token_into(lex, false); } -#if MICROPY_DEBUG_PRINTERS +#if 0 +// This function is used to print the current token and should only be +// needed to debug the lexer, so it's not available via a config option. void mp_lexer_show_token(const mp_lexer_t *lex) { printf("(" UINT_FMT ":" UINT_FMT ") kind:%u str:%p len:%zu", lex->tok_line, lex->tok_column, lex->tok_kind, lex->vstr.buf, lex->vstr.len); if (lex->vstr.len > 0) { diff --git a/py/lexer.h b/py/lexer.h index 1461f9c8cb..32aef96266 100644 --- a/py/lexer.h +++ b/py/lexer.h @@ -172,7 +172,6 @@ mp_lexer_t *mp_lexer_new_from_str_len(qstr src_name, const char *str, mp_uint_t void mp_lexer_free(mp_lexer_t *lex); void mp_lexer_to_next(mp_lexer_t *lex); -void mp_lexer_show_token(const mp_lexer_t *lex); /******************************************************************/ // platform specific import function; must be implemented for a specific port diff --git a/py/mpconfig.h b/py/mpconfig.h index 8cf4bbb779..6d18937177 100644 --- a/py/mpconfig.h +++ b/py/mpconfig.h @@ -362,7 +362,6 @@ #endif // Whether to build functions that print debugging info: -// mp_lexer_show_token // mp_bytecode_print // mp_parse_node_print #ifndef MICROPY_DEBUG_PRINTERS