]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools: Fix one expression bug to support ~ operate
authorYonghong Zhu <yonghong.zhu@intel.com>
Wed, 22 Aug 2018 02:11:23 +0000 (10:11 +0800)
committerYonghong Zhu <yonghong.zhu@intel.com>
Tue, 28 Aug 2018 06:33:47 +0000 (14:33 +0800)
current use (0x41>=~0x0&0x41|0x0) as Pcd value cause build failure
because the ~ is not correctly recognized.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
BaseTools/Source/Python/Common/Expression.py

index 0091e471c02da390a0adf70fc58e59c300d7d8d1..78c69faad626451545a1148a9a73d25a9f3fcdda 100644 (file)
@@ -788,7 +788,7 @@ class ValueExpression(BaseExpression):
         OpToken = ''\r
         for Ch in Expr:\r
             if Ch in self.NonLetterOpLst:\r
-                if '!' == Ch and OpToken:\r
+                if Ch in ['!', '~'] and OpToken:\r
                     break\r
                 self._Idx += 1\r
                 OpToken += Ch\r