python: Replace dict.has_key with 'key in dict'
Python 3 has removed dict.has_key in favour of 'key in dict'. Change-Id: I9852a5f57d672bea815308eb647a0ce45624fad5 Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com> Reviewed-on: https://gem5-review.googlesource.com/c/15987 Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
This commit is contained in:
@@ -1338,7 +1338,7 @@ def identifyTarget(t):
|
||||
ext = t.split('.')[-1]
|
||||
if ext in target_types:
|
||||
return ext
|
||||
if obj2target.has_key(ext):
|
||||
if ext in obj2target:
|
||||
return obj2target[ext]
|
||||
match = re.search(r'/tests/([^/]+)/', t)
|
||||
if match and match.group(1) in target_types:
|
||||
|
||||
Reference in New Issue
Block a user