BaseTools: Fix the bug for QuarkPlatformPkg build failure

The issue is that the string 'LPC' starts with the 'L' character and
this is being confused with L" or L' for a Unicode string or Unicode
character.

Fixes:https://bugzilla.tianocore.org/show_bug.cgi?id=831
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
This commit is contained in:
Zhu, Yonghong 2017-12-29 08:28:17 +08:00 committed by Liming Gao
parent a743986df8
commit f13f306b3b
1 changed files with 1 additions and 1 deletions

View File

@ -164,7 +164,7 @@ class ValueExpression(object):
else:
Oprand1,Size = ParseFieldValue('"' + Oprand1 + '"')
if type(Oprand2) == type(''):
if Oprand2[0] in ['"', "'", 'L'] or Oprand2.startswith('UINT'):
if Oprand2[0] in ['"', "'"] or Oprand2.startswith('L"') or Oprand2.startswith("L'") or Oprand2.startswith('UINT'):
Oprand2, Size = ParseFieldValue(Oprand2)
else:
Oprand2, Size = ParseFieldValue('"' + Oprand2 + '"')