mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Use strict C function prototypes
This fixes warnings when compiling with `-Wstrict-prototypes`. Functions with empty parameter lists behave differently in C and C++: - void func() in C is same as void func(...) in C++. - void func() in C++ is same as void func(void) in C.
This commit is contained in:
committed by
Marshall Greenblatt
parent
ce891b57e1
commit
8410b1383f
@ -20,7 +20,7 @@ def make_cpptoc_function_impl_existing(cls, name, func, impl, defined_names):
|
||||
notify(name + ' has manual edits')
|
||||
|
||||
# retrieve the C API prototype parts
|
||||
parts = func.get_capi_parts(defined_names)
|
||||
parts = func.get_capi_parts(defined_names, True)
|
||||
|
||||
changes = format_translation_changes(impl, parts)
|
||||
if len(changes) > 0:
|
||||
@ -36,7 +36,7 @@ def make_cpptoc_function_impl_new(cls, name, func, defined_names, base_scoped):
|
||||
func.parent, obj_header)
|
||||
|
||||
# retrieve the C API prototype parts
|
||||
parts = func.get_capi_parts(defined_names)
|
||||
parts = func.get_capi_parts(defined_names, True)
|
||||
result = make_cpptoc_impl_proto(name, func, parts) + ' {'
|
||||
|
||||
if isinstance(func.parent, obj_class) and \
|
||||
|
Reference in New Issue
Block a user