diff --git a/lesson_01/arrays.c b/lesson_01/arrays.c index a0c4c25..12db757 100644 --- a/lesson_01/arrays.c +++ b/lesson_01/arrays.c @@ -28,27 +28,29 @@ int main() { printf("void pointer to array: %p\n", void_pointer_to_values); // imprime cuantos bytes ocupa un entero en el sistema actual - printf("size of interger %d\n", sizeof(int)); + printf("size of interger %lu\n", sizeof(int)); // Regresa el numero de bytes que ocupa el arreglo completo - printf("size of array: %d\n", sizeof(values)); + printf("size of array: %lu\n", sizeof(values)); // Regresa el numero de bytes que ocupa una direccion de memoria // en la computadora donde se ejecuta - printf("size of array through pointer: %d\n", sizeof(pointer_to_values) ); + printf("size of array through pointer: %lu\n", sizeof(pointer_to_values) ); // Aritmetica de apuntadores, *(values + 2) == values[2] printf("pointer: %p, pointer + 2: %p\n", values, values + 2); + printf("pointer at position 2: %p\n", &values[2]); printf("value at position 2 %d\n", *(values + 2)); printf("value at position 2 %d\n", values[2]); // Este arreglo lo creamos en el heap por medio de create_array int* array_head = create_array(); printf("other array: %p\n", array_head); + // *array_head == *(array_head + 0) == array_head[0] printf("other array value at 0: %d\n", *array_head); // C no tiene garbage collector, por lo que la memoria que pedimos del Heap - // la tenemos que liberar explicitamente llamando la función free - // No vamos a utiliza realmente malloc durante el curso - free(array_head); + // la tenemos que liberar explicitamente llamando la función free + // No vamos a utiliza realmente malloc durante el curso + free(array_head); return EXIT_SUCCESS; // 0 definido en stdlib } \ No newline at end of file diff --git a/lesson_01/struct.c b/lesson_01/struct.c index fcac29b..8f84a2b 100644 --- a/lesson_01/struct.c +++ b/lesson_01/struct.c @@ -22,6 +22,7 @@ void set_node_value(struct node* pointer_to_node, int new_value) { // Es azucar sintactito de "(*pointer_to_node).value = new_value;" } +// Paso por valor: se crea una copia del struct node void set_node_value_wrong_way(struct node node, int new_value) { node.value = new_value; } @@ -64,7 +65,7 @@ int main() { // Esta es la cantidad de memoria que utiliza un struct node en // la computadora donde ejecutamos este programa. - printf("sizeof(struct node) -> %d\n", sizeof(struct node)); + printf("sizeof(struct node) -> %lu\n", sizeof(struct node)); // Asi creamos un "struct node" en el heap struct node* other_node = create_node(8); diff --git a/lesson_02/preprocesor_directives.c b/lesson_02/preprocesor_directives.c index ae1fe84..0c72721 100644 --- a/lesson_02/preprocesor_directives.c +++ b/lesson_02/preprocesor_directives.c @@ -20,7 +20,7 @@ #include #include #include -#include "list.h" +//#include "list.h" /* @@ -33,6 +33,9 @@ // inesperados, dado que no podemos garantizar que la presedencia de // operadores se respete al hacer sustitucion textual #define ADD(x, y) ((x) + (y)) + +// Observa que al remover estos paréntesis, +// la sustitución no se realiza de forma correcta #define MULT(x, y) (x * (y)) /* diff --git a/lesson_02/preprocessed_file.c b/lesson_02/preprocessed_file.c new file mode 100644 index 0000000..69bc11f --- /dev/null +++ b/lesson_02/preprocessed_file.c @@ -0,0 +1,1601 @@ +# 1 "preprocesor_directives.c" +# 1 "" 1 +# 1 "" 3 +# 400 "" 3 +# 1 "" 1 +# 1 "" 2 +# 1 "preprocesor_directives.c" 2 +# 19 "preprocesor_directives.c" +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 1 3 4 +# 64 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 1 3 4 +# 68 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h" 1 3 4 +# 659 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_symbol_aliasing.h" 1 3 4 +# 660 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h" 2 3 4 +# 725 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_posix_availability.h" 1 3 4 +# 726 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h" 2 3 4 +# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/Availability.h" 1 3 4 +# 135 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/Availability.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/AvailabilityVersions.h" 1 3 4 +# 136 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/Availability.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/AvailabilityInternal.h" 1 3 4 +# 137 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/Availability.h" 2 3 4 +# 70 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types.h" 1 3 4 +# 27 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types.h" 1 3 4 +# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/_types.h" 1 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/_types.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_types.h" 1 3 4 +# 15 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_types.h" 3 4 +typedef signed char __int8_t; + + + +typedef unsigned char __uint8_t; +typedef short __int16_t; +typedef unsigned short __uint16_t; +typedef int __int32_t; +typedef unsigned int __uint32_t; +typedef long long __int64_t; +typedef unsigned long long __uint64_t; + +typedef long __darwin_intptr_t; +typedef unsigned int __darwin_natural_t; +# 48 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_types.h" 3 4 +typedef int __darwin_ct_rune_t; + + + + + +typedef union { + char __mbstate8[128]; + long long _mbstateL; +} __mbstate_t; + +typedef __mbstate_t __darwin_mbstate_t; + + +typedef long int __darwin_ptrdiff_t; + + + + + + + +typedef long unsigned int __darwin_size_t; + + + + + +typedef __builtin_va_list __darwin_va_list; + + + + + +typedef int __darwin_wchar_t; + + + + +typedef __darwin_wchar_t __darwin_rune_t; + + +typedef int __darwin_wint_t; + + + + +typedef unsigned long __darwin_clock_t; +typedef __uint32_t __darwin_socklen_t; +typedef long __darwin_ssize_t; +typedef long __darwin_time_t; +# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/_types.h" 2 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types.h" 2 3 4 +# 55 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types.h" 3 4 +typedef __int64_t __darwin_blkcnt_t; +typedef __int32_t __darwin_blksize_t; +typedef __int32_t __darwin_dev_t; +typedef unsigned int __darwin_fsblkcnt_t; +typedef unsigned int __darwin_fsfilcnt_t; +typedef __uint32_t __darwin_gid_t; +typedef __uint32_t __darwin_id_t; +typedef __uint64_t __darwin_ino64_t; + +typedef __darwin_ino64_t __darwin_ino_t; + + + +typedef __darwin_natural_t __darwin_mach_port_name_t; +typedef __darwin_mach_port_name_t __darwin_mach_port_t; +typedef __uint16_t __darwin_mode_t; +typedef __int64_t __darwin_off_t; +typedef __int32_t __darwin_pid_t; +typedef __uint32_t __darwin_sigset_t; +typedef __int32_t __darwin_suseconds_t; +typedef __uint32_t __darwin_uid_t; +typedef __uint32_t __darwin_useconds_t; +typedef unsigned char __darwin_uuid_t[16]; +typedef char __darwin_uuid_string_t[37]; + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_pthread/_pthread_types.h" 1 3 4 +# 57 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_pthread/_pthread_types.h" 3 4 +struct __darwin_pthread_handler_rec { + void (*__routine)(void *); + void *__arg; + struct __darwin_pthread_handler_rec *__next; +}; + +struct _opaque_pthread_attr_t { + long __sig; + char __opaque[56]; +}; + +struct _opaque_pthread_cond_t { + long __sig; + char __opaque[40]; +}; + +struct _opaque_pthread_condattr_t { + long __sig; + char __opaque[8]; +}; + +struct _opaque_pthread_mutex_t { + long __sig; + char __opaque[56]; +}; + +struct _opaque_pthread_mutexattr_t { + long __sig; + char __opaque[8]; +}; + +struct _opaque_pthread_once_t { + long __sig; + char __opaque[8]; +}; + +struct _opaque_pthread_rwlock_t { + long __sig; + char __opaque[192]; +}; + +struct _opaque_pthread_rwlockattr_t { + long __sig; + char __opaque[16]; +}; + +struct _opaque_pthread_t { + long __sig; + struct __darwin_pthread_handler_rec *__cleanup_stack; + char __opaque[8176]; +}; + +typedef struct _opaque_pthread_attr_t __darwin_pthread_attr_t; +typedef struct _opaque_pthread_cond_t __darwin_pthread_cond_t; +typedef struct _opaque_pthread_condattr_t __darwin_pthread_condattr_t; +typedef unsigned long __darwin_pthread_key_t; +typedef struct _opaque_pthread_mutex_t __darwin_pthread_mutex_t; +typedef struct _opaque_pthread_mutexattr_t __darwin_pthread_mutexattr_t; +typedef struct _opaque_pthread_once_t __darwin_pthread_once_t; +typedef struct _opaque_pthread_rwlock_t __darwin_pthread_rwlock_t; +typedef struct _opaque_pthread_rwlockattr_t __darwin_pthread_rwlockattr_t; +typedef struct _opaque_pthread_t *__darwin_pthread_t; +# 81 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types.h" 2 3 4 +# 28 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types.h" 2 3 4 +# 40 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types.h" 3 4 +typedef int __darwin_nl_item; +typedef int __darwin_wctrans_t; + +typedef __uint32_t __darwin_wctype_t; +# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_va_list.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_va_list.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/types.h" 1 3 4 +# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/types.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 1 3 4 +# 55 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int8_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int8_t.h" 3 4 +typedef signed char int8_t; +# 56 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int16_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int16_t.h" 3 4 +typedef short int16_t; +# 57 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int32_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int32_t.h" 3 4 +typedef int int32_t; +# 58 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int64_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_int64_t.h" 3 4 +typedef long long int64_t; +# 59 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int8_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int8_t.h" 3 4 +typedef unsigned char u_int8_t; +# 61 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int16_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int16_t.h" 3 4 +typedef unsigned short u_int16_t; +# 62 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int32_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int32_t.h" 3 4 +typedef unsigned int u_int32_t; +# 63 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int64_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_u_int64_t.h" 3 4 +typedef unsigned long long u_int64_t; +# 64 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 + + +typedef int64_t register_t; + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_intptr_t.h" 1 3 4 +# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_intptr_t.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/types.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_intptr_t.h" 2 3 4 + +typedef __darwin_intptr_t intptr_t; +# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uintptr_t.h" 1 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uintptr_t.h" 3 4 +typedef unsigned long uintptr_t; +# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 2 3 4 + + + + +typedef u_int64_t user_addr_t; +typedef u_int64_t user_size_t; +typedef int64_t user_ssize_t; +typedef int64_t user_long_t; +typedef u_int64_t user_ulong_t; +typedef int64_t user_time_t; +typedef int64_t user_off_t; +# 104 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/types.h" 3 4 +typedef u_int64_t syscall_arg_t; +# 38 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/types.h" 2 3 4 +# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_va_list.h" 2 3 4 +typedef __darwin_va_list va_list; +# 76 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_size_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_size_t.h" 3 4 +typedef __darwin_size_t size_t; +# 77 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_null.h" 1 3 4 +# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/stdio.h" 1 3 4 +# 47 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/stdio.h" 3 4 +int renameat(int, const char *, int, const char *) __attribute__((availability(macosx,introduced=10.10))); + + + +int renamex_np(const char *, const char *, unsigned int) __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))); +int renameatx_np(int, const char *, int, const char *, unsigned int) __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))); +# 80 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 2 3 4 + +typedef __darwin_off_t fpos_t; +# 92 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 3 4 +struct __sbuf { + unsigned char *_base; + int _size; +}; + + +struct __sFILEX; +# 126 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_stdio.h" 3 4 +typedef struct __sFILE { + unsigned char *_p; + int _r; + int _w; + short _flags; + short _file; + struct __sbuf _bf; + int _lbfsize; + + + void *_cookie; + int (* _Nullable _close)(void *); + int (* _Nullable _read) (void *, char *, int); + fpos_t (* _Nullable _seek) (void *, fpos_t, int); + int (* _Nullable _write)(void *, const char *, int); + + + struct __sbuf _ub; + struct __sFILEX *_extra; + int _ur; + + + unsigned char _ubuf[3]; + unsigned char _nbuf[1]; + + + struct __sbuf _lb; + + + int _blksize; + fpos_t _offset; +} FILE; +# 65 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 2 3 4 + + +extern FILE *__stdinp; +extern FILE *__stdoutp; +extern FILE *__stderrp; +# 142 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +void clearerr(FILE *); +int fclose(FILE *); +int feof(FILE *); +int ferror(FILE *); +int fflush(FILE *); +int fgetc(FILE *); +int fgetpos(FILE * restrict, fpos_t *); +char *fgets(char * restrict, int, FILE *); + + + +FILE *fopen(const char * restrict __filename, const char * restrict __mode) __asm("_" "fopen" ); + +int fprintf(FILE * restrict, const char * restrict, ...) __attribute__((__format__ (__printf__, 2, 3))); +int fputc(int, FILE *); +int fputs(const char * restrict, FILE * restrict) __asm("_" "fputs" ); +size_t fread(void * restrict __ptr, size_t __size, size_t __nitems, FILE * restrict __stream); +FILE *freopen(const char * restrict, const char * restrict, + FILE * restrict) __asm("_" "freopen" ); +int fscanf(FILE * restrict, const char * restrict, ...) __attribute__((__format__ (__scanf__, 2, 3))); +int fseek(FILE *, long, int); +int fsetpos(FILE *, const fpos_t *); +long ftell(FILE *); +size_t fwrite(const void * restrict __ptr, size_t __size, size_t __nitems, FILE * restrict __stream) __asm("_" "fwrite" ); +int getc(FILE *); +int getchar(void); +char *gets(char *); +void perror(const char *) __attribute__((__cold__)); +int printf(const char * restrict, ...) __attribute__((__format__ (__printf__, 1, 2))); +int putc(int, FILE *); +int putchar(int); +int puts(const char *); +int remove(const char *); +int rename (const char *__old, const char *__new); +void rewind(FILE *); +int scanf(const char * restrict, ...) __attribute__((__format__ (__scanf__, 1, 2))); +void setbuf(FILE * restrict, char * restrict); +int setvbuf(FILE * restrict, char * restrict, int, size_t); +int sprintf(char * restrict, const char * restrict, ...) __attribute__((__format__ (__printf__, 2, 3))) __attribute__((__availability__(swift, unavailable, message="Use snprintf instead."))); +int sscanf(const char * restrict, const char * restrict, ...) __attribute__((__format__ (__scanf__, 2, 3))); +FILE *tmpfile(void); + +__attribute__((__availability__(swift, unavailable, message="Use mkstemp(3) instead."))) + +__attribute__((__deprecated__("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of tmpnam(3), it is highly recommended that you use mkstemp(3) instead."))) + +char *tmpnam(char *); +int ungetc(int, FILE *); +int vfprintf(FILE * restrict, const char * restrict, va_list) __attribute__((__format__ (__printf__, 2, 0))); +int vprintf(const char * restrict, va_list) __attribute__((__format__ (__printf__, 1, 0))); +int vsprintf(char * restrict, const char * restrict, va_list) __attribute__((__format__ (__printf__, 2, 0))) __attribute__((__availability__(swift, unavailable, message="Use vsnprintf instead."))); +# 205 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_ctermid.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_ctermid.h" 3 4 +char *ctermid(char *); +# 206 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 2 3 4 + + + + +FILE *fdopen(int, const char *) __asm("_" "fdopen" ); + +int fileno(FILE *); +# 223 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +int pclose(FILE *) __attribute__((__availability__(swift, unavailable, message="Use posix_spawn APIs or NSTask instead. (On iOS, process spawning is unavailable.)"))); + + + +FILE *popen(const char *, const char *) __asm("_" "popen" ) __attribute__((__availability__(swift, unavailable, message="Use posix_spawn APIs or NSTask instead. (On iOS, process spawning is unavailable.)"))); +# 242 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +int __srget(FILE *); +int __svfscanf(FILE *, const char *, va_list) __attribute__((__format__ (__scanf__, 2, 0))); +int __swbuf(int, FILE *); +# 253 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +inline __attribute__ ((__always_inline__)) int __sputc(int _c, FILE *_p) { + if (--_p->_w >= 0 || (_p->_w >= _p->_lbfsize && (char)_c != '\n')) + return (*_p->_p++ = _c); + else + return (__swbuf(_c, _p)); +} +# 279 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +void flockfile(FILE *); +int ftrylockfile(FILE *); +void funlockfile(FILE *); +int getc_unlocked(FILE *); +int getchar_unlocked(void); +int putc_unlocked(int, FILE *); +int putchar_unlocked(int); + + + +int getw(FILE *); +int putw(int, FILE *); + + +__attribute__((__availability__(swift, unavailable, message="Use mkstemp(3) instead."))) + +__attribute__((__deprecated__("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of tempnam(3), it is highly recommended that you use mkstemp(3) instead."))) + +char *tempnam(const char *__dir, const char *__prefix) __asm("_" "tempnam" ); +# 317 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_off_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_off_t.h" 3 4 +typedef __darwin_off_t off_t; +# 318 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 2 3 4 + + +int fseeko(FILE * __stream, off_t __offset, int __whence); +off_t ftello(FILE * __stream); + + + + + +int snprintf(char * restrict __str, size_t __size, const char * restrict __format, ...) __attribute__((__format__ (__printf__, 3, 4))); +int vfscanf(FILE * restrict __stream, const char * restrict __format, va_list) __attribute__((__format__ (__scanf__, 2, 0))); +int vscanf(const char * restrict __format, va_list) __attribute__((__format__ (__scanf__, 1, 0))); +int vsnprintf(char * restrict __str, size_t __size, const char * restrict __format, va_list) __attribute__((__format__ (__printf__, 3, 0))); +int vsscanf(const char * restrict __str, const char * restrict __format, va_list) __attribute__((__format__ (__scanf__, 2, 0))); +# 342 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_ssize_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_ssize_t.h" 3 4 +typedef __darwin_ssize_t ssize_t; +# 343 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 2 3 4 + + +int dprintf(int, const char * restrict, ...) __attribute__((__format__ (__printf__, 2, 3))) __attribute__((availability(macosx,introduced=10.7))); +int vdprintf(int, const char * restrict, va_list) __attribute__((__format__ (__printf__, 2, 0))) __attribute__((availability(macosx,introduced=10.7))); +ssize_t getdelim(char ** restrict __linep, size_t * restrict __linecapp, int __delimiter, FILE * restrict __stream) __attribute__((availability(macosx,introduced=10.7))); +ssize_t getline(char ** restrict __linep, size_t * restrict __linecapp, FILE * restrict __stream) __attribute__((availability(macosx,introduced=10.7))); +FILE *fmemopen(void * restrict __buf, size_t __size, const char * restrict __mode) __attribute__((availability(macos,introduced=10.13))) __attribute__((availability(ios,introduced=11.0))) __attribute__((availability(tvos,introduced=11.0))) __attribute__((availability(watchos,introduced=4.0))); +FILE *open_memstream(char **__bufp, size_t *__sizep) __attribute__((availability(macos,introduced=10.13))) __attribute__((availability(ios,introduced=11.0))) __attribute__((availability(tvos,introduced=11.0))) __attribute__((availability(watchos,introduced=4.0))); +# 360 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +extern const int sys_nerr; +extern const char *const sys_errlist[]; + +int asprintf(char ** restrict, const char * restrict, ...) __attribute__((__format__ (__printf__, 2, 3))); +char *ctermid_r(char *); +char *fgetln(FILE *, size_t *); +const char *fmtcheck(const char *, const char *); +int fpurge(FILE *); +void setbuffer(FILE *, char *, int); +int setlinebuf(FILE *); +int vasprintf(char ** restrict, const char * restrict, va_list) __attribute__((__format__ (__printf__, 2, 0))); + + + + + +FILE *funopen(const void *, + int (* _Nullable)(void *, char *, int), + int (* _Nullable)(void *, const char *, int), + fpos_t (* _Nullable)(void *, fpos_t, int), + int (* _Nullable)(void *)); +# 399 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/secure/_stdio.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/secure/_stdio.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/secure/_common.h" 1 3 4 +# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/secure/_stdio.h" 2 3 4 +# 42 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/secure/_stdio.h" 3 4 +extern int __sprintf_chk (char * restrict, int, size_t, + const char * restrict, ...); +# 52 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/secure/_stdio.h" 3 4 +extern int __snprintf_chk (char * restrict, size_t, int, size_t, + const char * restrict, ...); + + + + + + + +extern int __vsprintf_chk (char * restrict, int, size_t, + const char * restrict, va_list); + + + + + + + +extern int __vsnprintf_chk (char * restrict, size_t, int, size_t, + const char * restrict, va_list); +# 400 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h" 2 3 4 +# 20 "preprocesor_directives.c" 2 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 1 3 4 +# 66 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 1 3 4 +# 79 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 3 4 +typedef enum { + P_ALL, + P_PID, + P_PGID +} idtype_t; + + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_pid_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_pid_t.h" 3 4 +typedef __darwin_pid_t pid_t; +# 90 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_id_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_id_t.h" 3 4 +typedef __darwin_id_t id_t; +# 91 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 2 3 4 +# 109 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 1 3 4 +# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/appleapiopts.h" 1 3 4 +# 74 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 + + + + + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/signal.h" 1 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/signal.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/signal.h" 1 3 4 +# 17 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/signal.h" 3 4 +typedef int sig_atomic_t; +# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/signal.h" 2 3 4 +# 83 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 +# 146 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/_mcontext.h" 1 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/_mcontext.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_mcontext.h" 1 3 4 +# 36 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_mcontext.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/machine/_structs.h" 1 3 4 +# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/machine/_structs.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 1 3 4 +# 41 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_exception_state +{ + __uint32_t __exception; + __uint32_t __fsr; + __uint32_t __far; +}; +# 59 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_exception_state64 +{ + __uint64_t __far; + __uint32_t __esr; + __uint32_t __exception; +}; +# 77 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_thread_state +{ + __uint32_t __r[13]; + __uint32_t __sp; + __uint32_t __lr; + __uint32_t __pc; + __uint32_t __cpsr; +}; +# 136 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_thread_state64 +{ + __uint64_t __x[29]; + __uint64_t __fp; + __uint64_t __lr; + __uint64_t __sp; + __uint64_t __pc; + __uint32_t __cpsr; + __uint32_t __pad; +}; +# 433 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_vfp_state +{ + __uint32_t __r[64]; + __uint32_t __fpscr; +}; +# 452 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_neon_state64 +{ + __uint128_t __v[32]; + __uint32_t __fpsr; + __uint32_t __fpcr; +}; + +struct __darwin_arm_neon_state +{ + __uint128_t __v[16]; + __uint32_t __fpsr; + __uint32_t __fpcr; +}; +# 523 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __arm_pagein_state +{ + int __pagein_error; +}; +# 560 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __arm_legacy_debug_state +{ + __uint32_t __bvr[16]; + __uint32_t __bcr[16]; + __uint32_t __wvr[16]; + __uint32_t __wcr[16]; +}; +# 583 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_debug_state32 +{ + __uint32_t __bvr[16]; + __uint32_t __bcr[16]; + __uint32_t __wvr[16]; + __uint32_t __wcr[16]; + __uint64_t __mdscr_el1; +}; + + +struct __darwin_arm_debug_state64 +{ + __uint64_t __bvr[16]; + __uint64_t __bcr[16]; + __uint64_t __wvr[16]; + __uint64_t __wcr[16]; + __uint64_t __mdscr_el1; +}; +# 625 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/arm/_structs.h" 3 4 +struct __darwin_arm_cpmu_state64 +{ + __uint64_t __ctrs[16]; +}; +# 36 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/mach/machine/_structs.h" 2 3 4 +# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_mcontext.h" 2 3 4 + + + + +struct __darwin_mcontext32 +{ + struct __darwin_arm_exception_state __es; + struct __darwin_arm_thread_state __ss; + struct __darwin_arm_vfp_state __fs; +}; +# 64 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_mcontext.h" 3 4 +struct __darwin_mcontext64 +{ + struct __darwin_arm_exception_state64 __es; + struct __darwin_arm_thread_state64 __ss; + struct __darwin_arm_neon_state64 __ns; +}; +# 85 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/_mcontext.h" 3 4 +typedef struct __darwin_mcontext64 *mcontext_t; +# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/_mcontext.h" 2 3 4 +# 147 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_pthread/_pthread_attr_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_pthread/_pthread_attr_t.h" 3 4 +typedef __darwin_pthread_attr_t pthread_attr_t; +# 149 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_sigaltstack.h" 1 3 4 +# 42 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_sigaltstack.h" 3 4 +struct __darwin_sigaltstack +{ + void *ss_sp; + __darwin_size_t ss_size; + int ss_flags; +}; +typedef struct __darwin_sigaltstack stack_t; +# 151 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_ucontext.h" 1 3 4 +# 43 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_ucontext.h" 3 4 +struct __darwin_ucontext +{ + int uc_onstack; + __darwin_sigset_t uc_sigmask; + struct __darwin_sigaltstack uc_stack; + struct __darwin_ucontext *uc_link; + __darwin_size_t uc_mcsize; + struct __darwin_mcontext64 *uc_mcontext; + + + +}; + + +typedef struct __darwin_ucontext ucontext_t; +# 152 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_sigset_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_sigset_t.h" 3 4 +typedef __darwin_sigset_t sigset_t; +# 155 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uid_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uid_t.h" 3 4 +typedef __darwin_uid_t uid_t; +# 157 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 2 3 4 + +union sigval { + + int sival_int; + void *sival_ptr; +}; + + + + + +struct sigevent { + int sigev_notify; + int sigev_signo; + union sigval sigev_value; + void (*sigev_notify_function)(union sigval); + pthread_attr_t *sigev_notify_attributes; +}; + + +typedef struct __siginfo { + int si_signo; + int si_errno; + int si_code; + pid_t si_pid; + uid_t si_uid; + int si_status; + void *si_addr; + union sigval si_value; + long si_band; + unsigned long __pad[7]; +} siginfo_t; +# 269 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 +union __sigaction_u { + void (*__sa_handler)(int); + void (*__sa_sigaction)(int, struct __siginfo *, + void *); +}; + + +struct __sigaction { + union __sigaction_u __sigaction_u; + void (*sa_tramp)(void *, int, int, siginfo_t *, void *); + sigset_t sa_mask; + int sa_flags; +}; + + + + +struct sigaction { + union __sigaction_u __sigaction_u; + sigset_t sa_mask; + int sa_flags; +}; +# 331 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 +typedef void (*sig_t)(int); +# 348 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 +struct sigvec { + void (*sv_handler)(int); + int sv_mask; + int sv_flags; +}; +# 367 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 +struct sigstack { + char *ss_sp; + int ss_onstack; +}; +# 390 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/signal.h" 3 4 + void(*signal(int, void (*)(int)))(int); +# 110 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 1 3 4 +# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/usr/lib/clang/13.1.6/include/stdint.h" 1 3 4 +# 52 "/Library/Developer/CommandLineTools/usr/lib/clang/13.1.6/include/stdint.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 1 3 4 +# 23 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint8_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint8_t.h" 3 4 +typedef unsigned char uint8_t; +# 24 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint16_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint16_t.h" 3 4 +typedef unsigned short uint16_t; +# 25 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint32_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint32_t.h" 3 4 +typedef unsigned int uint32_t; +# 26 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint64_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uint64_t.h" 3 4 +typedef unsigned long long uint64_t; +# 27 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 2 3 4 + + +typedef int8_t int_least8_t; +typedef int16_t int_least16_t; +typedef int32_t int_least32_t; +typedef int64_t int_least64_t; +typedef uint8_t uint_least8_t; +typedef uint16_t uint_least16_t; +typedef uint32_t uint_least32_t; +typedef uint64_t uint_least64_t; + + + +typedef int8_t int_fast8_t; +typedef int16_t int_fast16_t; +typedef int32_t int_fast32_t; +typedef int64_t int_fast64_t; +typedef uint8_t uint_fast8_t; +typedef uint16_t uint_fast16_t; +typedef uint32_t uint_fast32_t; +typedef uint64_t uint_fast64_t; +# 58 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_intmax_t.h" 1 3 4 +# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_intmax_t.h" 3 4 +typedef long int intmax_t; +# 59 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uintmax_t.h" 1 3 4 +# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types/_uintmax_t.h" 3 4 +typedef long unsigned int uintmax_t; +# 60 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h" 2 3 4 +# 53 "/Library/Developer/CommandLineTools/usr/lib/clang/13.1.6/include/stdint.h" 2 3 4 +# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 2 3 4 + + + + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_timeval.h" 1 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_timeval.h" 3 4 +struct timeval +{ + __darwin_time_t tv_sec; + __darwin_suseconds_t tv_usec; +}; +# 81 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 2 3 4 + + + + + + + + +typedef __uint64_t rlim_t; +# 152 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 +struct rusage { + struct timeval ru_utime; + struct timeval ru_stime; +# 163 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 + long ru_maxrss; + + long ru_ixrss; + long ru_idrss; + long ru_isrss; + long ru_minflt; + long ru_majflt; + long ru_nswap; + long ru_inblock; + long ru_oublock; + long ru_msgsnd; + long ru_msgrcv; + long ru_nsignals; + long ru_nvcsw; + long ru_nivcsw; + + +}; +# 199 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 +typedef void *rusage_info_t; + +struct rusage_info_v0 { + uint8_t ri_uuid[16]; + uint64_t ri_user_time; + uint64_t ri_system_time; + uint64_t ri_pkg_idle_wkups; + uint64_t ri_interrupt_wkups; + uint64_t ri_pageins; + uint64_t ri_wired_size; + uint64_t ri_resident_size; + uint64_t ri_phys_footprint; + uint64_t ri_proc_start_abstime; + uint64_t ri_proc_exit_abstime; +}; + +struct rusage_info_v1 { + uint8_t ri_uuid[16]; + uint64_t ri_user_time; + uint64_t ri_system_time; + uint64_t ri_pkg_idle_wkups; + uint64_t ri_interrupt_wkups; + uint64_t ri_pageins; + uint64_t ri_wired_size; + uint64_t ri_resident_size; + uint64_t ri_phys_footprint; + uint64_t ri_proc_start_abstime; + uint64_t ri_proc_exit_abstime; + uint64_t ri_child_user_time; + uint64_t ri_child_system_time; + uint64_t ri_child_pkg_idle_wkups; + uint64_t ri_child_interrupt_wkups; + uint64_t ri_child_pageins; + uint64_t ri_child_elapsed_abstime; +}; + +struct rusage_info_v2 { + uint8_t ri_uuid[16]; + uint64_t ri_user_time; + uint64_t ri_system_time; + uint64_t ri_pkg_idle_wkups; + uint64_t ri_interrupt_wkups; + uint64_t ri_pageins; + uint64_t ri_wired_size; + uint64_t ri_resident_size; + uint64_t ri_phys_footprint; + uint64_t ri_proc_start_abstime; + uint64_t ri_proc_exit_abstime; + uint64_t ri_child_user_time; + uint64_t ri_child_system_time; + uint64_t ri_child_pkg_idle_wkups; + uint64_t ri_child_interrupt_wkups; + uint64_t ri_child_pageins; + uint64_t ri_child_elapsed_abstime; + uint64_t ri_diskio_bytesread; + uint64_t ri_diskio_byteswritten; +}; + +struct rusage_info_v3 { + uint8_t ri_uuid[16]; + uint64_t ri_user_time; + uint64_t ri_system_time; + uint64_t ri_pkg_idle_wkups; + uint64_t ri_interrupt_wkups; + uint64_t ri_pageins; + uint64_t ri_wired_size; + uint64_t ri_resident_size; + uint64_t ri_phys_footprint; + uint64_t ri_proc_start_abstime; + uint64_t ri_proc_exit_abstime; + uint64_t ri_child_user_time; + uint64_t ri_child_system_time; + uint64_t ri_child_pkg_idle_wkups; + uint64_t ri_child_interrupt_wkups; + uint64_t ri_child_pageins; + uint64_t ri_child_elapsed_abstime; + uint64_t ri_diskio_bytesread; + uint64_t ri_diskio_byteswritten; + uint64_t ri_cpu_time_qos_default; + uint64_t ri_cpu_time_qos_maintenance; + uint64_t ri_cpu_time_qos_background; + uint64_t ri_cpu_time_qos_utility; + uint64_t ri_cpu_time_qos_legacy; + uint64_t ri_cpu_time_qos_user_initiated; + uint64_t ri_cpu_time_qos_user_interactive; + uint64_t ri_billed_system_time; + uint64_t ri_serviced_system_time; +}; + +struct rusage_info_v4 { + uint8_t ri_uuid[16]; + uint64_t ri_user_time; + uint64_t ri_system_time; + uint64_t ri_pkg_idle_wkups; + uint64_t ri_interrupt_wkups; + uint64_t ri_pageins; + uint64_t ri_wired_size; + uint64_t ri_resident_size; + uint64_t ri_phys_footprint; + uint64_t ri_proc_start_abstime; + uint64_t ri_proc_exit_abstime; + uint64_t ri_child_user_time; + uint64_t ri_child_system_time; + uint64_t ri_child_pkg_idle_wkups; + uint64_t ri_child_interrupt_wkups; + uint64_t ri_child_pageins; + uint64_t ri_child_elapsed_abstime; + uint64_t ri_diskio_bytesread; + uint64_t ri_diskio_byteswritten; + uint64_t ri_cpu_time_qos_default; + uint64_t ri_cpu_time_qos_maintenance; + uint64_t ri_cpu_time_qos_background; + uint64_t ri_cpu_time_qos_utility; + uint64_t ri_cpu_time_qos_legacy; + uint64_t ri_cpu_time_qos_user_initiated; + uint64_t ri_cpu_time_qos_user_interactive; + uint64_t ri_billed_system_time; + uint64_t ri_serviced_system_time; + uint64_t ri_logical_writes; + uint64_t ri_lifetime_max_phys_footprint; + uint64_t ri_instructions; + uint64_t ri_cycles; + uint64_t ri_billed_energy; + uint64_t ri_serviced_energy; + uint64_t ri_interval_max_phys_footprint; + uint64_t ri_runnable_time; +}; + +struct rusage_info_v5 { + uint8_t ri_uuid[16]; + uint64_t ri_user_time; + uint64_t ri_system_time; + uint64_t ri_pkg_idle_wkups; + uint64_t ri_interrupt_wkups; + uint64_t ri_pageins; + uint64_t ri_wired_size; + uint64_t ri_resident_size; + uint64_t ri_phys_footprint; + uint64_t ri_proc_start_abstime; + uint64_t ri_proc_exit_abstime; + uint64_t ri_child_user_time; + uint64_t ri_child_system_time; + uint64_t ri_child_pkg_idle_wkups; + uint64_t ri_child_interrupt_wkups; + uint64_t ri_child_pageins; + uint64_t ri_child_elapsed_abstime; + uint64_t ri_diskio_bytesread; + uint64_t ri_diskio_byteswritten; + uint64_t ri_cpu_time_qos_default; + uint64_t ri_cpu_time_qos_maintenance; + uint64_t ri_cpu_time_qos_background; + uint64_t ri_cpu_time_qos_utility; + uint64_t ri_cpu_time_qos_legacy; + uint64_t ri_cpu_time_qos_user_initiated; + uint64_t ri_cpu_time_qos_user_interactive; + uint64_t ri_billed_system_time; + uint64_t ri_serviced_system_time; + uint64_t ri_logical_writes; + uint64_t ri_lifetime_max_phys_footprint; + uint64_t ri_instructions; + uint64_t ri_cycles; + uint64_t ri_billed_energy; + uint64_t ri_serviced_energy; + uint64_t ri_interval_max_phys_footprint; + uint64_t ri_runnable_time; + uint64_t ri_flags; +}; + +typedef struct rusage_info_v5 rusage_info_current; +# 411 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 +struct rlimit { + rlim_t rlim_cur; + rlim_t rlim_max; +}; +# 446 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 +struct proc_rlimit_control_wakeupmon { + uint32_t wm_flags; + int32_t wm_rate; +}; +# 511 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/resource.h" 3 4 +int getpriority(int, id_t); + +int getiopolicy_np(int, int) __attribute__((availability(macosx,introduced=10.5))); + +int getrlimit(int, struct rlimit *) __asm("_" "getrlimit" ); +int getrusage(int, struct rusage *); +int setpriority(int, id_t, int); + +int setiopolicy_np(int, int, int) __attribute__((availability(macosx,introduced=10.5))); + +int setrlimit(int, const struct rlimit *) __asm("_" "setrlimit" ); +# 111 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 2 3 4 +# 186 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/endian.h" 1 3 4 +# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/endian.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/endian.h" 1 3 4 +# 77 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/endian.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_endian.h" 1 3 4 +# 130 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_endian.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/_OSByteOrder.h" 1 3 4 +# 80 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/_OSByteOrder.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 1 3 4 + + + + + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/arch.h" 1 3 4 +# 10 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 2 3 4 + + + +static inline +uint16_t +_OSSwapInt16( + uint16_t _data + ) +{ + + return (uint16_t)(_data << 8 | _data >> 8); +} + +static inline +uint32_t +_OSSwapInt32( + uint32_t _data + ) +{ + + _data = __builtin_bswap32(_data); + + + + + + return _data; +} + +static inline +uint64_t +_OSSwapInt64( + uint64_t _data + ) +{ + + return __builtin_bswap64(_data); +# 60 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +} + + + +struct _OSUnalignedU16 { + volatile uint16_t __val; +} __attribute__((__packed__)); + +struct _OSUnalignedU32 { + volatile uint32_t __val; +} __attribute__((__packed__)); + +struct _OSUnalignedU64 { + volatile uint64_t __val; +} __attribute__((__packed__)); +# 87 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +static inline +uint16_t +OSReadSwapInt16( + const volatile void * _base, + uintptr_t _offset + ) +{ + return _OSSwapInt16(((struct _OSUnalignedU16 *)((uintptr_t)_base + _offset))->__val); +} +# 109 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +static inline +uint32_t +OSReadSwapInt32( + const volatile void * _base, + uintptr_t _offset + ) +{ + return _OSSwapInt32(((struct _OSUnalignedU32 *)((uintptr_t)_base + _offset))->__val); +} +# 131 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +static inline +uint64_t +OSReadSwapInt64( + const volatile void * _base, + uintptr_t _offset + ) +{ + return _OSSwapInt64(((struct _OSUnalignedU64 *)((uintptr_t)_base + _offset))->__val); +} +# 156 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +static inline +void +OSWriteSwapInt16( + volatile void * _base, + uintptr_t _offset, + uint16_t _data + ) +{ + ((struct _OSUnalignedU16 *)((uintptr_t)_base + _offset))->__val = _OSSwapInt16(_data); +} +# 180 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +static inline +void +OSWriteSwapInt32( + volatile void * _base, + uintptr_t _offset, + uint32_t _data + ) +{ + ((struct _OSUnalignedU32 *)((uintptr_t)_base + _offset))->__val = _OSSwapInt32(_data); +} +# 204 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/arm/OSByteOrder.h" 3 4 +static inline +void +OSWriteSwapInt64( + volatile void * _base, + uintptr_t _offset, + uint64_t _data + ) +{ + ((struct _OSUnalignedU64 *)((uintptr_t)_base + _offset))->__val = _OSSwapInt64(_data); +} +# 81 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/libkern/_OSByteOrder.h" 2 3 4 +# 131 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_endian.h" 2 3 4 +# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/arm/endian.h" 2 3 4 +# 38 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/machine/endian.h" 2 3 4 +# 187 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 2 3 4 + + + + + + + +union wait { + int w_status; + + + + struct { + + unsigned int w_Termsig:7, + w_Coredump:1, + w_Retcode:8, + w_Filler:16; + + + + + + + + } w_T; + + + + + + struct { + + unsigned int w_Stopval:8, + w_Stopsig:8, + w_Filler:16; + + + + + + + } w_S; +}; +# 248 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/wait.h" 3 4 +pid_t wait(int *) __asm("_" "wait" ); +pid_t waitpid(pid_t, int *, int) __asm("_" "waitpid" ); + +int waitid(idtype_t, id_t, siginfo_t *, int) __asm("_" "waitid" ); + + +pid_t wait3(int *, int, struct rusage *); +pid_t wait4(pid_t, int *, int, struct rusage *); +# 67 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/alloca.h" 1 3 4 +# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/alloca.h" 3 4 +void *alloca(size_t); +# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 + + + + + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_ct_rune_t.h" 1 3 4 +# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_ct_rune_t.h" 3 4 +typedef __darwin_ct_rune_t ct_rune_t; +# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_rune_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_rune_t.h" 3 4 +typedef __darwin_rune_t rune_t; +# 79 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_wchar_t.h" 1 3 4 +# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_wchar_t.h" 3 4 +typedef __darwin_wchar_t wchar_t; +# 82 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 + +typedef struct { + int quot; + int rem; +} div_t; + +typedef struct { + long quot; + long rem; +} ldiv_t; + + +typedef struct { + long long quot; + long long rem; +} lldiv_t; +# 118 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 3 4 +extern int __mb_cur_max; +# 128 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/malloc/_malloc.h" 1 3 4 +# 40 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/malloc/_malloc.h" 3 4 +void *malloc(size_t __size) __attribute__((__warn_unused_result__)) __attribute__((alloc_size(1))); +void *calloc(size_t __count, size_t __size) __attribute__((__warn_unused_result__)) __attribute__((alloc_size(1,2))); +void free(void *); +void *realloc(void *__ptr, size_t __size) __attribute__((__warn_unused_result__)) __attribute__((alloc_size(2))); + +void *valloc(size_t) __attribute__((alloc_size(1))); + + + + +void *aligned_alloc(size_t __alignment, size_t __size) __attribute__((__warn_unused_result__)) __attribute__((alloc_size(2))) __attribute__((availability(macosx,introduced=10.15))) __attribute__((availability(ios,introduced=13.0))) __attribute__((availability(tvos,introduced=13.0))) __attribute__((availability(watchos,introduced=6.0))); + +int posix_memalign(void **__memptr, size_t __alignment, size_t __size) __attribute__((availability(macosx,introduced=10.6))); +# 129 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 + + +void abort(void) __attribute__((__cold__)) __attribute__((__noreturn__)); +int abs(int) __attribute__((__const__)); +int atexit(void (* _Nonnull)(void)); +double atof(const char *); +int atoi(const char *); +long atol(const char *); + +long long + atoll(const char *); + +void *bsearch(const void *__key, const void *__base, size_t __nel, + size_t __width, int (* _Nonnull __compar)(const void *, const void *)); + +div_t div(int, int) __attribute__((__const__)); +void exit(int) __attribute__((__noreturn__)); + +char *getenv(const char *); +long labs(long) __attribute__((__const__)); +ldiv_t ldiv(long, long) __attribute__((__const__)); + +long long + llabs(long long); +lldiv_t lldiv(long long, long long); + + +int mblen(const char *__s, size_t __n); +size_t mbstowcs(wchar_t * restrict , const char * restrict, size_t); +int mbtowc(wchar_t * restrict, const char * restrict, size_t); + +void qsort(void *__base, size_t __nel, size_t __width, + int (* _Nonnull __compar)(const void *, const void *)); +int rand(void) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); + +void srand(unsigned) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); +double strtod(const char *, char **) __asm("_" "strtod" ); +float strtof(const char *, char **) __asm("_" "strtof" ); +long strtol(const char *__str, char **__endptr, int __base); +long double + strtold(const char *, char **); + +long long + strtoll(const char *__str, char **__endptr, int __base); + +unsigned long + strtoul(const char *__str, char **__endptr, int __base); + +unsigned long long + strtoull(const char *__str, char **__endptr, int __base); + + +__attribute__((__availability__(swift, unavailable, message="Use posix_spawn APIs or NSTask instead. (On iOS, process spawning is unavailable.)"))) +__attribute__((availability(macos,introduced=10.0))) __attribute__((availability(ios,unavailable))) +__attribute__((availability(watchos,unavailable))) __attribute__((availability(tvos,unavailable))) +int system(const char *) __asm("_" "system" ); + + +size_t wcstombs(char * restrict, const wchar_t * restrict, size_t); +int wctomb(char *, wchar_t); + + +void _Exit(int) __attribute__((__noreturn__)); +long a64l(const char *); +double drand48(void); +char *ecvt(double, int, int *restrict, int *restrict); +double erand48(unsigned short[3]); +char *fcvt(double, int, int *restrict, int *restrict); +char *gcvt(double, int, char *); +int getsubopt(char **, char * const *, char **); +int grantpt(int); + +char *initstate(unsigned, char *, size_t); + + + +long jrand48(unsigned short[3]) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); +char *l64a(long); +void lcong48(unsigned short[7]); +long lrand48(void) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); +char *mktemp(char *); +int mkstemp(char *); +long mrand48(void) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); +long nrand48(unsigned short[3]) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); +int posix_openpt(int); +char *ptsname(int); + + +int ptsname_r(int fildes, char *buffer, size_t buflen) __attribute__((availability(macos,introduced=10.13.4))) __attribute__((availability(ios,introduced=11.3))) __attribute__((availability(tvos,introduced=11.3))) __attribute__((availability(watchos,introduced=4.3))); + + +int putenv(char *) __asm("_" "putenv" ); +long random(void) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); +int rand_r(unsigned *) __attribute__((__availability__(swift, unavailable, message="Use arc4random instead."))); + +char *realpath(const char * restrict, char * restrict) __asm("_" "realpath" "$DARWIN_EXTSN"); + + + +unsigned short + *seed48(unsigned short[3]); +int setenv(const char * __name, const char * __value, int __overwrite) __asm("_" "setenv" ); + +void setkey(const char *) __asm("_" "setkey" ); + + + +char *setstate(const char *); +void srand48(long); + +void srandom(unsigned); + + + +int unlockpt(int); + +int unsetenv(const char *) __asm("_" "unsetenv" ); + + + + + + + +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_dev_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_dev_t.h" 3 4 +typedef __darwin_dev_t dev_t; +# 254 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_mode_t.h" 1 3 4 +# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_mode_t.h" 3 4 +typedef __darwin_mode_t mode_t; +# 255 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 2 3 4 + + +uint32_t arc4random(void); +void arc4random_addrandom(unsigned char * , int ) + __attribute__((availability(macosx,introduced=10.0))) __attribute__((availability(macosx,deprecated=10.12,message="use arc4random_stir"))) + __attribute__((availability(ios,introduced=2.0))) __attribute__((availability(ios,deprecated=10.0,message="use arc4random_stir"))) + __attribute__((availability(tvos,introduced=2.0))) __attribute__((availability(tvos,deprecated=10.0,message="use arc4random_stir"))) + __attribute__((availability(watchos,introduced=1.0))) __attribute__((availability(watchos,deprecated=3.0,message="use arc4random_stir"))); +void arc4random_buf(void * __buf, size_t __nbytes) __attribute__((availability(macosx,introduced=10.7))); +void arc4random_stir(void); +uint32_t + arc4random_uniform(uint32_t __upper_bound) __attribute__((availability(macosx,introduced=10.7))); + +int atexit_b(void (^ _Nonnull)(void)) __attribute__((availability(macosx,introduced=10.6))); +# 277 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 3 4 +void *bsearch_b(const void *__key, const void *__base, size_t __nel, + size_t __width, int (^ _Nonnull __compar)(const void *, const void *) __attribute__((__noescape__))) + __attribute__((availability(macosx,introduced=10.6))); + + + +char *cgetcap(char *, const char *, int); +int cgetclose(void); +int cgetent(char **, char **, const char *); +int cgetfirst(char **, char **); +int cgetmatch(const char *, const char *); +int cgetnext(char **, char **); +int cgetnum(char *, const char *, long *); +int cgetset(const char *); +int cgetstr(char *, const char *, char **); +int cgetustr(char *, const char *, char **); + +int daemon(int, int) __asm("_" "daemon" ) __attribute__((availability(macosx,introduced=10.0,deprecated=10.5,message="Use posix_spawn APIs instead."))) __attribute__((availability(watchos,unavailable))) __attribute__((availability(tvos,unavailable))); +char *devname(dev_t, mode_t); +char *devname_r(dev_t, mode_t, char *buf, int len); +char *getbsize(int *, long *); +int getloadavg(double [], int); +const char + *getprogname(void); +void setprogname(const char *); +# 311 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdlib.h" 3 4 +int heapsort(void *__base, size_t __nel, size_t __width, + int (* _Nonnull __compar)(const void *, const void *)); + +int heapsort_b(void *__base, size_t __nel, size_t __width, + int (^ _Nonnull __compar)(const void *, const void *) __attribute__((__noescape__))) + __attribute__((availability(macosx,introduced=10.6))); + +int mergesort(void *__base, size_t __nel, size_t __width, + int (* _Nonnull __compar)(const void *, const void *)); + +int mergesort_b(void *__base, size_t __nel, size_t __width, + int (^ _Nonnull __compar)(const void *, const void *) __attribute__((__noescape__))) + __attribute__((availability(macosx,introduced=10.6))); + +void psort(void *__base, size_t __nel, size_t __width, + int (* _Nonnull __compar)(const void *, const void *)) + __attribute__((availability(macosx,introduced=10.6))); + +void psort_b(void *__base, size_t __nel, size_t __width, + int (^ _Nonnull __compar)(const void *, const void *) __attribute__((__noescape__))) + __attribute__((availability(macosx,introduced=10.6))); + +void psort_r(void *__base, size_t __nel, size_t __width, void *, + int (* _Nonnull __compar)(void *, const void *, const void *)) + __attribute__((availability(macosx,introduced=10.6))); + +void qsort_b(void *__base, size_t __nel, size_t __width, + int (^ _Nonnull __compar)(const void *, const void *) __attribute__((__noescape__))) + __attribute__((availability(macosx,introduced=10.6))); + +void qsort_r(void *__base, size_t __nel, size_t __width, void *, + int (* _Nonnull __compar)(void *, const void *, const void *)); +int radixsort(const unsigned char **__base, int __nel, const unsigned char *__table, + unsigned __endbyte); +int rpmatch(const char *) + __attribute__((availability(macos,introduced=10.15))) __attribute__((availability(ios,introduced=13.0))) __attribute__((availability(tvos,introduced=13.0))) __attribute__((availability(watchos,introduced=6.0))); +int sradixsort(const unsigned char **__base, int __nel, const unsigned char *__table, + unsigned __endbyte); +void sranddev(void); +void srandomdev(void); +void *reallocf(void *__ptr, size_t __size) __attribute__((alloc_size(2))); +long long + strtonum(const char *__numstr, long long __minval, long long __maxval, const char **__errstrp) + __attribute__((availability(macos,introduced=11.0))) __attribute__((availability(ios,introduced=14.0))) __attribute__((availability(tvos,introduced=14.0))) __attribute__((availability(watchos,introduced=7.0))); + +long long + strtoq(const char *__str, char **__endptr, int __base); +unsigned long long + strtouq(const char *__str, char **__endptr, int __base); + +extern char *suboptarg; +# 21 "preprocesor_directives.c" 2 +# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/assert.h" 1 3 4 +# 82 "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/assert.h" 3 4 +void __assert_rtn(const char *, const char *, int, const char *) __attribute__((__noreturn__)) __attribute__((__cold__)) __attribute__((__disable_tail_calls__)); +# 22 "preprocesor_directives.c" 2 +# 1 "/Library/Developer/CommandLineTools/usr/lib/clang/13.1.6/include/stdbool.h" 1 3 +# 23 "preprocesor_directives.c" 2 +# 47 "preprocesor_directives.c" +int main() { + printf("LIMIT %d\n", 5); + printf("ADD(%d, %d) -> %d\n", 1, 2, ((1) + (2))); + printf("MULT(%d, %d) -> %d\n", 4+1, 8, (4+1 * (8))); + printf("MULT(%d, %d) -> %d\n", ((4) + (1)), 8, (((4) + (1)) * (8))); + + return 0; +}