X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=BaseTools%2FSource%2FPython%2FCommon%2FExpression.py;h=9a3415ccaabe03bd29749f33a2895f88a91729a8;hp=462e8f93f883e3d765ccf4fefac02ff1e849bd6b;hb=9eb87141eca12b1f15afa4b769af04d1395891c6;hpb=55c84777ee638be8735a5c421941e7eb71633bdf diff --git a/BaseTools/Source/Python/Common/Expression.py b/BaseTools/Source/Python/Common/Expression.py index 462e8f93f8..9a3415ccaa 100644 --- a/BaseTools/Source/Python/Common/Expression.py +++ b/BaseTools/Source/Python/Common/Expression.py @@ -151,7 +151,7 @@ def ReplaceExprMacro(String, Macros, ExceptionList = None): InQuote = True MacroStartPos = String.find('$(') if MacroStartPos < 0: - for Pcd in gPlatformPcds.keys(): + for Pcd in gPlatformPcds: if Pcd in String: if Pcd not in gConditionalPcds: gConditionalPcds.append(Pcd) @@ -908,7 +908,7 @@ class ValueExpressionEx(ValueExpression): for Label in LabelList: if not IsValidCName(Label): raise BadExpression('%s is not a valid c variable name' % Label) - if Label not in LabelDict.keys(): + if Label not in LabelDict: LabelDict[Label] = str(LabelOffset) if Item.startswith('UINT8'): LabelOffset = LabelOffset + 1