summaryrefslogtreecommitdiff
path: root/CHANGES
diff options
context:
space:
mode:
authorDavid Beazley <dave@dabeaz.com>2012-04-26 15:16:57 -0500
committerDavid Beazley <dave@dabeaz.com>2012-04-26 15:16:57 -0500
commitff91f50c7c5a0aac792ab2e256255feee5df7533 (patch)
treeec5211b4d92a40852700b35fdb2ee98eed87d5d6 /CHANGES
parentc0f9ed554f3425b08b717933f94eb34485e8c993 (diff)
downloadply-ff91f50c7c5a0aac792ab2e256255feee5df7533.tar.gz
Reverted p_error() API
Diffstat (limited to 'CHANGES')
-rw-r--r--CHANGES9
1 files changed, 5 insertions, 4 deletions
diff --git a/CHANGES b/CHANGES
index 28da920..16f83cd 100644
--- a/CHANGES
+++ b/CHANGES
@@ -10,14 +10,15 @@ Version 3.5
The use of global variables was problematic for code involving multiple parsers
and frankly was a poor design overall. These functions have been moved to methods
- of the parser instance created by the yacc() function. To make it easier to
- obtain an instance of the parser in error handling, it is now passed as an optional
- parameter to p_error() like this:
+ of the parser instance created by the yacc() function. You should write code like
+ this:
- def p_error(p, parser):
+ def p_error(p):
...
parser.errok()
+ parser = yacc.yacc()
+
*** POTENTIAL INCOMPATIBILITY *** The original global functions now issue a
DeprecationWarning.