summaryrefslogtreecommitdiffstats
path: root/BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py
diff options
context:
space:
mode:
authorYunhua Feng <yunhuax.feng@intel.com>2018-12-03 10:29:40 +0800
committerFeng, Bob C <bob.c.feng@intel.com>2019-02-01 11:09:18 +0800
commitaf881abc6537298feade1c0b01a2a77224635647 (patch)
treef7166d3a4dbf8604d418df17acf39b636b40b0aa /BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py
parent1d2aa01cdf4b853a79871bd13588c71a0eb3d601 (diff)
downloadedk2-af881abc6537298feade1c0b01a2a77224635647.tar.gz
edk2-af881abc6537298feade1c0b01a2a77224635647.tar.bz2
edk2-af881abc6537298feade1c0b01a2a77224635647.zip
BaseTools: replace long by int
replace long by int Because the long() was not exist in Python3 Cc: Bob Feng <bob.c.feng@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng <yunhuax.feng@intel.com> Tested-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Bob Feng <bob.c.feng@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py')
-rw-r--r--BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py b/BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py
index edd40a1498..6ddf38fd0d 100644
--- a/BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py
+++ b/BaseTools/Source/Python/AutoGen/ValidCheckingInfoObject.py
@@ -57,7 +57,7 @@ class VAR_CHECK_PCD_VARIABLE_TAB_CONTAINER(object):
itemIndex += 1
realLength += 5
for v_data in item.data:
- if type(v_data) in (int, long):
+ if isinstance(v_data, int):
realLength += item.StorageWidth
else:
realLength += item.StorageWidth
@@ -137,7 +137,7 @@ class VAR_CHECK_PCD_VARIABLE_TAB_CONTAINER(object):
Buffer += b
realLength += 1
for v_data in item.data:
- if type(v_data) in (int, long):
+ if isinstance(v_data, int):
b = pack(PACK_CODE_BY_SIZE[item.StorageWidth], v_data)
Buffer += b
realLength += item.StorageWidth