mirror of
https://gitlab.gnome.org/GNOME/libxml2
synced 2025-03-28 21:33:13 +00:00
Fix update call in apibuild.py
There are still a few places where try/except is used for branching. This is a bad idea since it can hide errors like this one.
This commit is contained in:
parent
92bb889be3
commit
288c951eff
@ -192,10 +192,10 @@ class index:
|
||||
if name[0:2] == '__':
|
||||
return None
|
||||
d = None
|
||||
try:
|
||||
if name in self.identifiers:
|
||||
d = self.identifiers[name]
|
||||
d.update(header, module, type, lineno, info, extra, conditionals)
|
||||
except:
|
||||
d.update(header, module, type, info, extra, conditionals)
|
||||
else:
|
||||
d = identifier(name, header, module, type, lineno, info, extra, conditionals)
|
||||
self.identifiers[name] = d
|
||||
|
||||
@ -214,10 +214,10 @@ class index:
|
||||
if name[0:2] == '__':
|
||||
return None
|
||||
d = None
|
||||
try:
|
||||
if name in self.identifiers:
|
||||
d = self.identifiers[name]
|
||||
d.update(header, module, type, lineno, info, extra, conditionals)
|
||||
except:
|
||||
d.update(header, module, type, info, extra, conditionals)
|
||||
else:
|
||||
d = identifier(name, header, module, type, lineno, info, extra, conditionals)
|
||||
self.identifiers[name] = d
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user