Apply clang-format for core/shared and product-mini files (#785)
Apply clang-format for core/shared and product-mini files
This commit is contained in:
@ -6,7 +6,6 @@
|
||||
#include "platform_api_vmcore.h"
|
||||
#include "platform_api_extension.h"
|
||||
|
||||
|
||||
int errno = 0;
|
||||
|
||||
int
|
||||
@ -27,7 +26,8 @@ bh_platform_destroy()
|
||||
os_thread_sys_destroy();
|
||||
}
|
||||
|
||||
int os_printf(const char *format, ...)
|
||||
int
|
||||
os_printf(const char *format, ...)
|
||||
{
|
||||
int ret = 0;
|
||||
va_list ap;
|
||||
@ -66,8 +66,7 @@ os_mprotect(void *addr, size_t size, int prot)
|
||||
|
||||
void
|
||||
os_dcache_flush()
|
||||
{
|
||||
}
|
||||
{}
|
||||
|
||||
int
|
||||
atoi(const char *nptr)
|
||||
@ -112,11 +111,10 @@ memmove(void *dest, const void *src, size_t n)
|
||||
*d++ = *s++;
|
||||
}
|
||||
else {
|
||||
const char *lasts = s + (n-1);
|
||||
char *lastd = d + (n-1);
|
||||
const char *lasts = s + (n - 1);
|
||||
char *lastd = d + (n - 1);
|
||||
while (n--)
|
||||
*lastd-- = *lasts--;
|
||||
}
|
||||
return dest;
|
||||
}
|
||||
|
||||
|
||||
@ -6,9 +6,9 @@
|
||||
#include "platform_api_vmcore.h"
|
||||
#include "platform_api_extension.h"
|
||||
|
||||
uint8 *os_thread_get_stack_boundary()
|
||||
uint8 *
|
||||
os_thread_get_stack_boundary()
|
||||
{
|
||||
/* TODO: implement os_thread_get_stack_boundary */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
@ -45,9 +45,12 @@ typedef struct korp_cond {
|
||||
os_thread_wait_list thread_wait_list;
|
||||
} korp_cond;
|
||||
|
||||
int os_printf(const char *format, ...);
|
||||
int os_vprintf(const char *format, va_list ap);
|
||||
int
|
||||
os_printf(const char *format, ...);
|
||||
int
|
||||
os_vprintf(const char *format, va_list ap);
|
||||
|
||||
/* clang-format off */
|
||||
/* math functions which are not provided by os */
|
||||
double sqrt(double x);
|
||||
double floor(double x);
|
||||
@ -93,5 +96,6 @@ uint32_t htonl(uint32_t hostlong);
|
||||
uint16_t htons(uint16_t hostshort);
|
||||
uint32_t ntohl(uint32_t netlong);
|
||||
uint16_t ntohs(uint16_t netshort);
|
||||
/* clang-format on */
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user