diff options
author | Kevin Lim <ktlim@umich.edu> | 2006-07-27 17:49:00 -0400 |
---|---|---|
committer | Kevin Lim <ktlim@umich.edu> | 2006-07-27 17:49:00 -0400 |
commit | 08c0919b433d7188c61a43266f7cfa1d67df28ae (patch) | |
tree | 5deedc3aaff5a99df6819d1af3773e91cfaf25ed /src/python/m5/__init__.py | |
parent | 53e17d0368df22e9eb1b0b32296436fa3e19d6af (diff) | |
download | gem5-08c0919b433d7188c61a43266f7cfa1d67df28ae.tar.xz |
Clean up some more config stuff.
configs/common/FSConfig.py:
Clean up some code to make functions look less like classes. Also put makeList function (formerly listWrapper) into m5 itself.
configs/test/fs.py:
Update for changed code.
src/python/m5/__init__.py:
Put makeList into m5.
--HG--
extra : convert_revision : 731806a7486f9abf986f52926126df666b024b1d
Diffstat (limited to 'src/python/m5/__init__.py')
-rw-r--r-- | src/python/m5/__init__.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/python/m5/__init__.py b/src/python/m5/__init__.py index 3d0e3defa..950d605df 100644 --- a/src/python/m5/__init__.py +++ b/src/python/m5/__init__.py @@ -44,6 +44,11 @@ def panic(string): print >>sys.stderr, 'panic:', string sys.exit(1) +def makeList(objOrList): + if isinstance(objOrList, list): + return objOrList + return [objOrList] + # Prepend given directory to system module search path. We may not # need this anymore if we can structure our config library more like a # Python package. |