summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorLeSasse <l.sasse@fz-juelich.de>2024-03-27 09:49:37 +0100
committerNoel Grandin <noel.grandin@collabora.co.uk>2024-03-28 08:48:59 +0100
commit9e424d98e5af9f6219398e02cb05c454471c237d (patch)
tree81d99ef8b6dfe0cdc182ff736142852284df1e9e /bin
parentb470044cbf116b825ca86c1b054aaaaea7647646 (diff)
tdf#158803 test for membership should be 'not in', unnecessary semicolons
Change-Id: Ib82e40a0ec0e6d6c7a363150d033b07a8d045a89 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165378 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'bin')
-rwxr-xr-xbin/find-can-be-private-symbols.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/find-can-be-private-symbols.py b/bin/find-can-be-private-symbols.py
index 483b29cd7343..da28310196f7 100755
--- a/bin/find-can-be-private-symbols.py
+++ b/bin/find-can-be-private-symbols.py
@@ -65,7 +65,7 @@ with subprocess_find.stdout as txt:
# 0000000000000000 DF *UND* 0000000000000000 _ZN16FilterConfigItem10WriteInt32ERKN3rtl8OUStringEi
for line2_bytes in txt2:
line2 = line2_bytes.strip().decode("utf-8")
- if not("*UND*"in line2): continue
+ if "*UND*" not in line2: continue
tokens = line2.split(" ")
sym = tokens[len(tokens)-1].strip()
imported_symbols1.add(sym)
@@ -100,7 +100,7 @@ subprocess_find.terminate()
# Now we have to symbolize before comparing because sometimes (due to thunks) two
# different encoded names symbolize to the same method/func name
#
-progress = 0;
+progress = 0
progress_max_len = len(imported_symbols1) + len(exported_symbols1)
for sym in imported_symbols1:
progress += 1
@@ -109,7 +109,7 @@ for sym in imported_symbols1:
if filtered_sym.startswith("non-virtual thunk to "): filtered_sym = filtered_sym[21:]
elif filtered_sym.startswith("virtual thunk to "): filtered_sym = filtered_sym[17:]
imported_symbols2.add(filtered_sym)
-progress = 0;
+progress = 0
for sym in exported_symbols1:
progress += 1
if (progress % 128 == 0): print( str(int(progress * 100 / progress_max_len)) + "%")