python: Add Python 3 workarounds for long

Python 3 doesn't have a separate long type. Make long an alias for int
where needed to maintain compatibility.

Change-Id: I4c0861302bc3a2fa5226b3041803ef975d29b2fd
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/15988
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
This commit is contained in:
Andreas Sandberg
2019-01-25 18:38:03 +00:00
parent debb5daace
commit b5b19d2470
7 changed files with 23 additions and 0 deletions

View File

@@ -45,6 +45,9 @@
from __future__ import print_function
from __future__ import absolute_import
import six
if six.PY3:
long = int
import sys
from types import FunctionType, MethodType, ModuleType