BaseTools: Remove equality operator with None
replace "== None" with "is None" and "!= None" with "is not None" Cc: Yonghong Zhu <yonghong.zhu@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
This commit is contained in:
committed by
Yonghong Zhu
parent
05a32984ab
commit
4231a8193e
@ -906,12 +906,12 @@ cleanlib:
|
||||
# skip non-C files
|
||||
if File.Ext not in [".c", ".C"] or File.Name == "AutoGen.c":
|
||||
continue
|
||||
elif DepSet == None:
|
||||
elif DepSet is None:
|
||||
DepSet = set(self.FileDependency[File])
|
||||
else:
|
||||
DepSet &= set(self.FileDependency[File])
|
||||
# in case nothing in SourceFileList
|
||||
if DepSet == None:
|
||||
if DepSet is None:
|
||||
DepSet = set()
|
||||
#
|
||||
# Extract common files list in the dependency files
|
||||
@ -1516,7 +1516,7 @@ class TopLevelMakefile(BuildFile):
|
||||
|
||||
# TRICK: for not generating GenFds call in makefile if no FDF file
|
||||
MacroList = []
|
||||
if PlatformInfo.FdfFile != None and PlatformInfo.FdfFile != "":
|
||||
if PlatformInfo.FdfFile is not None and PlatformInfo.FdfFile != "":
|
||||
FdfFileList = [PlatformInfo.FdfFile]
|
||||
# macros passed to GenFds
|
||||
MacroList.append('"%s=%s"' % ("EFI_SOURCE", GlobalData.gEfiSource.replace('\\', '\\\\')))
|
||||
|
Reference in New Issue
Block a user