mirror of https://github.com/acidanthera/audk.git
BaseTools/Ecc: Fix a bug to get correct member variable
Fix a bug to get correct member variable by ignoring 'OPTIONAL' modifier Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen <hesheng.chen@intel.com> Reviewed-by: YangX Li <yangx.li@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17800 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
fa4470638a
commit
fa3a21569b
|
@ -1632,8 +1632,11 @@ def CheckMemberVariableFormat(Name, Value, FileTable, TdId, ModelId):
|
|||
Field = Field.split('=')[0].strip()
|
||||
TokenList = Field.split()
|
||||
# Remove pointers before variable
|
||||
if not Pattern.match(TokenList[-1].lstrip('*')):
|
||||
ErrMsgList.append(TokenList[-1].lstrip('*'))
|
||||
Token = TokenList[-1]
|
||||
if Token in ['OPTIONAL']:
|
||||
Token = TokenList[-2]
|
||||
if not Pattern.match(Token.lstrip('*')):
|
||||
ErrMsgList.append(Token.lstrip('*'))
|
||||
|
||||
return ErrMsgList
|
||||
|
||||
|
|
Loading…
Reference in New Issue