summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Beazley <dave@dabeaz.com>2022-11-26 11:38:01 -0600
committerDavid Beazley <dave@dabeaz.com>2022-11-26 11:38:01 -0600
commit12d161ad3395305f68712930cfe127c55bd3bc71 (patch)
treef2b0e36bb9746daf447020b2ecd57c009a22ddbe
parentee76ee7c4c0a0f1a53d013a6f0dd124f6a8a20f0 (diff)
downloadply-12d161ad3395305f68712930cfe127c55bd3bc71.tar.gz
Fix typo
-rw-r--r--doc/ply.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/doc/ply.md b/doc/ply.md
index d61e9ed..29a16de 100644
--- a/doc/ply.md
+++ b/doc/ply.md
@@ -477,13 +477,13 @@ parse. Here is an example of how this works:
# Get more input (Example)
more = input('... ')
if more:
- self.lexer.input(more)
- return self.lexer.token()
+ t.lexer.input(more)
+ return t.lexer.token()
return None
The EOF function should return the next available token (by calling
-`self.lexer.token())` or `None` to indicate no more data. Be aware that
-setting more input with the `self.lexer.input()` method does NOT reset
+`t.lexer.token())` or `None` to indicate no more data. Be aware that
+setting more input with the `t.lexer.input()` method does NOT reset
the lexer state or the `lineno` attribute used for position tracking.
The `lexpos` attribute is reset so be aware of that if you\'re using it
in error reporting.