diff options
author | Carsey, Jaben </o=Intel/ou=Americas01/cn=Workers/cn=Carsey, Jaben> | 2018-03-12 22:24:56 +0800 |
---|---|---|
committer | Yonghong Zhu <yonghong.zhu@intel.com> | 2018-03-15 14:50:15 +0800 |
commit | b3fa393f477a12fe0e1aedb36395ca9b345ae110 (patch) | |
tree | f4b60b8713de6eef4c35fe00d657882b7b47861b /BaseTools/Source/Python/UPT/Library/UniClassObject.py | |
parent | 75787f6580f331b8cf6765c677c6a8bdccb98270 (diff) | |
download | edk2-b3fa393f477a12fe0e1aedb36395ca9b345ae110.tar.gz edk2-b3fa393f477a12fe0e1aedb36395ca9b345ae110.tar.bz2 edk2-b3fa393f477a12fe0e1aedb36395ca9b345ae110.zip |
BaseTools: UPT: remove unused variable and inaccessible code.
gINCLUDE_PATTERN is never used.
IncList is always empty.
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>
Diffstat (limited to 'BaseTools/Source/Python/UPT/Library/UniClassObject.py')
-rw-r--r-- | BaseTools/Source/Python/UPT/Library/UniClassObject.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/BaseTools/Source/Python/UPT/Library/UniClassObject.py b/BaseTools/Source/Python/UPT/Library/UniClassObject.py index 1fbbf2e498..0014a7561b 100644 --- a/BaseTools/Source/Python/UPT/Library/UniClassObject.py +++ b/BaseTools/Source/Python/UPT/Library/UniClassObject.py @@ -1,7 +1,7 @@ ## @file
# Collect all defined strings in multiple uni files.
#
-# Copyright (c) 2014 - 2017, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2014 - 2018, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials are licensed and made available
# under the terms and conditions of the BSD License which accompanies this
@@ -47,8 +47,6 @@ NULL = u'\u0000' TAB = u'\t'
BACK_SPLASH = u'\\'
-gINCLUDE_PATTERN = re.compile("^!include[\s]+([\S]+)[\s]*$", re.MULTILINE | re.UNICODE)
-
gLANG_CONV_TABLE = {'eng':'en', 'fra':'fr', \
'aar':'aa', 'abk':'ab', 'ave':'ae', 'afr':'af', 'aka':'ak', 'amh':'am', \
'arg':'an', 'ara':'ar', 'asm':'as', 'ava':'av', 'aym':'ay', 'aze':'az', \
@@ -543,22 +541,6 @@ class UniFileClassObject(object): Line = Line.replace(u'\t', u' ')
Line = Line.replace(u'\u0006', u'\\')
- # IncList = gINCLUDE_PATTERN.findall(Line)
- IncList = []
- if len(IncList) == 1:
- for Dir in [File.Dir] + self.IncludePathList:
- IncFile = PathClass(str(IncList[0]), Dir)
- self.IncFileList.append(IncFile)
- if os.path.isfile(IncFile.Path):
- Lines.extend(self.PreProcess(IncFile, True))
- break
- else:
- EdkLogger.Error("Unicode File Parser",
- ToolError.FILE_NOT_FOUND,
- Message="Cannot find include file",
- ExtraData=str(IncList[0]))
- continue
-
#
# Check if single line has correct '"'
#
|