BaseTools: Remove the deprecated hash_key()
Replace "has_key()" with "in" to be compatible with python3. Based on "futurize -f lib2to3.fixes.fix_has_key" Contributed-under: TianoCore Contribution Agreement 1.1 Cc: Yonghong Zhu <yonghong.zhu@intel.com> Cc: Liming Gao <liming.gao@intel.com> Signed-off-by: Gary Lin <glin@suse.com> Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
This commit is contained in:
@ -338,7 +338,7 @@ class InfGuidObject():
|
||||
#
|
||||
pass
|
||||
|
||||
if self.Guids.has_key((InfGuidItemObj)):
|
||||
if (InfGuidItemObj) in self.Guids:
|
||||
GuidList = self.Guids[InfGuidItemObj]
|
||||
GuidList.append(InfGuidItemObj)
|
||||
self.Guids[InfGuidItemObj] = GuidList
|
||||
@ -350,4 +350,4 @@ class InfGuidObject():
|
||||
return True
|
||||
|
||||
def GetGuid(self):
|
||||
return self.Guids
|
||||
return self.Guids
|
||||
|
Reference in New Issue
Block a user