Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1098)

Unified Diff: fusl/arch/x86_64/bits/alltypes.h

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: fusl/arch/x86_64/bits/alltypes.h
diff --git a/fusl/arch/x86_64/bits/alltypes.h b/fusl/arch/x86_64/bits/alltypes.h
index 5ae8b5c5a01d762b0ed9ff5b77b4ce016c18be0e..77bfc14058b17ed6886d0e6bb7c6abd468156bc8 100644
--- a/fusl/arch/x86_64/bits/alltypes.h
+++ b/fusl/arch/x86_64/bits/alltypes.h
@@ -12,7 +12,6 @@ typedef __builtin_va_list __isoc_va_list;
#define __DEFINED___isoc_va_list
#endif
-
#ifndef __cplusplus
#if defined(__NEED_wchar_t) && !defined(__DEFINED_wchar_t)
typedef int wchar_t;
@@ -46,11 +45,13 @@ typedef double double_t;
#endif
#if defined(__NEED_max_align_t) && !defined(__DEFINED_max_align_t)
-typedef struct { long long __ll; long double __ld; } max_align_t;
+typedef struct {
+ long long __ll;
+ long double __ld;
+} max_align_t;
#define __DEFINED_max_align_t
#endif
-
#if defined(__NEED_time_t) && !defined(__DEFINED_time_t)
typedef long time_t;
#define __DEFINED_time_t
@@ -61,39 +62,80 @@ typedef long suseconds_t;
#define __DEFINED_suseconds_t
#endif
-
#if defined(__NEED_pthread_attr_t) && !defined(__DEFINED_pthread_attr_t)
-typedef struct { union { int __i[14]; volatile int __vi[14]; unsigned long __s[7]; } __u; } pthread_attr_t;
+typedef struct {
+ union {
+ int __i[14];
+ volatile int __vi[14];
+ unsigned long __s[7];
+ } __u;
+} pthread_attr_t;
#define __DEFINED_pthread_attr_t
#endif
#if defined(__NEED_pthread_mutex_t) && !defined(__DEFINED_pthread_mutex_t)
-typedef struct { union { int __i[10]; volatile int __vi[10]; volatile void *volatile __p[5]; } __u; } pthread_mutex_t;
+typedef struct {
+ union {
+ int __i[10];
+ volatile int __vi[10];
+ volatile void* volatile __p[5];
+ } __u;
+} pthread_mutex_t;
#define __DEFINED_pthread_mutex_t
#endif
#if defined(__NEED_mtx_t) && !defined(__DEFINED_mtx_t)
-typedef struct { union { int __i[10]; volatile int __vi[10]; volatile void *volatile __p[5]; } __u; } mtx_t;
+typedef struct {
+ union {
+ int __i[10];
+ volatile int __vi[10];
+ volatile void* volatile __p[5];
+ } __u;
+} mtx_t;
#define __DEFINED_mtx_t
#endif
#if defined(__NEED_pthread_cond_t) && !defined(__DEFINED_pthread_cond_t)
-typedef struct { union { int __i[12]; volatile int __vi[12]; void *__p[6]; } __u; } pthread_cond_t;
+typedef struct {
+ union {
+ int __i[12];
+ volatile int __vi[12];
+ void* __p[6];
+ } __u;
+} pthread_cond_t;
#define __DEFINED_pthread_cond_t
#endif
#if defined(__NEED_cnd_t) && !defined(__DEFINED_cnd_t)
-typedef struct { union { int __i[12]; volatile int __vi[12]; void *__p[6]; } __u; } cnd_t;
+typedef struct {
+ union {
+ int __i[12];
+ volatile int __vi[12];
+ void* __p[6];
+ } __u;
+} cnd_t;
#define __DEFINED_cnd_t
#endif
#if defined(__NEED_pthread_rwlock_t) && !defined(__DEFINED_pthread_rwlock_t)
-typedef struct { union { int __i[14]; volatile int __vi[14]; void *__p[7]; } __u; } pthread_rwlock_t;
+typedef struct {
+ union {
+ int __i[14];
+ volatile int __vi[14];
+ void* __p[7];
+ } __u;
+} pthread_rwlock_t;
#define __DEFINED_pthread_rwlock_t
#endif
#if defined(__NEED_pthread_barrier_t) && !defined(__DEFINED_pthread_barrier_t)
-typedef struct { union { int __i[8]; volatile int __vi[8]; void *__p[4]; } __u; } pthread_barrier_t;
+typedef struct {
+ union {
+ int __i[8];
+ volatile int __vi[8];
+ void* __p[4];
+ } __u;
+} pthread_barrier_t;
#define __DEFINED_pthread_barrier_t
#endif
@@ -132,44 +174,43 @@ typedef _Reg register_t;
#define __DEFINED_register_t
#endif
-
#if defined(__NEED_int8_t) && !defined(__DEFINED_int8_t)
-typedef signed char int8_t;
+typedef signed char int8_t;
#define __DEFINED_int8_t
#endif
#if defined(__NEED_int16_t) && !defined(__DEFINED_int16_t)
-typedef short int16_t;
+typedef short int16_t;
#define __DEFINED_int16_t
#endif
#if defined(__NEED_int32_t) && !defined(__DEFINED_int32_t)
-typedef int int32_t;
+typedef int int32_t;
#define __DEFINED_int32_t
#endif
#if defined(__NEED_int64_t) && !defined(__DEFINED_int64_t)
-typedef _Int64 int64_t;
+typedef _Int64 int64_t;
#define __DEFINED_int64_t
#endif
#if defined(__NEED_intmax_t) && !defined(__DEFINED_intmax_t)
-typedef _Int64 intmax_t;
+typedef _Int64 intmax_t;
#define __DEFINED_intmax_t
#endif
#if defined(__NEED_uint8_t) && !defined(__DEFINED_uint8_t)
-typedef unsigned char uint8_t;
+typedef unsigned char uint8_t;
#define __DEFINED_uint8_t
#endif
#if defined(__NEED_uint16_t) && !defined(__DEFINED_uint16_t)
-typedef unsigned short uint16_t;
+typedef unsigned short uint16_t;
#define __DEFINED_uint16_t
#endif
#if defined(__NEED_uint32_t) && !defined(__DEFINED_uint32_t)
-typedef unsigned int uint32_t;
+typedef unsigned int uint32_t;
#define __DEFINED_uint32_t
#endif
@@ -188,7 +229,6 @@ typedef unsigned _Int64 uintmax_t;
#define __DEFINED_uintmax_t
#endif
-
#if defined(__NEED_mode_t) && !defined(__DEFINED_mode_t)
typedef unsigned mode_t;
#define __DEFINED_mode_t
@@ -234,7 +274,6 @@ typedef unsigned _Int64 fsfilcnt_t;
#define __DEFINED_fsfilcnt_t
#endif
-
#if defined(__NEED_wint_t) && !defined(__DEFINED_wint_t)
typedef unsigned wint_t;
#define __DEFINED_wint_t
@@ -245,9 +284,8 @@ typedef unsigned long wctype_t;
#define __DEFINED_wctype_t
#endif
-
#if defined(__NEED_timer_t) && !defined(__DEFINED_timer_t)
-typedef void * timer_t;
+typedef void* timer_t;
#define __DEFINED_timer_t
#endif
@@ -262,16 +300,21 @@ typedef long clock_t;
#endif
#if defined(__NEED_struct_timeval) && !defined(__DEFINED_struct_timeval)
-struct timeval { time_t tv_sec; suseconds_t tv_usec; };
+struct timeval {
+ time_t tv_sec;
+ suseconds_t tv_usec;
+};
#define __DEFINED_struct_timeval
#endif
#if defined(__NEED_struct_timespec) && !defined(__DEFINED_struct_timespec)
-struct timespec { time_t tv_sec; long tv_nsec; };
+struct timespec {
+ time_t tv_sec;
+ long tv_nsec;
+};
#define __DEFINED_struct_timespec
#endif
-
#if defined(__NEED_pid_t) && !defined(__DEFINED_pid_t)
typedef int pid_t;
#define __DEFINED_pid_t
@@ -302,7 +345,6 @@ typedef unsigned useconds_t;
#define __DEFINED_useconds_t
#endif
-
#ifdef __cplusplus
#if defined(__NEED_pthread_t) && !defined(__DEFINED_pthread_t)
typedef unsigned long pthread_t;
@@ -311,7 +353,7 @@ typedef unsigned long pthread_t;
#else
#if defined(__NEED_pthread_t) && !defined(__DEFINED_pthread_t)
-typedef struct __pthread * pthread_t;
+typedef struct __pthread* pthread_t;
#define __DEFINED_pthread_t
#endif
@@ -331,7 +373,8 @@ typedef int pthread_spinlock_t;
#define __DEFINED_pthread_spinlock_t
#endif
-#if defined(__NEED_pthread_mutexattr_t) && !defined(__DEFINED_pthread_mutexattr_t)
+#if defined(__NEED_pthread_mutexattr_t) && \
+ !defined(__DEFINED_pthread_mutexattr_t)
typedef struct { unsigned __attr; } pthread_mutexattr_t;
#define __DEFINED_pthread_mutexattr_t
#endif
@@ -341,47 +384,48 @@ typedef struct { unsigned __attr; } pthread_condattr_t;
#define __DEFINED_pthread_condattr_t
#endif
-#if defined(__NEED_pthread_barrierattr_t) && !defined(__DEFINED_pthread_barrierattr_t)
+#if defined(__NEED_pthread_barrierattr_t) && \
+ !defined(__DEFINED_pthread_barrierattr_t)
typedef struct { unsigned __attr; } pthread_barrierattr_t;
#define __DEFINED_pthread_barrierattr_t
#endif
-#if defined(__NEED_pthread_rwlockattr_t) && !defined(__DEFINED_pthread_rwlockattr_t)
+#if defined(__NEED_pthread_rwlockattr_t) && \
+ !defined(__DEFINED_pthread_rwlockattr_t)
typedef struct { unsigned __attr[2]; } pthread_rwlockattr_t;
#define __DEFINED_pthread_rwlockattr_t
#endif
-
#if defined(__NEED_FILE) && !defined(__DEFINED_FILE)
typedef struct _IO_FILE FILE;
#define __DEFINED_FILE
#endif
-
#if defined(__NEED_mbstate_t) && !defined(__DEFINED_mbstate_t)
typedef struct __mbstate_t { unsigned __opaque1, __opaque2; } mbstate_t;
#define __DEFINED_mbstate_t
#endif
-
#if defined(__NEED_locale_t) && !defined(__DEFINED_locale_t)
-typedef struct __locale_struct * locale_t;
+typedef struct __locale_struct* locale_t;
#define __DEFINED_locale_t
#endif
-
#if defined(__NEED_sigset_t) && !defined(__DEFINED_sigset_t)
-typedef struct __sigset_t { unsigned long __bits[128/sizeof(long)]; } sigset_t;
+typedef struct __sigset_t {
+ unsigned long __bits[128 / sizeof(long)];
+} sigset_t;
#define __DEFINED_sigset_t
#endif
-
#if defined(__NEED_struct_iovec) && !defined(__DEFINED_struct_iovec)
-struct iovec { void *iov_base; size_t iov_len; };
+struct iovec {
+ void* iov_base;
+ size_t iov_len;
+};
#define __DEFINED_struct_iovec
#endif
-
#if defined(__NEED_socklen_t) && !defined(__DEFINED_socklen_t)
typedef unsigned socklen_t;
#define __DEFINED_socklen_t
@@ -392,7 +436,6 @@ typedef unsigned short sa_family_t;
#define __DEFINED_sa_family_t
#endif
-
#undef _Addr
#undef _Int64
#undef _Reg

Powered by Google App Engine
This is Rietveld 408576698