[libc] Fix hdrgen output for no-argument functions (#123245)
The hdrgen output is C, not C++.
This commit is contained in:
@@ -22,7 +22,7 @@ class Function:
|
||||
|
||||
def __str__(self):
|
||||
attributes_str = " ".join(self.attributes)
|
||||
arguments_str = ", ".join(self.arguments)
|
||||
arguments_str = ", ".join(self.arguments) if self.arguments else "void"
|
||||
if attributes_str == "":
|
||||
result = f"{self.return_type} {self.name}({arguments_str})"
|
||||
else:
|
||||
|
||||
@@ -28,10 +28,10 @@ enum {
|
||||
|
||||
__BEGIN_C_DECLS
|
||||
|
||||
CONST_FUNC_A void func_a() __NOEXCEPT;
|
||||
CONST_FUNC_A void func_a(void) __NOEXCEPT;
|
||||
|
||||
#ifdef LIBC_TYPES_HAS_FLOAT128
|
||||
float128 func_b() __NOEXCEPT;
|
||||
float128 func_b(void) __NOEXCEPT;
|
||||
#endif // LIBC_TYPES_HAS_FLOAT128
|
||||
|
||||
#ifdef LIBC_TYPES_HAS_FLOAT16
|
||||
|
||||
Reference in New Issue
Block a user