Fix discrepancies between function signatures in headers and documentation
This commit is contained in:
@@ -116,8 +116,8 @@ def compareSignatures(f, s):
|
||||
sarg = arg[1]
|
||||
ftype = re.sub(r"\b(cv|std)::", "", (farg[0] or ""))
|
||||
stype = re.sub(r"\b(cv|std)::", "", (sarg[0] or ""))
|
||||
ftype = re.sub(r" (&|\*)$", "\\1", ftype)
|
||||
stype = re.sub(r" (&|\*)$", "\\1", stype)
|
||||
ftype = re.sub(r"\s+(\*|&)$", "\\1", ftype)
|
||||
stype = re.sub(r"\s+(\*|&)$", "\\1", stype)
|
||||
if ftype != stype:
|
||||
return False, "type of argument #" + str(idx+1) + " mismatch"
|
||||
fname = farg[1] or "arg" + str(idx)
|
||||
@@ -153,7 +153,7 @@ def formatSignature(s):
|
||||
if idx > 0:
|
||||
_str += ", "
|
||||
argtype = re.sub(r"\bcv::", "", arg[0])
|
||||
argtype = re.sub(r" (&|\*)$", "\\1", argtype)
|
||||
argtype = re.sub(r"\s+(\*|&)$", "\\1", arg[0])
|
||||
bidx = argtype.find('[')
|
||||
if bidx < 0:
|
||||
_str += argtype + " "
|
||||
|
Reference in New Issue
Block a user