- extra spaces are removed
- static class member modifier processing is fixed (moved from 'rettype' to 'func_modlist')
This commit is contained in:
parent
2935bb29e5
commit
0f5f60f7f5
@ -749,8 +749,9 @@ class PythonWrapperGenerator(object):
|
|||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
srcfiles = hdr_parser.opencv_hdr_list
|
srcfiles = hdr_parser.opencv_hdr_list
|
||||||
dstdir = "/Users/vp/tmp"
|
dstdir = "/Users/vp/tmp"
|
||||||
if len(sys.argv) > 2:
|
if len(sys.argv) > 1:
|
||||||
dstdir = sys.argv[1]
|
dstdir = sys.argv[1]
|
||||||
|
if len(sys.argv) > 2:
|
||||||
srcfiles = sys.argv[2:]
|
srcfiles = sys.argv[2:]
|
||||||
generator = PythonWrapperGenerator()
|
generator = PythonWrapperGenerator()
|
||||||
generator.gen(srcfiles, dstdir)
|
generator.gen(srcfiles, dstdir)
|
||||||
|
@ -251,7 +251,7 @@ class CppHeaderParser(object):
|
|||||||
[const] {; | <function_body>}
|
[const] {; | <function_body>}
|
||||||
|
|
||||||
Returns the function declaration entry:
|
Returns the function declaration entry:
|
||||||
[<function_name>, <rettype>, <the_list_of_argument_descriptions>] (see above)
|
[<func name>, <return value C-type>, <list of modifiers>, <list of arguments>] (see above)
|
||||||
"""
|
"""
|
||||||
|
|
||||||
if not (("CV_EXPORTS_AS" in decl_str) or ("CV_EXPORTS_W" in decl_str) or \
|
if not (("CV_EXPORTS_AS" in decl_str) or ("CV_EXPORTS_W" in decl_str) or \
|
||||||
@ -400,7 +400,7 @@ class CppHeaderParser(object):
|
|||||||
return []
|
return []
|
||||||
|
|
||||||
if static_method:
|
if static_method:
|
||||||
rettype = " ".join([rettype, "/S"])
|
func_modlist.append("/S")
|
||||||
|
|
||||||
return [funcname, rettype, func_modlist, args]
|
return [funcname, rettype, func_modlist, args]
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user