History log of /gem5/src/python/m5/util/grammar.py
Revision Date Author Comments
# 13720:18f5d3990ac9 26-Jan-2019 Andreas Sandberg <andreas.sandberg@arm.com>

python: Stop using basestring to test for strings

The base class basestring doesn't exist in Python 3. Use string_types
from six instead.

Change-Id: I7e84903fb7dd4a0af7ae4e9f4ec2e54338f212bb
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/15998
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Juha Jäykkä <juha.jaykka@arm.com>


# 13682:907a4f6c8435 25-Jan-2019 Andreas Sandberg <andreas.sandberg@arm.com>

python: Replace deprecated repr syntax

Change-Id: I5f9538cf2ca5ee17c51e7c5388d3aef363fcfa54
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/15989
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>


# 13670:8a98db5a481f 24-Jan-2019 Andreas Sandberg <andreas.sandberg@arm.com>

python: Switch to using open instead of file

Python 3 doesn't support the file(name, mode) syntax which has been
deprecated in favour of open.

Change-Id: I35ef8690d97a5243860a64ff985fd22fa86253f1
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/15985
Reviewed-by: Gabe Black <gabeblack@google.com>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>


# 13663:9b64aeabf9a5 25-Jan-2019 Andreas Sandberg <andreas.sandberg@arm.com>

python: Make exception handling Python 3 safe

Change-Id: I9c2cdfad20deb1ddfa224320cf93f2105d126652
Reviewed-on: https://gem5-review.googlesource.com/c/15980
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>


# 8452:3f2c329e9046 05-Jul-2011 Nathan Binkert <nate@binkert.org>

grammar: better encapsulation of a grammar and parsing
This makes it possible to use the grammar multiple times and use the multiple
instances concurrently. This makes implementing an include statement as part
of a grammar possible.


# 6660:a886774d5ae1 23-Sep-2009 Nathan Binkert <nate@binkert.org>

ply grammar: Fixup Tokenizer class so you can get lexer arguments


# 6501:1b5863aba48c 16-Aug-2009 Nathan Binkert <nate@binkert.org>

ply: add a base class called Grammar that encapsulates a ply grammar