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>
This commit is contained in:
Andreas Sandberg
2019-01-25 11:32:25 +00:00
parent 6ba4545b1f
commit fa21127a64
13 changed files with 177 additions and 182 deletions

View File

@@ -74,7 +74,7 @@ class lookup(object):
return self.args[item]
except ValueError:
pass
raise IndexError, "Could not find '%s'" % item
raise IndexError("Could not find '%s'" % item)
class code_formatter_meta(type):
pattern = r"""