mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-09 01:18:00 +03:00
apibuild: Drop backslash between brackets
Backslash between brackets in Python is redundant. [1] 1: https://lintlyci.github.io/Flake8Rules/rules/E502.html Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Signed-off-by: Radostin Stoyanov <rstoyanov1@gmail.com>
This commit is contained in:
parent
d65f487a91
commit
aad30c3e57
@ -385,8 +385,8 @@ class index:
|
|||||||
up = idx.functions[id]
|
up = idx.functions[id]
|
||||||
# check that function condition agrees with header
|
# check that function condition agrees with header
|
||||||
if up.conditionals != self.functions[id].conditionals:
|
if up.conditionals != self.functions[id].conditionals:
|
||||||
self.warning("Header condition differs from Function for %s:" \
|
self.warning("Header condition differs from Function"
|
||||||
% id)
|
" for %s:" % id)
|
||||||
self.warning(" H: %s" % self.functions[id].conditionals)
|
self.warning(" H: %s" % self.functions[id].conditionals)
|
||||||
self.warning(" C: %s" % up.conditionals)
|
self.warning(" C: %s" % up.conditionals)
|
||||||
self.functions[id].update(None, up.module, up.type, up.info, up.extra)
|
self.functions[id].update(None, up.module, up.type, up.info, up.extra)
|
||||||
@ -1882,7 +1882,7 @@ class CParser:
|
|||||||
raise Exception()
|
raise Exception()
|
||||||
except:
|
except:
|
||||||
self.error(("struct '%s' is not allowed to contain long "
|
self.error(("struct '%s' is not allowed to contain long "
|
||||||
"field '%s', use long long instead") \
|
"field '%s', use long long instead")
|
||||||
% (name, field[1]))
|
% (name, field[1]))
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -1939,8 +1939,8 @@ class CParser:
|
|||||||
if token[1] == "[":
|
if token[1] == "[":
|
||||||
type = type + token[1]
|
type = type + token[1]
|
||||||
token = self.token()
|
token = self.token()
|
||||||
while token is not None and (token[0] != "sep" or \
|
while token is not None and (token[0] != "sep" or
|
||||||
token[1] != ";"):
|
token[1] != ";"):
|
||||||
type = type + token[1]
|
type = type + token[1]
|
||||||
token = self.token()
|
token = self.token()
|
||||||
|
|
||||||
@ -1954,9 +1954,9 @@ class CParser:
|
|||||||
token = self.parseBlock(token)
|
token = self.parseBlock(token)
|
||||||
else:
|
else:
|
||||||
self.comment = None
|
self.comment = None
|
||||||
while token is not None and (token[0] != "sep" or \
|
while token is not None and (token[0] != "sep" or
|
||||||
(token[1] != ';' and token[1] != ',')):
|
token[1] not in ',;'):
|
||||||
token = self.token()
|
token = self.token()
|
||||||
self.comment = None
|
self.comment = None
|
||||||
if token is None or token[0] != "sep" or (token[1] != ';' and
|
if token is None or token[0] != "sep" or (token[1] != ';' and
|
||||||
token[1] != ','):
|
token[1] != ','):
|
||||||
@ -2351,11 +2351,11 @@ class docBuilder:
|
|||||||
module = self.modulename_file(file)
|
module = self.modulename_file(file)
|
||||||
output.write(" <file name='%s'>\n" % (module))
|
output.write(" <file name='%s'>\n" % (module))
|
||||||
dict = self.headers[file]
|
dict = self.headers[file]
|
||||||
ids = uniq(list(dict.functions.keys()) + \
|
ids = uniq(list(dict.functions.keys()) +
|
||||||
list(dict.variables.keys()) + \
|
list(dict.variables.keys()) +
|
||||||
list(dict.macros.keys()) + \
|
list(dict.macros.keys()) +
|
||||||
list(dict.typedefs.keys()) + \
|
list(dict.typedefs.keys()) +
|
||||||
list(dict.structs.keys()) + \
|
list(dict.structs.keys()) +
|
||||||
list(dict.enums.keys()))
|
list(dict.enums.keys()))
|
||||||
for id in ids:
|
for id in ids:
|
||||||
output.write(" <ref name='%s'/>\n" % (id))
|
output.write(" <ref name='%s'/>\n" % (id))
|
||||||
|
Loading…
Reference in New Issue
Block a user