The following code comes from Ply, python’s lexer and parser. I understand the first line is a raw string but I also feel that the first line of the code looks like dead code and will be discarded in execution. How could I understand that line of code?
def t_newline(t):
r'\n+'
t.lexer.lineno += t.value.count("\n")