projects
/
gem5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
eeff538
)
Improve toBool
author
Nathan Binkert
<binkertn@umich.edu>
Thu, 24 Mar 2005 17:24:54 +0000
(12:24 -0500)
committer
Nathan Binkert
<binkertn@umich.edu>
Thu, 24 Mar 2005 17:24:54 +0000
(12:24 -0500)
python/m5/convert.py:
an empty string should still be false
--HG--
extra : convert_revision :
dd9900794d94cd018b57ec81bcbce1d412e2a83e
python/m5/convert.py
patch
|
blob
|
history
diff --git
a/python/m5/convert.py
b/python/m5/convert.py
index 2f69645b947f9783a93dcc89ba9acb0b0f359537..4a4492af7f3557a1af5f961a9580d656e1f11b79 100644
(file)
--- a/
python/m5/convert.py
+++ b/
python/m5/convert.py
@@
-81,6
+81,8
@@
def toBool(val):
return True
elif val == "false" or val == "f" or val == "no" or val == "n":
return False
+ elif val == "":
+ return False
return toInteger(val) != 0