classicfm-discord-bot/node_modules/sodium/out.c
2024-05-09 14:45:10 -04:00

41536 lines
1.3 MiB

# 1 "./src/crypto_pwhash_algos.cc"
# 1 "<built-in>" 1
# 1 "<built-in>" 3
# 373 "<built-in>" 3
# 1 "<command line>" 1
# 1 "<built-in>" 2
# 1 "./src/crypto_pwhash_algos.cc" 2
# 1 "./src/include/node_sodium.h" 1
# 15 "./src/include/node_sodium.h"
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdlib" 1 3
# 85 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdlib" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__config" 1 3
# 22 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__config" 3
# 327 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__config" 3
typedef __char16_t char16_t;
typedef __char32_t char32_t;
# 449 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__config" 3
namespace std {
inline namespace __1 {
}
}
# 86 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdlib" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdlib.h" 1 3
# 92 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdlib.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 1 3 4
# 61 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/Availability.h" 1 3 4
# 232 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/Availability.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/AvailabilityInternal.h" 1 3 4
# 233 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/Availability.h" 2 3 4
# 62 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/cdefs.h" 1 3 4
# 608 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/cdefs.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_symbol_aliasing.h" 1 3 4
# 609 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/cdefs.h" 2 3 4
# 674 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/cdefs.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_posix_availability.h" 1 3 4
# 675 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/cdefs.h" 2 3 4
# 63 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types.h" 1 3 4
# 27 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types.h" 1 3 4
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_types.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_types.h" 1 3 4
# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_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;
# 70 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_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;
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_types.h" 2 3 4
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types.h" 2 3 4
# 55 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_types.h" 1 3 4
# 57 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/sys/_types.h" 2 3 4
# 28 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types.h" 2 3 4
# 40 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types.h" 3 4
typedef int __darwin_nl_item;
typedef int __darwin_wctrans_t;
typedef __uint32_t __darwin_wctype_t;
# 65 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 1 3 4
# 79 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 3 4
typedef enum {
P_ALL,
P_PID,
P_PGID
} idtype_t;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_pid_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_pid_t.h" 3 4
typedef __darwin_pid_t pid_t;
# 90 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_id_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_id_t.h" 3 4
typedef __darwin_id_t id_t;
# 91 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 2 3 4
# 109 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 1 3 4
# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/appleapiopts.h" 1 3 4
# 74 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/signal.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/signal.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/signal.h" 1 3 4
# 39 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/signal.h" 3 4
typedef int sig_atomic_t;
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/signal.h" 2 3 4
# 83 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 146 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_mcontext.h" 1 3 4
# 29 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_mcontext.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_mcontext.h" 1 3 4
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_mcontext.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/machine/_structs.h" 1 3 4
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/machine/_structs.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 1 3 4
# 36 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/types.h" 1 3 4
# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 1 3 4
# 76 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int8_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int8_t.h" 3 4
typedef signed char int8_t;
# 77 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int16_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int16_t.h" 3 4
typedef short int16_t;
# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int32_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int32_t.h" 3 4
typedef int int32_t;
# 79 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int64_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_int64_t.h" 3 4
typedef long long int64_t;
# 80 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int8_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int8_t.h" 3 4
typedef unsigned char u_int8_t;
# 82 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int16_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int16_t.h" 3 4
typedef unsigned short u_int16_t;
# 83 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int32_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int32_t.h" 3 4
typedef unsigned int u_int32_t;
# 84 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int64_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int64_t.h" 3 4
typedef unsigned long long u_int64_t;
# 85 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
typedef int64_t register_t;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_intptr_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_intptr_t.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/types.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_intptr_t.h" 2 3 4
typedef __darwin_intptr_t intptr_t;
# 93 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_uintptr_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_uintptr_t.h" 3 4
typedef unsigned long uintptr_t;
# 94 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/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;
typedef u_int64_t syscall_arg_t;
# 36 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/types.h" 2 3 4
# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 2 3 4
# 46 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_i386_thread_state
{
unsigned int __eax;
unsigned int __ebx;
unsigned int __ecx;
unsigned int __edx;
unsigned int __edi;
unsigned int __esi;
unsigned int __ebp;
unsigned int __esp;
unsigned int __ss;
unsigned int __eflags;
unsigned int __eip;
unsigned int __cs;
unsigned int __ds;
unsigned int __es;
unsigned int __fs;
unsigned int __gs;
};
# 92 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_fp_control
{
unsigned short __invalid :1,
__denorm :1,
__zdiv :1,
__ovrfl :1,
__undfl :1,
__precis :1,
:2,
__pc :2,
__rc :2,
:1,
:3;
};
typedef struct __darwin_fp_control __darwin_fp_control_t;
# 150 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_fp_status
{
unsigned short __invalid :1,
__denorm :1,
__zdiv :1,
__ovrfl :1,
__undfl :1,
__precis :1,
__stkflt :1,
__errsumm :1,
__c0 :1,
__c1 :1,
__c2 :1,
__tos :3,
__c3 :1,
__busy :1;
};
typedef struct __darwin_fp_status __darwin_fp_status_t;
# 194 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_mmst_reg
{
char __mmst_reg[10];
char __mmst_rsrv[6];
};
# 213 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_xmm_reg
{
char __xmm_reg[16];
};
# 229 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_ymm_reg
{
char __ymm_reg[32];
};
# 245 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_zmm_reg
{
char __zmm_reg[64];
};
# 259 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_opmask_reg
{
char __opmask_reg[8];
};
# 281 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_i386_float_state
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
char __fpu_rsrv4[14*16];
int __fpu_reserved1;
};
struct __darwin_i386_avx_state
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
char __fpu_rsrv4[14*16];
int __fpu_reserved1;
char __avx_reserved1[64];
struct __darwin_xmm_reg __fpu_ymmh0;
struct __darwin_xmm_reg __fpu_ymmh1;
struct __darwin_xmm_reg __fpu_ymmh2;
struct __darwin_xmm_reg __fpu_ymmh3;
struct __darwin_xmm_reg __fpu_ymmh4;
struct __darwin_xmm_reg __fpu_ymmh5;
struct __darwin_xmm_reg __fpu_ymmh6;
struct __darwin_xmm_reg __fpu_ymmh7;
};
struct __darwin_i386_avx512_state
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
char __fpu_rsrv4[14*16];
int __fpu_reserved1;
char __avx_reserved1[64];
struct __darwin_xmm_reg __fpu_ymmh0;
struct __darwin_xmm_reg __fpu_ymmh1;
struct __darwin_xmm_reg __fpu_ymmh2;
struct __darwin_xmm_reg __fpu_ymmh3;
struct __darwin_xmm_reg __fpu_ymmh4;
struct __darwin_xmm_reg __fpu_ymmh5;
struct __darwin_xmm_reg __fpu_ymmh6;
struct __darwin_xmm_reg __fpu_ymmh7;
struct __darwin_opmask_reg __fpu_k0;
struct __darwin_opmask_reg __fpu_k1;
struct __darwin_opmask_reg __fpu_k2;
struct __darwin_opmask_reg __fpu_k3;
struct __darwin_opmask_reg __fpu_k4;
struct __darwin_opmask_reg __fpu_k5;
struct __darwin_opmask_reg __fpu_k6;
struct __darwin_opmask_reg __fpu_k7;
struct __darwin_ymm_reg __fpu_zmmh0;
struct __darwin_ymm_reg __fpu_zmmh1;
struct __darwin_ymm_reg __fpu_zmmh2;
struct __darwin_ymm_reg __fpu_zmmh3;
struct __darwin_ymm_reg __fpu_zmmh4;
struct __darwin_ymm_reg __fpu_zmmh5;
struct __darwin_ymm_reg __fpu_zmmh6;
struct __darwin_ymm_reg __fpu_zmmh7;
};
# 575 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_i386_exception_state
{
__uint16_t __trapno;
__uint16_t __cpu;
__uint32_t __err;
__uint32_t __faultvaddr;
};
# 595 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_x86_debug_state32
{
unsigned int __dr0;
unsigned int __dr1;
unsigned int __dr2;
unsigned int __dr3;
unsigned int __dr4;
unsigned int __dr5;
unsigned int __dr6;
unsigned int __dr7;
};
# 627 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_x86_thread_state64
{
__uint64_t __rax;
__uint64_t __rbx;
__uint64_t __rcx;
__uint64_t __rdx;
__uint64_t __rdi;
__uint64_t __rsi;
__uint64_t __rbp;
__uint64_t __rsp;
__uint64_t __r8;
__uint64_t __r9;
__uint64_t __r10;
__uint64_t __r11;
__uint64_t __r12;
__uint64_t __r13;
__uint64_t __r14;
__uint64_t __r15;
__uint64_t __rip;
__uint64_t __rflags;
__uint64_t __cs;
__uint64_t __fs;
__uint64_t __gs;
};
# 682 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_x86_float_state64
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
struct __darwin_xmm_reg __fpu_xmm8;
struct __darwin_xmm_reg __fpu_xmm9;
struct __darwin_xmm_reg __fpu_xmm10;
struct __darwin_xmm_reg __fpu_xmm11;
struct __darwin_xmm_reg __fpu_xmm12;
struct __darwin_xmm_reg __fpu_xmm13;
struct __darwin_xmm_reg __fpu_xmm14;
struct __darwin_xmm_reg __fpu_xmm15;
char __fpu_rsrv4[6*16];
int __fpu_reserved1;
};
struct __darwin_x86_avx_state64
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
struct __darwin_xmm_reg __fpu_xmm8;
struct __darwin_xmm_reg __fpu_xmm9;
struct __darwin_xmm_reg __fpu_xmm10;
struct __darwin_xmm_reg __fpu_xmm11;
struct __darwin_xmm_reg __fpu_xmm12;
struct __darwin_xmm_reg __fpu_xmm13;
struct __darwin_xmm_reg __fpu_xmm14;
struct __darwin_xmm_reg __fpu_xmm15;
char __fpu_rsrv4[6*16];
int __fpu_reserved1;
char __avx_reserved1[64];
struct __darwin_xmm_reg __fpu_ymmh0;
struct __darwin_xmm_reg __fpu_ymmh1;
struct __darwin_xmm_reg __fpu_ymmh2;
struct __darwin_xmm_reg __fpu_ymmh3;
struct __darwin_xmm_reg __fpu_ymmh4;
struct __darwin_xmm_reg __fpu_ymmh5;
struct __darwin_xmm_reg __fpu_ymmh6;
struct __darwin_xmm_reg __fpu_ymmh7;
struct __darwin_xmm_reg __fpu_ymmh8;
struct __darwin_xmm_reg __fpu_ymmh9;
struct __darwin_xmm_reg __fpu_ymmh10;
struct __darwin_xmm_reg __fpu_ymmh11;
struct __darwin_xmm_reg __fpu_ymmh12;
struct __darwin_xmm_reg __fpu_ymmh13;
struct __darwin_xmm_reg __fpu_ymmh14;
struct __darwin_xmm_reg __fpu_ymmh15;
};
struct __darwin_x86_avx512_state64
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
struct __darwin_xmm_reg __fpu_xmm8;
struct __darwin_xmm_reg __fpu_xmm9;
struct __darwin_xmm_reg __fpu_xmm10;
struct __darwin_xmm_reg __fpu_xmm11;
struct __darwin_xmm_reg __fpu_xmm12;
struct __darwin_xmm_reg __fpu_xmm13;
struct __darwin_xmm_reg __fpu_xmm14;
struct __darwin_xmm_reg __fpu_xmm15;
char __fpu_rsrv4[6*16];
int __fpu_reserved1;
char __avx_reserved1[64];
struct __darwin_xmm_reg __fpu_ymmh0;
struct __darwin_xmm_reg __fpu_ymmh1;
struct __darwin_xmm_reg __fpu_ymmh2;
struct __darwin_xmm_reg __fpu_ymmh3;
struct __darwin_xmm_reg __fpu_ymmh4;
struct __darwin_xmm_reg __fpu_ymmh5;
struct __darwin_xmm_reg __fpu_ymmh6;
struct __darwin_xmm_reg __fpu_ymmh7;
struct __darwin_xmm_reg __fpu_ymmh8;
struct __darwin_xmm_reg __fpu_ymmh9;
struct __darwin_xmm_reg __fpu_ymmh10;
struct __darwin_xmm_reg __fpu_ymmh11;
struct __darwin_xmm_reg __fpu_ymmh12;
struct __darwin_xmm_reg __fpu_ymmh13;
struct __darwin_xmm_reg __fpu_ymmh14;
struct __darwin_xmm_reg __fpu_ymmh15;
struct __darwin_opmask_reg __fpu_k0;
struct __darwin_opmask_reg __fpu_k1;
struct __darwin_opmask_reg __fpu_k2;
struct __darwin_opmask_reg __fpu_k3;
struct __darwin_opmask_reg __fpu_k4;
struct __darwin_opmask_reg __fpu_k5;
struct __darwin_opmask_reg __fpu_k6;
struct __darwin_opmask_reg __fpu_k7;
struct __darwin_ymm_reg __fpu_zmmh0;
struct __darwin_ymm_reg __fpu_zmmh1;
struct __darwin_ymm_reg __fpu_zmmh2;
struct __darwin_ymm_reg __fpu_zmmh3;
struct __darwin_ymm_reg __fpu_zmmh4;
struct __darwin_ymm_reg __fpu_zmmh5;
struct __darwin_ymm_reg __fpu_zmmh6;
struct __darwin_ymm_reg __fpu_zmmh7;
struct __darwin_ymm_reg __fpu_zmmh8;
struct __darwin_ymm_reg __fpu_zmmh9;
struct __darwin_ymm_reg __fpu_zmmh10;
struct __darwin_ymm_reg __fpu_zmmh11;
struct __darwin_ymm_reg __fpu_zmmh12;
struct __darwin_ymm_reg __fpu_zmmh13;
struct __darwin_ymm_reg __fpu_zmmh14;
struct __darwin_ymm_reg __fpu_zmmh15;
struct __darwin_zmm_reg __fpu_zmm16;
struct __darwin_zmm_reg __fpu_zmm17;
struct __darwin_zmm_reg __fpu_zmm18;
struct __darwin_zmm_reg __fpu_zmm19;
struct __darwin_zmm_reg __fpu_zmm20;
struct __darwin_zmm_reg __fpu_zmm21;
struct __darwin_zmm_reg __fpu_zmm22;
struct __darwin_zmm_reg __fpu_zmm23;
struct __darwin_zmm_reg __fpu_zmm24;
struct __darwin_zmm_reg __fpu_zmm25;
struct __darwin_zmm_reg __fpu_zmm26;
struct __darwin_zmm_reg __fpu_zmm27;
struct __darwin_zmm_reg __fpu_zmm28;
struct __darwin_zmm_reg __fpu_zmm29;
struct __darwin_zmm_reg __fpu_zmm30;
struct __darwin_zmm_reg __fpu_zmm31;
};
# 1140 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_x86_exception_state64
{
__uint16_t __trapno;
__uint16_t __cpu;
__uint32_t __err;
__uint64_t __faultvaddr;
};
# 1160 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_x86_debug_state64
{
__uint64_t __dr0;
__uint64_t __dr1;
__uint64_t __dr2;
__uint64_t __dr3;
__uint64_t __dr4;
__uint64_t __dr5;
__uint64_t __dr6;
__uint64_t __dr7;
};
# 1188 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/i386/_structs.h" 3 4
struct __darwin_x86_cpmu_state64
{
__uint64_t __ctrs[16];
};
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/mach/machine/_structs.h" 2 3 4
# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_mcontext.h" 2 3 4
struct __darwin_mcontext32
{
struct __darwin_i386_exception_state __es;
struct __darwin_i386_thread_state __ss;
struct __darwin_i386_float_state __fs;
};
struct __darwin_mcontext_avx32
{
struct __darwin_i386_exception_state __es;
struct __darwin_i386_thread_state __ss;
struct __darwin_i386_avx_state __fs;
};
struct __darwin_mcontext_avx512_32
{
struct __darwin_i386_exception_state __es;
struct __darwin_i386_thread_state __ss;
struct __darwin_i386_avx512_state __fs;
};
# 97 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_mcontext.h" 3 4
struct __darwin_mcontext64
{
struct __darwin_x86_exception_state64 __es;
struct __darwin_x86_thread_state64 __ss;
struct __darwin_x86_float_state64 __fs;
};
struct __darwin_mcontext_avx64
{
struct __darwin_x86_exception_state64 __es;
struct __darwin_x86_thread_state64 __ss;
struct __darwin_x86_avx_state64 __fs;
};
struct __darwin_mcontext_avx512_64
{
struct __darwin_x86_exception_state64 __es;
struct __darwin_x86_thread_state64 __ss;
struct __darwin_x86_avx512_state64 __fs;
};
# 156 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_mcontext.h" 3 4
typedef struct __darwin_mcontext64 *mcontext_t;
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_mcontext.h" 2 3 4
# 147 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_attr_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_attr_t.h" 3 4
typedef __darwin_pthread_attr_t pthread_attr_t;
# 149 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_sigaltstack.h" 1 3 4
# 42 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ucontext.h" 1 3 4
# 39 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ucontext.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/_mcontext.h" 1 3 4
# 40 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ucontext.h" 2 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/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_sigset_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_sigset_t.h" 3 4
typedef __darwin_sigset_t sigset_t;
# 155 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_size_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_size_t.h" 3 4
typedef __darwin_size_t size_t;
# 156 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_uid_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_uid_t.h" 3 4
typedef __darwin_uid_t uid_t;
# 157 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/sys/signal.h" 3 4
typedef void (*sig_t)(int);
# 348 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/sys/signal.h" 3 4
struct sigstack {
char *ss_sp;
int ss_onstack;
};
# 389 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/signal.h" 3 4
extern "C" {
void (*signal(int, void (*)(int)))(int);
}
# 110 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 1 3 4
# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 3 4
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdint.h" 1 3 4
# 106 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdint.h" 3
# 119 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdint.h" 3
# 1 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stdint.h" 1 3 4
# 63 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stdint.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 1 3 4
# 23 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint8_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint8_t.h" 3 4
typedef unsigned char uint8_t;
# 24 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint16_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint16_t.h" 3 4
typedef unsigned short uint16_t;
# 25 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint32_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint32_t.h" 3 4
typedef unsigned int uint32_t;
# 26 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint64_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uint64_t.h" 3 4
typedef unsigned long long uint64_t;
# 27 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/stdint.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_intmax_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_intmax_t.h" 3 4
typedef long int intmax_t;
# 59 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uintmax_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_uintmax_t.h" 3 4
typedef long unsigned int uintmax_t;
# 60 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdint.h" 2 3 4
# 64 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stdint.h" 2 3 4
# 120 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdint.h" 2 3
# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_timeval.h" 1 3 4
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/sys/resource.h" 2 3 4
typedef __uint64_t rlim_t;
# 152 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 3 4
struct rusage {
struct timeval ru_utime;
struct timeval ru_stime;
# 163 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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;
};
# 193 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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_unused[1];
};
typedef struct rusage_info_v4 rusage_info_current;
# 366 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 3 4
struct rlimit {
rlim_t rlim_cur;
rlim_t rlim_max;
};
# 401 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 3 4
struct proc_rlimit_control_wakeupmon {
uint32_t wm_flags;
int32_t wm_rate;
};
# 436 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/resource.h" 3 4
extern "C" {
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/MacOSX10.14.sdk/usr/include/sys/wait.h" 2 3 4
# 186 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/endian.h" 1 3 4
# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/endian.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/endian.h" 1 3 4
# 99 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/endian.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_endian.h" 1 3 4
# 130 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_endian.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/libkern/_OSByteOrder.h" 1 3 4
# 66 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/libkern/_OSByteOrder.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/libkern/i386/_OSByteOrder.h" 1 3 4
# 44 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/libkern/i386/_OSByteOrder.h" 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
)
{
return __builtin_bswap32(_data);
}
static inline
__uint64_t
_OSSwapInt64(
__uint64_t _data
)
{
return __builtin_bswap64(_data);
}
# 67 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/libkern/_OSByteOrder.h" 2 3 4
# 131 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_endian.h" 2 3 4
# 100 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/endian.h" 2 3 4
# 36 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/endian.h" 2 3 4
# 187 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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;
};
# 247 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/wait.h" 3 4
extern "C" {
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/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/alloca.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/alloca.h" 3 4
extern "C" {
void *alloca(size_t);
}
# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ct_rune_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ct_rune_t.h" 3 4
typedef __darwin_ct_rune_t ct_rune_t;
# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_rune_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_rune_t.h" 3 4
typedef __darwin_rune_t rune_t;
# 79 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_wchar_t.h" 1 3 4
# 82 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_null.h" 1 3 4
# 101 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 118 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 3 4
extern int __mb_cur_max;
# 128 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/malloc/_malloc.h" 1 3 4
# 38 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/malloc/_malloc.h" 3 4
extern "C" {
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)));
int posix_memalign(void **__memptr, size_t __alignment, size_t __size) __attribute__((availability(macosx,introduced=10.6)));
}
# 129 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
extern "C" {
void abort(void) __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 * , const char * , size_t);
int mbtowc(wchar_t * , const char * , 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);
# 187 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 3 4
__attribute__((__availability__(swift, unavailable, message="Use posix_spawn APIs or NSTask instead.")))
__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 * , const wchar_t * , size_t);
int wctomb(char *, wchar_t);
void _Exit(int) __attribute__((noreturn));
long a64l(const char *);
double drand48(void);
char *ecvt(double, int, int *, int *);
double erand48(unsigned short[3]);
char *fcvt(double, int, int *, int *);
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 * , char * ) __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" );
# 261 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_dev_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_dev_t.h" 3 4
typedef __darwin_dev_t dev_t;
# 262 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdlib.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_mode_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_mode_t.h" 3 4
typedef __darwin_mode_t mode_t;
# 263 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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)));
void *bsearch_b(const void *__key, const void *__base, size_t __nel,
size_t __width, int (^ _Nonnull __compar)(const void *, const void *)) __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" "$1050") __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);
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__((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__((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__((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__((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);
void setprogname(const char *);
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
strtoq(const char *__str, char **__endptr, int __base);
unsigned long long
strtouq(const char *__str, char **__endptr, int __base);
extern char *suboptarg;
}
# 95 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdlib.h" 2 3
extern "C++" {
# 111 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdlib.h" 3
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) long abs( long __x) throw() {return labs(__x);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) long long abs(long long __x) throw() {return llabs(__x);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) ldiv_t div( long __x, long __y) throw() {return ldiv(__x, __y);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) lldiv_t div(long long __x, long long __y) throw() {return lldiv(__x, __y);}
}
# 87 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdlib" 2 3
# 90 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdlib" 3
namespace std {inline namespace __1 {
using ::size_t;
using ::div_t;
using ::ldiv_t;
using ::lldiv_t;
using ::atof;
using ::atoi;
using ::atol;
using ::atoll;
using ::strtod;
using ::strtof;
using ::strtold;
using ::strtol;
using ::strtoll;
using ::strtoul;
using ::strtoull;
using ::rand;
using ::srand;
using ::calloc;
using ::free;
using ::malloc;
using ::realloc;
using ::abort;
using ::atexit;
using ::exit;
using ::_Exit;
using ::getenv;
using ::system;
using ::bsearch;
using ::qsort;
using ::abs;
using ::labs;
using ::llabs;
using ::div;
using ::ldiv;
using ::lldiv;
using ::mblen;
using ::mbtowc;
using ::wctomb;
using ::mbstowcs;
using ::wcstombs;
# 162 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdlib" 3
} }
# 16 "./src/include/node_sodium.h" 2
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctime" 1 3
# 48 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctime" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 1 3 4
# 68 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_clock_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_clock_t.h" 3 4
typedef __darwin_clock_t clock_t;
# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_time_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_time_t.h" 3 4
typedef __darwin_time_t time_t;
# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_timespec.h" 1 3 4
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_timespec.h" 3 4
struct timespec
{
__darwin_time_t tv_sec;
long tv_nsec;
};
# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 2 3 4
struct tm {
int tm_sec;
int tm_min;
int tm_hour;
int tm_mday;
int tm_mon;
int tm_year;
int tm_wday;
int tm_yday;
int tm_isdst;
long tm_gmtoff;
char *tm_zone;
};
# 97 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 3 4
extern char *tzname[];
extern int getdate_err;
extern long timezone __asm("_" "timezone" );
extern int daylight;
extern "C" {
char *asctime(const struct tm *);
clock_t clock(void) __asm("_" "clock" );
char *ctime(const time_t *);
double difftime(time_t, time_t);
struct tm *getdate(const char *);
struct tm *gmtime(const time_t *);
struct tm *localtime(const time_t *);
time_t mktime(struct tm *) __asm("_" "mktime" );
size_t strftime(char * , size_t, const char * , const struct tm * ) __asm("_" "strftime" );
char *strptime(const char * , const char * , struct tm * ) __asm("_" "strptime" );
time_t time(time_t *);
void tzset(void);
char *asctime_r(const struct tm * , char * );
char *ctime_r(const time_t *, char *);
struct tm *gmtime_r(const time_t * , struct tm * );
struct tm *localtime_r(const time_t * , struct tm * );
time_t posix2time(time_t);
void tzsetwall(void);
time_t time2posix(time_t);
time_t timelocal(struct tm * const);
time_t timegm(struct tm * const);
int nanosleep(const struct timespec *__rqtp, struct timespec *__rmtp) __asm("_" "nanosleep" );
# 152 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/time.h" 3 4
typedef enum {
_CLOCK_REALTIME __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 0,
_CLOCK_MONOTONIC __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 6,
_CLOCK_MONOTONIC_RAW __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 4,
_CLOCK_MONOTONIC_RAW_APPROX __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 5,
_CLOCK_UPTIME_RAW __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 8,
_CLOCK_UPTIME_RAW_APPROX __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 9,
_CLOCK_PROCESS_CPUTIME_ID __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 12,
_CLOCK_THREAD_CPUTIME_ID __attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0))) = 16
} clockid_t;
__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 clock_getres(clockid_t __clock_id, struct timespec *__res);
__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 clock_gettime(clockid_t __clock_id, struct timespec *__tp);
__attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,introduced=10.0))) __attribute__((availability(tvos,introduced=10.0))) __attribute__((availability(watchos,introduced=3.0)))
__uint64_t clock_gettime_nsec_np(clockid_t __clock_id);
__attribute__((availability(macosx,introduced=10.12))) __attribute__((availability(ios,unavailable)))
__attribute__((availability(tvos,unavailable))) __attribute__((availability(watchos,unavailable)))
int clock_settime(clockid_t __clock_id, const struct timespec *__tp);
}
# 49 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctime" 2 3
# 52 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctime" 3
namespace std {inline namespace __1 {
using ::clock_t;
using ::size_t;
using ::time_t;
using ::tm;
using ::clock;
using ::difftime;
using ::mktime;
using ::time;
using ::asctime;
using ::ctime;
using ::gmtime;
using ::localtime;
using ::strftime;
} }
# 17 "./src/include/node_sodium.h" 2
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstring" 1 3
# 61 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstring" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string.h" 1 3
# 59 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 1 3 4
# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 3 4
extern "C" {
void *memchr(const void *__s, int __c, size_t __n);
int memcmp(const void *__s1, const void *__s2, size_t __n);
void *memcpy(void *__dst, const void *__src, size_t __n);
void *memmove(void *__dst, const void *__src, size_t __len);
void *memset(void *__b, int __c, size_t __len);
char *strcat(char *__s1, const char *__s2);
char *strchr(const char *__s, int __c);
int strcmp(const char *__s1, const char *__s2);
int strcoll(const char *__s1, const char *__s2);
char *strcpy(char *__dst, const char *__src);
size_t strcspn(const char *__s, const char *__charset);
char *strerror(int __errnum) __asm("_" "strerror" );
size_t strlen(const char *__s);
char *strncat(char *__s1, const char *__s2, size_t __n);
int strncmp(const char *__s1, const char *__s2, size_t __n);
char *strncpy(char *__dst, const char *__src, size_t __n);
char *strpbrk(const char *__s, const char *__charset);
char *strrchr(const char *__s, int __c);
size_t strspn(const char *__s, const char *__charset);
char *strstr(const char *__big, const char *__little);
char *strtok(char *__str, const char *__sep);
size_t strxfrm(char *__s1, const char *__s2, size_t __n);
}
# 103 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 3 4
extern "C" {
char *strtok_r(char *__str, const char *__sep, char **__lasts);
}
# 115 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 3 4
extern "C" {
int strerror_r(int __errnum, char *__strerrbuf, size_t __buflen);
char *strdup(const char *__s1);
void *memccpy(void *__dst, const void *__src, int __c, size_t __n);
}
# 129 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 3 4
extern "C" {
char *stpcpy(char *__dst, const char *__src);
char *stpncpy(char *__dst, const char *__src, size_t __n) __attribute__((availability(macosx,introduced=10.7)));
char *strndup(const char *__s1, size_t __n) __attribute__((availability(macosx,introduced=10.7)));
size_t strnlen(const char *__s1, size_t __n) __attribute__((availability(macosx,introduced=10.7)));
char *strsignal(int __sig);
}
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_rsize_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_rsize_t.h" 3 4
typedef __darwin_size_t rsize_t;
# 142 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_errno_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_errno_t.h" 3 4
typedef int errno_t;
# 143 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 2 3 4
extern "C" {
errno_t memset_s(void *__s, rsize_t __smax, int __c, rsize_t __n) __attribute__((availability(macosx,introduced=10.9)));
}
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ssize_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ssize_t.h" 3 4
typedef __darwin_ssize_t ssize_t;
# 153 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 2 3 4
extern "C" {
void *memmem(const void *__big, size_t __big_len, const void *__little, size_t __little_len) __attribute__((availability(macosx,introduced=10.7)));
void memset_pattern4(void *__b, const void *__pattern4, size_t __len) __attribute__((availability(macosx,introduced=10.5)));
void memset_pattern8(void *__b, const void *__pattern8, size_t __len) __attribute__((availability(macosx,introduced=10.5)));
void memset_pattern16(void *__b, const void *__pattern16, size_t __len) __attribute__((availability(macosx,introduced=10.5)));
char *strcasestr(const char *__big, const char *__little);
char *strnstr(const char *__big, const char *__little, size_t __len);
size_t strlcat(char *__dst, const char *__source, size_t __size);
size_t strlcpy(char *__dst, const char *__source, size_t __size);
void strmode(int __mode, char *__bp);
char *strsep(char **__stringp, const char *__delim);
void swab(const void * , void * , ssize_t);
__attribute__((availability(macosx,introduced=10.12.1))) __attribute__((availability(ios,introduced=10.1)))
__attribute__((availability(tvos,introduced=10.0.1))) __attribute__((availability(watchos,introduced=3.1)))
int timingsafe_bcmp(const void *__b1, const void *__b2, size_t __len);
}
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/strings.h" 1 3 4
# 67 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/strings.h" 3 4
extern "C" {
int bcmp(const void *, const void *, size_t) ;
void bcopy(const void *, void *, size_t) ;
void bzero(void *, size_t) ;
char *index(const char *, int) ;
char *rindex(const char *, int) ;
int ffs(int);
int strcasecmp(const char *, const char *);
int strncasecmp(const char *, const char *, size_t);
}
extern "C" {
int ffsl(long) __attribute__((availability(macosx,introduced=10.5)));
int ffsll(long long) __attribute__((availability(macosx,introduced=10.9)));
int fls(int) __attribute__((availability(macosx,introduced=10.5)));
int flsl(long) __attribute__((availability(macosx,introduced=10.5)));
int flsll(long long) __attribute__((availability(macosx,introduced=10.9)));
}
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string.h" 1 3 4
# 93 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/strings.h" 2 3 4
# 181 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/string.h" 2 3 4
# 62 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string.h" 2 3
# 72 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string.h" 3
extern "C++" {
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
char* __libcpp_strchr(const char* __s, int __c) {return (char*)strchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const char* strchr(const char* __s, int __c) {return __libcpp_strchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
char* strchr( char* __s, int __c) {return __libcpp_strchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
char* __libcpp_strpbrk(const char* __s1, const char* __s2) {return (char*)strpbrk(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const char* strpbrk(const char* __s1, const char* __s2) {return __libcpp_strpbrk(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
char* strpbrk( char* __s1, const char* __s2) {return __libcpp_strpbrk(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
char* __libcpp_strrchr(const char* __s, int __c) {return (char*)strrchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const char* strrchr(const char* __s, int __c) {return __libcpp_strrchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
char* strrchr( char* __s, int __c) {return __libcpp_strrchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void* __libcpp_memchr(const void* __s, int __c, size_t __n) {return (void*)memchr(__s, __c, __n);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const void* memchr(const void* __s, int __c, size_t __n) {return __libcpp_memchr(__s, __c, __n);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
void* memchr( void* __s, int __c, size_t __n) {return __libcpp_memchr(__s, __c, __n);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
char* __libcpp_strstr(const char* __s1, const char* __s2) {return (char*)strstr(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const char* strstr(const char* __s1, const char* __s2) {return __libcpp_strstr(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
char* strstr( char* __s1, const char* __s2) {return __libcpp_strstr(__s1, __s2);}
}
# 62 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstring" 2 3
# 65 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstring" 3
namespace std {inline namespace __1 {
using ::size_t;
using ::memcpy;
using ::memmove;
using ::strcpy;
using ::strncpy;
using ::strcat;
using ::strncat;
using ::memcmp;
using ::strcmp;
using ::strncmp;
using ::strcoll;
using ::strxfrm;
using ::memchr;
using ::strchr;
using ::strcspn;
using ::strpbrk;
using ::strrchr;
using ::strspn;
using ::strstr;
using ::strtok;
using ::memset;
using ::strerror;
using ::strlen;
} }
# 18 "./src/include/node_sodium.h" 2
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 1 3
# 477 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 1 3
# 176 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 1 3
# 56 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 1 3
# 639 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/initializer_list" 1 3
# 47 "/Library/Developer/CommandLineTools/usr/include/c++/v1/initializer_list" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstddef" 1 3
# 41 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstddef" 3
# 1 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stddef.h" 1 3 4
# 51 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stddef.h" 3 4
typedef long int ptrdiff_t;
# 45 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstddef" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__nullptr" 1 3
# 18 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__nullptr" 3
namespace std {inline namespace __1 {
struct __attribute__ ((__type_visibility__("default"))) nullptr_t
{
void* __lx;
struct __nat {int __for_bool_;};
__attribute__ ((__visibility__("hidden"), __always_inline__)) nullptr_t() : __lx(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) nullptr_t(int __nat::*) : __lx(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator int __nat::*() const {return 0;}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator _Tp* () const {return 0;}
template <class _Tp, class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator _Tp _Up::* () const {return 0;}
friend __attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator==(nullptr_t, nullptr_t) {return true;}
friend __attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator!=(nullptr_t, nullptr_t) {return false;}
};
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) nullptr_t __get_nullptr_t() {return nullptr_t(0);}
} }
# 46 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstddef" 2 3
namespace std {inline namespace __1 {
using ::ptrdiff_t;
using ::size_t;
typedef long double max_align_t;
} }
# 48 "/Library/Developer/CommandLineTools/usr/include/c++/v1/initializer_list" 2 3
# 51 "/Library/Developer/CommandLineTools/usr/include/c++/v1/initializer_list" 3
namespace std
{
# 116 "/Library/Developer/CommandLineTools/usr/include/c++/v1/initializer_list" 3
}
# 640 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 1 3
# 406 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
namespace std {inline namespace __1 {
template <class _T1, class _T2> struct __attribute__ ((__type_visibility__("default"))) pair;
template <class _Tp> class __attribute__ ((__type_visibility__("default"))) reference_wrapper;
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) hash;
template <class>
struct __void_t { typedef void type; };
template <class _Tp>
struct __identity { typedef _Tp type; };
template <class _Tp, bool>
struct __attribute__ ((__type_visibility__("default"))) __dependent_type : public _Tp {};
template <bool _Bp, class _If, class _Then>
struct __attribute__ ((__type_visibility__("default"))) conditional {typedef _If type;};
template <class _If, class _Then>
struct __attribute__ ((__type_visibility__("default"))) conditional<false, _If, _Then> {typedef _Then type;};
template <bool, class _Tp> struct __attribute__ ((__type_visibility__("default"))) __lazy_enable_if {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) __lazy_enable_if<true, _Tp> {typedef typename _Tp::type type;};
template <bool, class _Tp = void> struct __attribute__ ((__type_visibility__("default"))) enable_if {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) enable_if<true, _Tp> {typedef _Tp type;};
# 445 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
inline
__attribute__((__no_sanitize__("cfi"))) __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
addressof(_Tp& __x) throw()
{
return __builtin_addressof(__x);
}
# 511 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
struct __two {char __lx[2];};
template <class _Tp, _Tp __v>
struct __attribute__ ((__type_visibility__("default"))) integral_constant
{
static const _Tp value = __v;
typedef _Tp value_type;
typedef integral_constant type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator value_type() const throw() {return value;}
};
template <class _Tp, _Tp __v>
const _Tp integral_constant<_Tp, __v>::value;
# 540 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
typedef integral_constant<bool,(true)> true_type;
typedef integral_constant<bool,(false)> false_type;
# 622 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_const : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_const<_Tp const> : public true_type {};
# 633 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_volatile : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_volatile<_Tp volatile> : public true_type {};
# 644 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_const {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_const<const _Tp> {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_volatile {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_volatile<volatile _Tp> {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_cv
{typedef typename remove_volatile<typename remove_const<_Tp>::type>::type type;};
template <class _Tp> struct __libcpp_is_void : public false_type {};
template <> struct __libcpp_is_void<void> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_void
: public __libcpp_is_void<typename remove_cv<_Tp>::type> {};
# 682 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __is_nullptr_t_impl : public false_type {};
template <> struct __is_nullptr_t_impl<nullptr_t> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) __is_nullptr_t
: public __is_nullptr_t_impl<typename remove_cv<_Tp>::type> {};
# 701 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __libcpp_is_integral : public false_type {};
template <> struct __libcpp_is_integral<bool> : public true_type {};
template <> struct __libcpp_is_integral<char> : public true_type {};
template <> struct __libcpp_is_integral<signed char> : public true_type {};
template <> struct __libcpp_is_integral<unsigned char> : public true_type {};
template <> struct __libcpp_is_integral<wchar_t> : public true_type {};
template <> struct __libcpp_is_integral<char16_t> : public true_type {};
template <> struct __libcpp_is_integral<char32_t> : public true_type {};
template <> struct __libcpp_is_integral<short> : public true_type {};
template <> struct __libcpp_is_integral<unsigned short> : public true_type {};
template <> struct __libcpp_is_integral<int> : public true_type {};
template <> struct __libcpp_is_integral<unsigned int> : public true_type {};
template <> struct __libcpp_is_integral<long> : public true_type {};
template <> struct __libcpp_is_integral<unsigned long> : public true_type {};
template <> struct __libcpp_is_integral<long long> : public true_type {};
template <> struct __libcpp_is_integral<unsigned long long> : public true_type {};
template <> struct __libcpp_is_integral<__int128_t> : public true_type {};
template <> struct __libcpp_is_integral<__uint128_t> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_integral
: public __libcpp_is_integral<typename remove_cv<_Tp>::type> {};
# 735 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __libcpp_is_floating_point : public false_type {};
template <> struct __libcpp_is_floating_point<float> : public true_type {};
template <> struct __libcpp_is_floating_point<double> : public true_type {};
template <> struct __libcpp_is_floating_point<long double> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_floating_point
: public __libcpp_is_floating_point<typename remove_cv<_Tp>::type> {};
# 751 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_array
: public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_array<_Tp[]>
: public true_type {};
template <class _Tp, size_t _Np> struct __attribute__ ((__type_visibility__("default"))) is_array<_Tp[_Np]>
: public true_type {};
# 766 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __libcpp_is_pointer : public false_type {};
template <class _Tp> struct __libcpp_is_pointer<_Tp*> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_pointer
: public __libcpp_is_pointer<typename remove_cv<_Tp>::type> {};
# 780 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_lvalue_reference : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_lvalue_reference<_Tp&> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_rvalue_reference : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_reference : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_reference<_Tp&> : public true_type {};
# 811 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_union
: public integral_constant<bool, __is_union(_Tp)> {};
# 832 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_class
: public integral_constant<bool, __is_class(_Tp)> {};
# 856 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class _Up> struct __attribute__ ((__type_visibility__("default"))) is_same : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_same<_Tp, _Tp> : public true_type {};
# 867 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
namespace __libcpp_is_function_imp
{
struct __dummy_type {};
template <class _Tp> char __test(_Tp*);
template <class _Tp> char __test(__dummy_type);
template <class _Tp> __two __test(...);
template <class _Tp> _Tp& __source(int);
template <class _Tp> __dummy_type __source(...);
}
template <class _Tp, bool = is_class<_Tp>::value ||
is_union<_Tp>::value ||
is_void<_Tp>::value ||
is_reference<_Tp>::value ||
__is_nullptr_t<_Tp>::value >
struct __libcpp_is_function
: public integral_constant<bool, sizeof(__libcpp_is_function_imp::__test<_Tp>(__libcpp_is_function_imp::__source<_Tp>(0))) == 1>
{};
template <class _Tp> struct __libcpp_is_function<_Tp, true> : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_function
: public __libcpp_is_function<_Tp> {};
# 902 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _MP, bool _IsMemberFunctionPtr, bool _IsMemberObjectPtr>
struct __member_pointer_traits_imp
{
};
template <class _Tp> struct __libcpp_is_member_function_pointer
: public false_type {};
template <class _Ret, class _Class>
struct __libcpp_is_member_function_pointer<_Ret _Class::*>
: public is_function<_Ret> {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_member_function_pointer
: public __libcpp_is_member_function_pointer<typename remove_cv<_Tp>::type>::type {};
# 926 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __libcpp_is_member_pointer : public false_type {};
template <class _Tp, class _Up> struct __libcpp_is_member_pointer<_Tp _Up::*> : public true_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_member_pointer
: public __libcpp_is_member_pointer<typename remove_cv<_Tp>::type> {};
# 940 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_member_object_pointer
: public integral_constant<bool, is_member_pointer<_Tp>::value &&
!is_member_function_pointer<_Tp>::value> {};
# 954 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_enum
: public integral_constant<bool, __is_enum(_Tp)> {};
# 981 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_arithmetic
: public integral_constant<bool, is_integral<_Tp>::value ||
is_floating_point<_Tp>::value> {};
# 993 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_fundamental
: public integral_constant<bool, is_void<_Tp>::value ||
__is_nullptr_t<_Tp>::value ||
is_arithmetic<_Tp>::value> {};
# 1006 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_scalar
: public integral_constant<bool, is_arithmetic<_Tp>::value ||
is_member_pointer<_Tp>::value ||
is_pointer<_Tp>::value ||
__is_nullptr_t<_Tp>::value ||
is_enum<_Tp>::value > {};
template <> struct __attribute__ ((__type_visibility__("default"))) is_scalar<nullptr_t> : public true_type {};
# 1023 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_object
: public integral_constant<bool, is_scalar<_Tp>::value ||
is_array<_Tp>::value ||
is_union<_Tp>::value ||
is_class<_Tp>::value > {};
# 1037 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_compound
: public integral_constant<bool, !is_fundamental<_Tp>::value> {};
# 1049 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
struct __is_referenceable_impl {
template <class _Tp> static _Tp& __test(int);
template <class _Tp> static __two __test(...);
};
template <class _Tp>
struct __is_referenceable : integral_constant<bool,
!is_same<__decltype(__is_referenceable_impl::__test<_Tp>(0)), __two>::value> {};
template <class _Tp, bool = is_reference<_Tp>::value ||
is_function<_Tp>::value ||
is_const<_Tp>::value >
struct __add_const {typedef _Tp type;};
template <class _Tp>
struct __add_const<_Tp, false> {typedef const _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) add_const
{typedef typename __add_const<_Tp>::type type;};
template <class _Tp, bool = is_reference<_Tp>::value ||
is_function<_Tp>::value ||
is_volatile<_Tp>::value >
struct __add_volatile {typedef _Tp type;};
template <class _Tp>
struct __add_volatile<_Tp, false> {typedef volatile _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) add_volatile
{typedef typename __add_volatile<_Tp>::type type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) add_cv
{typedef typename add_const<typename add_volatile<_Tp>::type>::type type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_reference {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_reference<_Tp&> {typedef _Tp type;};
# 1116 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, bool = __is_referenceable<_Tp>::value> struct __add_lvalue_reference_impl { typedef _Tp type; };
template <class _Tp > struct __add_lvalue_reference_impl<_Tp, true> { typedef _Tp& type; };
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) add_lvalue_reference
{typedef typename __add_lvalue_reference_impl<_Tp>::type type;};
# 1151 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
typename add_lvalue_reference<_Tp>::type
declval();
template <class _Tp>
struct __uncvref {
typedef typename remove_cv<typename remove_reference<_Tp>::type>::type type;
};
template <class _Tp>
struct __unconstref {
typedef typename remove_const<typename remove_reference<_Tp>::type>::type type;
};
# 1176 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class _Up>
struct __is_same_uncvref : is_same<typename __uncvref<_Tp>::type,
typename __uncvref<_Up>::type> {};
# 1191 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
struct __any
{
__any(...);
};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_pointer {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_pointer<_Tp*> {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_pointer<_Tp* const> {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_pointer<_Tp* volatile> {typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_pointer<_Tp* const volatile> {typedef _Tp type;};
template <class _Tp,
bool = __is_referenceable<_Tp>::value ||
is_same<typename remove_cv<_Tp>::type, void>::value>
struct __add_pointer_impl
{typedef typename remove_reference<_Tp>::type* type;};
template <class _Tp> struct __add_pointer_impl<_Tp, false>
{typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) add_pointer
{typedef typename __add_pointer_impl<_Tp>::type type;};
template <class _Tp, bool = is_integral<_Tp>::value>
struct __libcpp_is_signed_impl : public integral_constant<bool,(_Tp(-1) < _Tp(0))> {};
template <class _Tp>
struct __libcpp_is_signed_impl<_Tp, false> : public true_type {};
template <class _Tp, bool = is_arithmetic<_Tp>::value>
struct __libcpp_is_signed : public __libcpp_is_signed_impl<_Tp> {};
template <class _Tp> struct __libcpp_is_signed<_Tp, false> : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_signed : public __libcpp_is_signed<_Tp> {};
# 1248 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, bool = is_integral<_Tp>::value>
struct __libcpp_is_unsigned_impl : public integral_constant<bool,(_Tp(0) < _Tp(-1))> {};
template <class _Tp>
struct __libcpp_is_unsigned_impl<_Tp, false> : public false_type {};
template <class _Tp, bool = is_arithmetic<_Tp>::value>
struct __libcpp_is_unsigned : public __libcpp_is_unsigned_impl<_Tp> {};
template <class _Tp> struct __libcpp_is_unsigned<_Tp, false> : public false_type {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_unsigned : public __libcpp_is_unsigned<_Tp> {};
# 1269 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) rank
: public integral_constant<size_t, 0> {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) rank<_Tp[]>
: public integral_constant<size_t, rank<_Tp>::value + 1> {};
template <class _Tp, size_t _Np> struct __attribute__ ((__type_visibility__("default"))) rank<_Tp[_Np]>
: public integral_constant<size_t, rank<_Tp>::value + 1> {};
# 1284 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, unsigned _Ip = 0> struct __attribute__ ((__type_visibility__("default"))) extent
: public integral_constant<size_t, 0> {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) extent<_Tp[], 0>
: public integral_constant<size_t, 0> {};
template <class _Tp, unsigned _Ip> struct __attribute__ ((__type_visibility__("default"))) extent<_Tp[], _Ip>
: public integral_constant<size_t, extent<_Tp, _Ip-1>::value> {};
template <class _Tp, size_t _Np> struct __attribute__ ((__type_visibility__("default"))) extent<_Tp[_Np], 0>
: public integral_constant<size_t, _Np> {};
template <class _Tp, size_t _Np, unsigned _Ip> struct __attribute__ ((__type_visibility__("default"))) extent<_Tp[_Np], _Ip>
: public integral_constant<size_t, extent<_Tp, _Ip-1>::value> {};
# 1303 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_extent
{typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_extent<_Tp[]>
{typedef _Tp type;};
template <class _Tp, size_t _Np> struct __attribute__ ((__type_visibility__("default"))) remove_extent<_Tp[_Np]>
{typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_all_extents
{typedef _Tp type;};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) remove_all_extents<_Tp[]>
{typedef typename remove_all_extents<_Tp>::type type;};
template <class _Tp, size_t _Np> struct __attribute__ ((__type_visibility__("default"))) remove_all_extents<_Tp[_Np]>
{typedef typename remove_all_extents<_Tp>::type type;};
template <class _Up, bool>
struct __decay {
typedef typename remove_cv<_Up>::type type;
};
template <class _Up>
struct __decay<_Up, true> {
public:
typedef typename conditional
<
is_array<_Up>::value,
typename remove_extent<_Up>::type*,
typename conditional
<
is_function<_Up>::value,
typename add_pointer<_Up>::type,
typename remove_cv<_Up>::type
>::type
>::type type;
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) decay
{
private:
typedef typename remove_reference<_Tp>::type _Up;
public:
typedef typename __decay<_Up, __is_referenceable<_Up>::value>::type type;
};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_abstract
: public integral_constant<bool, __is_abstract(_Tp)> {};
# 1377 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default")))
__libcpp_is_final : public integral_constant<bool, __is_final(_Tp)> {};
# 1413 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Bp, class _Dp>
struct __attribute__ ((__type_visibility__("default"))) is_base_of
: public integral_constant<bool, __is_base_of(_Bp, _Dp)> {};
# 1454 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _T1, class _T2> struct __attribute__ ((__type_visibility__("default"))) is_convertible
: public integral_constant<bool, __is_convertible_to(_T1, _T2) &&
!is_abstract<_T2>::value> {};
# 1545 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_empty
: public integral_constant<bool, __is_empty(_Tp)> {};
# 1582 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_polymorphic
: public integral_constant<bool, __is_polymorphic(_Tp)> {};
# 1608 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) has_virtual_destructor
: public integral_constant<bool, __has_virtual_destructor(_Tp)> {};
# 1642 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) alignment_of
: public integral_constant<size_t, __alignof__(_Tp)> {};
# 1653 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Hp, class _Tp>
struct __type_list
{
typedef _Hp _Head;
typedef _Tp _Tail;
};
struct __nat
{
};
template <class _Tp>
struct __align_type
{
static const size_t value = alignment_of<_Tp>::value;
typedef _Tp type;
};
struct __struct_double {long double __lx;};
struct __struct_double4 {double __lx[4];};
typedef
__type_list<__align_type<unsigned char>,
__type_list<__align_type<unsigned short>,
__type_list<__align_type<unsigned int>,
__type_list<__align_type<unsigned long>,
__type_list<__align_type<unsigned long long>,
__type_list<__align_type<double>,
__type_list<__align_type<long double>,
__type_list<__align_type<__struct_double>,
__type_list<__align_type<__struct_double4>,
__type_list<__align_type<int*>,
__nat
> > > > > > > > > > __all_types;
template <class _TL, size_t _Align> struct __find_pod;
template <class _Hp, size_t _Align>
struct __find_pod<__type_list<_Hp, __nat>, _Align>
{
typedef typename conditional<
_Align == _Hp::value,
typename _Hp::type,
void
>::type type;
};
template <class _Hp, class _Tp, size_t _Align>
struct __find_pod<__type_list<_Hp, _Tp>, _Align>
{
typedef typename conditional<
_Align == _Hp::value,
typename _Hp::type,
typename __find_pod<_Tp, _Align>::type
>::type type;
};
template <class _TL, size_t _Len> struct __find_max_align;
template <class _Hp, size_t _Len>
struct __find_max_align<__type_list<_Hp, __nat>, _Len> : public integral_constant<size_t, _Hp::value> {};
template <size_t _Len, size_t _A1, size_t _A2>
struct __select_align
{
private:
static const size_t __min = _A2 < _A1 ? _A2 : _A1;
static const size_t __max = _A1 < _A2 ? _A2 : _A1;
public:
static const size_t value = _Len < __max ? __min : __max;
};
template <class _Hp, class _Tp, size_t _Len>
struct __find_max_align<__type_list<_Hp, _Tp>, _Len>
: public integral_constant<size_t, __select_align<_Len, _Hp::value, __find_max_align<_Tp, _Len>::value>::value> {};
template <size_t _Len, size_t _Align = __find_max_align<__all_types, _Len>::value>
struct __attribute__ ((__type_visibility__("default"))) aligned_storage
{
typedef typename __find_pod<__all_types, _Align>::type _Aligner;
_Static_assert(!is_void<_Aligner>::value, "");
union type
{
_Aligner __align;
unsigned char __data[(_Len + _Align - 1)/_Align * _Align];
};
};
# 1762 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x1>{ struct __attribute__((__aligned__(0x1))) type { unsigned char __lx[(_Len + 0x1 - 1)/0x1 * 0x1]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x2>{ struct __attribute__((__aligned__(0x2))) type { unsigned char __lx[(_Len + 0x2 - 1)/0x2 * 0x2]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x4>{ struct __attribute__((__aligned__(0x4))) type { unsigned char __lx[(_Len + 0x4 - 1)/0x4 * 0x4]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x8>{ struct __attribute__((__aligned__(0x8))) type { unsigned char __lx[(_Len + 0x8 - 1)/0x8 * 0x8]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x10>{ struct __attribute__((__aligned__(0x10))) type { unsigned char __lx[(_Len + 0x10 - 1)/0x10 * 0x10]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x20>{ struct __attribute__((__aligned__(0x20))) type { unsigned char __lx[(_Len + 0x20 - 1)/0x20 * 0x20]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x40>{ struct __attribute__((__aligned__(0x40))) type { unsigned char __lx[(_Len + 0x40 - 1)/0x40 * 0x40]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x80>{ struct __attribute__((__aligned__(0x80))) type { unsigned char __lx[(_Len + 0x80 - 1)/0x80 * 0x80]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x100>{ struct __attribute__((__aligned__(0x100))) type { unsigned char __lx[(_Len + 0x100 - 1)/0x100 * 0x100]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x200>{ struct __attribute__((__aligned__(0x200))) type { unsigned char __lx[(_Len + 0x200 - 1)/0x200 * 0x200]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x400>{ struct __attribute__((__aligned__(0x400))) type { unsigned char __lx[(_Len + 0x400 - 1)/0x400 * 0x400]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x800>{ struct __attribute__((__aligned__(0x800))) type { unsigned char __lx[(_Len + 0x800 - 1)/0x800 * 0x800]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x1000>{ struct __attribute__((__aligned__(0x1000))) type { unsigned char __lx[(_Len + 0x1000 - 1)/0x1000 * 0x1000]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x2000>{ struct __attribute__((__aligned__(0x2000))) type { unsigned char __lx[(_Len + 0x2000 - 1)/0x2000 * 0x2000]; };};
template <size_t _Len>struct __attribute__ ((__type_visibility__("default"))) aligned_storage<_Len, 0x4000>{ struct __attribute__((__aligned__(0x4000))) type { unsigned char __lx[(_Len + 0x4000 - 1)/0x4000 * 0x4000]; };};
# 1819 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct __numeric_type
{
static void __test(...);
static float __test(float);
static double __test(char);
static double __test(int);
static double __test(unsigned);
static double __test(long);
static double __test(unsigned long);
static double __test(long long);
static double __test(unsigned long long);
static double __test(double);
static long double __test(long double);
typedef __decltype(__test(declval<_Tp>())) type;
static const bool value = !is_same<type, void>::value;
};
template <>
struct __numeric_type<void>
{
static const bool value = true;
};
template <class _A1, class _A2 = void, class _A3 = void,
bool = __numeric_type<_A1>::value &&
__numeric_type<_A2>::value &&
__numeric_type<_A3>::value>
class __promote_imp
{
public:
static const bool value = false;
};
template <class _A1, class _A2, class _A3>
class __promote_imp<_A1, _A2, _A3, true>
{
private:
typedef typename __promote_imp<_A1>::type __type1;
typedef typename __promote_imp<_A2>::type __type2;
typedef typename __promote_imp<_A3>::type __type3;
public:
typedef __decltype(__type1() + __type2() + __type3()) type;
static const bool value = true;
};
template <class _A1, class _A2>
class __promote_imp<_A1, _A2, void, true>
{
private:
typedef typename __promote_imp<_A1>::type __type1;
typedef typename __promote_imp<_A2>::type __type2;
public:
typedef __decltype(__type1() + __type2()) type;
static const bool value = true;
};
template <class _A1>
class __promote_imp<_A1, void, void, true>
{
public:
typedef typename __numeric_type<_A1>::type type;
static const bool value = true;
};
template <class _A1, class _A2 = void, class _A3 = void>
class __promote : public __promote_imp<_A1, _A2, _A3> {};
typedef
__type_list<signed char,
__type_list<signed short,
__type_list<signed int,
__type_list<signed long,
__type_list<signed long long,
__type_list<__int128_t,
__nat
>
> > > > > __signed_types;
typedef
__type_list<unsigned char,
__type_list<unsigned short,
__type_list<unsigned int,
__type_list<unsigned long,
__type_list<unsigned long long,
__type_list<__uint128_t,
__nat
>
> > > > > __unsigned_types;
template <class _TypeList, size_t _Size, bool = _Size <= sizeof(typename _TypeList::_Head)> struct __find_first;
template <class _Hp, class _Tp, size_t _Size>
struct __find_first<__type_list<_Hp, _Tp>, _Size, true>
{
typedef _Hp type;
};
template <class _Hp, class _Tp, size_t _Size>
struct __find_first<__type_list<_Hp, _Tp>, _Size, false>
{
typedef typename __find_first<_Tp, _Size>::type type;
};
template <class _Tp, class _Up, bool = is_const<typename remove_reference<_Tp>::type>::value,
bool = is_volatile<typename remove_reference<_Tp>::type>::value>
struct __apply_cv
{
typedef _Up type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp, _Up, true, false>
{
typedef const _Up type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp, _Up, false, true>
{
typedef volatile _Up type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp, _Up, true, true>
{
typedef const volatile _Up type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp&, _Up, false, false>
{
typedef _Up& type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp&, _Up, true, false>
{
typedef const _Up& type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp&, _Up, false, true>
{
typedef volatile _Up& type;
};
template <class _Tp, class _Up>
struct __apply_cv<_Tp&, _Up, true, true>
{
typedef const volatile _Up& type;
};
template <class _Tp, bool = is_integral<_Tp>::value || is_enum<_Tp>::value>
struct __make_signed {};
template <class _Tp>
struct __make_signed<_Tp, true>
{
typedef typename __find_first<__signed_types, sizeof(_Tp)>::type type;
};
template <> struct __make_signed<bool, true> {};
template <> struct __make_signed< signed short, true> {typedef short type;};
template <> struct __make_signed<unsigned short, true> {typedef short type;};
template <> struct __make_signed< signed int, true> {typedef int type;};
template <> struct __make_signed<unsigned int, true> {typedef int type;};
template <> struct __make_signed< signed long, true> {typedef long type;};
template <> struct __make_signed<unsigned long, true> {typedef long type;};
template <> struct __make_signed< signed long long, true> {typedef long long type;};
template <> struct __make_signed<unsigned long long, true> {typedef long long type;};
template <> struct __make_signed<__int128_t, true> {typedef __int128_t type;};
template <> struct __make_signed<__uint128_t, true> {typedef __int128_t type;};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) make_signed
{
typedef typename __apply_cv<_Tp, typename __make_signed<typename remove_cv<_Tp>::type>::type>::type type;
};
template <class _Tp, bool = is_integral<_Tp>::value || is_enum<_Tp>::value>
struct __make_unsigned {};
template <class _Tp>
struct __make_unsigned<_Tp, true>
{
typedef typename __find_first<__unsigned_types, sizeof(_Tp)>::type type;
};
template <> struct __make_unsigned<bool, true> {};
template <> struct __make_unsigned< signed short, true> {typedef unsigned short type;};
template <> struct __make_unsigned<unsigned short, true> {typedef unsigned short type;};
template <> struct __make_unsigned< signed int, true> {typedef unsigned int type;};
template <> struct __make_unsigned<unsigned int, true> {typedef unsigned int type;};
template <> struct __make_unsigned< signed long, true> {typedef unsigned long type;};
template <> struct __make_unsigned<unsigned long, true> {typedef unsigned long type;};
template <> struct __make_unsigned< signed long long, true> {typedef unsigned long long type;};
template <> struct __make_unsigned<unsigned long long, true> {typedef unsigned long long type;};
template <> struct __make_unsigned<__int128_t, true> {typedef __uint128_t type;};
template <> struct __make_unsigned<__uint128_t, true> {typedef __uint128_t type;};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) make_unsigned
{
typedef typename __apply_cv<_Tp, typename __make_unsigned<typename remove_cv<_Tp>::type>::type>::type type;
};
template <class _Tp, class _Up = void, class _Vp = void>
struct __attribute__ ((__type_visibility__("default"))) common_type
{
public:
typedef typename common_type<typename common_type<_Tp, _Up>::type, _Vp>::type type;
};
template <>
struct __attribute__ ((__type_visibility__("default"))) common_type<void, void, void>
{
public:
typedef void type;
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) common_type<_Tp, void, void>
{
public:
typedef typename common_type<_Tp, _Tp>::type type;
};
template <class _Tp, class _Up>
struct __attribute__ ((__type_visibility__("default"))) common_type<_Tp, _Up, void>
{
typedef typename decay<__decltype(true ? std::__1::declval<_Tp>() : std::__1::declval<_Up>())>::type type;
};
# 2161 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template<typename, typename _Tp> struct __select_2nd { typedef _Tp type; };
template <class _Tp, class _Arg>
typename __select_2nd<__decltype((std::__1::declval<_Tp>() = std::__1::declval<_Arg>())), true_type>::type
__is_assignable_test(int);
template <class, class>
false_type __is_assignable_test(...);
template <class _Tp, class _Arg, bool = is_void<_Tp>::value || is_void<_Arg>::value>
struct __is_assignable_imp
: public __decltype((std::__1::__is_assignable_test<_Tp, _Arg>(0))) {};
template <class _Tp, class _Arg>
struct __is_assignable_imp<_Tp, _Arg, true>
: public false_type
{
};
template <class _Tp, class _Arg>
struct is_assignable
: public __is_assignable_imp<_Tp, _Arg> {};
# 2193 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_copy_assignable
: public is_assignable<typename add_lvalue_reference<_Tp>::type,
typename add_lvalue_reference<typename add_const<_Tp>::type>::type> {};
# 2205 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_move_assignable
: public is_copy_assignable<_Tp> {};
# 2228 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class>
struct __is_destructible_apply { typedef int type; };
template <typename _Tp>
struct __is_destructor_wellformed {
template <typename _Tp1>
static char __test (
typename __is_destructible_apply<__decltype(std::__1::declval<_Tp1&>().~_Tp1())>::type
);
template <typename _Tp1>
static __two __test (...);
static const bool value = sizeof(__test<_Tp>(12)) == sizeof(char);
};
template <class _Tp, bool>
struct __destructible_imp;
template <class _Tp>
struct __destructible_imp<_Tp, false>
: public std::__1::integral_constant<bool,
__is_destructor_wellformed<typename std::__1::remove_all_extents<_Tp>::type>::value> {};
template <class _Tp>
struct __destructible_imp<_Tp, true>
: public std::__1::true_type {};
template <class _Tp, bool>
struct __destructible_false;
template <class _Tp>
struct __destructible_false<_Tp, false> : public __destructible_imp<_Tp, std::__1::is_reference<_Tp>::value> {};
template <class _Tp>
struct __destructible_false<_Tp, true> : public std::__1::false_type {};
template <class _Tp>
struct is_destructible
: public __destructible_false<_Tp, std::__1::is_function<_Tp>::value> {};
template <class _Tp>
struct is_destructible<_Tp[]>
: public std::__1::false_type {};
template <>
struct is_destructible<void>
: public std::__1::false_type {};
# 2316 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp&
move(_Tp& __t)
{
return __t;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const _Tp&
move(const _Tp& __t)
{
return __t;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp&
forward(typename remove_reference<_Tp>::type& __t) throw()
{
return __t;
}
template <class _Tp>
class __rv
{
typedef typename remove_reference<_Tp>::type _Trr;
_Trr& t_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Trr* operator->() {return &t_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __rv(_Trr& __t) : t_(__t) {}
};
# 2367 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename decay<_Tp>::type
__decay_copy(const _Tp& __t)
{
return std::__1::forward<_Tp>(__t);
}
# 2578 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)(), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) ();
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)(...), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (...);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, ...), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, ...);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, ...), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, ...);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2, ...), true, false>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2, ...);
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)() const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) ();
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)(...) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (...);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, ...) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, ...);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, ...) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, ...);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2, ...) const, true, false>
{
typedef _Class const _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2, ...);
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)() volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) ();
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)(...) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (...);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, ...) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, ...);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, ...) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, ...);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2, ...) volatile, true, false>
{
typedef _Class volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2, ...);
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)() const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) ();
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp (_Class::*)(...) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (...);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0);
};
template <class _Rp, class _Class, class _P0>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, ...) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, ...);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1);
};
template <class _Rp, class _Class, class _P0, class _P1>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, ...) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, ...);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2);
};
template <class _Rp, class _Class, class _P0, class _P1, class _P2>
struct __member_pointer_traits_imp<_Rp (_Class::*)(_P0, _P1, _P2, ...) const volatile, true, false>
{
typedef _Class const volatile _ClassType;
typedef _Rp _ReturnType;
typedef _Rp (_FnType) (_P0, _P1, _P2, ...);
};
template <class _Rp, class _Class>
struct __member_pointer_traits_imp<_Rp _Class::*, false, true>
{
typedef _Class _ClassType;
typedef _Rp _ReturnType;
};
template <class _MP>
struct __member_pointer_traits
: public __member_pointer_traits_imp<typename remove_cv<_MP>::type,
is_member_function_pointer<_MP>::value,
is_member_object_pointer<_MP>::value>
{
};
template <class _DecayedFp>
struct __member_pointer_class_type {};
template <class _Ret, class _ClassType>
struct __member_pointer_class_type<_Ret _ClassType::*> {
typedef _ClassType type;
};
template <class _Callable> class result_of;
template <class _Fn, bool, bool>
class __result_of
{
};
template <class _Fn>
class __result_of<_Fn(), true, false>
{
public:
typedef __decltype(declval<_Fn>()()) type;
};
template <class _Fn, class _A0>
class __result_of<_Fn(_A0), true, false>
{
public:
typedef __decltype(declval<_Fn>()(declval<_A0>())) type;
};
template <class _Fn, class _A0, class _A1>
class __result_of<_Fn(_A0, _A1), true, false>
{
public:
typedef __decltype(declval<_Fn>()(declval<_A0>(), declval<_A1>())) type;
};
template <class _Fn, class _A0, class _A1, class _A2>
class __result_of<_Fn(_A0, _A1, _A2), true, false>
{
public:
typedef __decltype(declval<_Fn>()(declval<_A0>(), declval<_A1>(), declval<_A2>())) type;
};
template <class _MP, class _Tp, bool _IsMemberFunctionPtr>
struct __result_of_mp;
template <class _MP, class _Tp>
struct __result_of_mp<_MP, _Tp, true>
: public __identity<typename __member_pointer_traits<_MP>::_ReturnType>
{
};
template <class _MP, class _Tp, bool>
struct __result_of_mdp;
template <class _Rp, class _Class, class _Tp>
struct __result_of_mdp<_Rp _Class::*, _Tp, false>
{
typedef typename __apply_cv<__decltype(*std::__1::declval<_Tp>()), _Rp>::type& type;
};
template <class _Rp, class _Class, class _Tp>
struct __result_of_mdp<_Rp _Class::*, _Tp, true>
{
typedef typename __apply_cv<_Tp, _Rp>::type& type;
};
template <class _Rp, class _Class, class _Tp>
struct __result_of_mp<_Rp _Class::*, _Tp, false>
: public __result_of_mdp<_Rp _Class::*, _Tp,
is_base_of<_Class, typename remove_reference<_Tp>::type>::value>
{
};
template <class _Fn, class _Tp>
class __result_of<_Fn(_Tp), false, true>
: public __result_of_mp<typename remove_reference<_Fn>::type,
_Tp,
is_member_function_pointer<typename remove_reference<_Fn>::type>::value>
{
};
template <class _Fn, class _Tp, class _A0>
class __result_of<_Fn(_Tp, _A0), false, true>
: public __result_of_mp<typename remove_reference<_Fn>::type,
_Tp,
is_member_function_pointer<typename remove_reference<_Fn>::type>::value>
{
};
template <class _Fn, class _Tp, class _A0, class _A1>
class __result_of<_Fn(_Tp, _A0, _A1), false, true>
: public __result_of_mp<typename remove_reference<_Fn>::type,
_Tp,
is_member_function_pointer<typename remove_reference<_Fn>::type>::value>
{
};
template <class _Fn, class _Tp, class _A0, class _A1, class _A2>
class __result_of<_Fn(_Tp, _A0, _A1, _A2), false, true>
: public __result_of_mp<typename remove_reference<_Fn>::type,
_Tp,
is_member_function_pointer<typename remove_reference<_Fn>::type>::value>
{
};
template <class _Fn>
class __attribute__ ((__type_visibility__("default"))) result_of<_Fn()>
: public __result_of<_Fn(),
is_class<typename remove_reference<_Fn>::type>::value ||
is_function<typename remove_pointer<typename remove_reference<_Fn>::type>::type>::value,
is_member_pointer<typename remove_reference<_Fn>::type>::value
>
{
};
template <class _Fn, class _A0>
class __attribute__ ((__type_visibility__("default"))) result_of<_Fn(_A0)>
: public __result_of<_Fn(_A0),
is_class<typename remove_reference<_Fn>::type>::value ||
is_function<typename remove_pointer<typename remove_reference<_Fn>::type>::type>::value,
is_member_pointer<typename remove_reference<_Fn>::type>::value
>
{
};
template <class _Fn, class _A0, class _A1>
class __attribute__ ((__type_visibility__("default"))) result_of<_Fn(_A0, _A1)>
: public __result_of<_Fn(_A0, _A1),
is_class<typename remove_reference<_Fn>::type>::value ||
is_function<typename remove_pointer<typename remove_reference<_Fn>::type>::type>::value,
is_member_pointer<typename remove_reference<_Fn>::type>::value
>
{
};
template <class _Fn, class _A0, class _A1, class _A2>
class __attribute__ ((__type_visibility__("default"))) result_of<_Fn(_A0, _A1, _A2)>
: public __result_of<_Fn(_A0, _A1, _A2),
is_class<typename remove_reference<_Fn>::type>::value ||
is_function<typename remove_pointer<typename remove_reference<_Fn>::type>::type>::value,
is_member_pointer<typename remove_reference<_Fn>::type>::value
>
{
};
namespace __is_construct
{
struct __nat {};
}
# 3139 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class ..._Args>
struct __attribute__ ((__type_visibility__("default"))) is_constructible
: public integral_constant<bool, __is_constructible(_Tp, _Args...)>
{};
# 3331 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_default_constructible
: public is_constructible<_Tp>
{};
# 3344 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_copy_constructible
: public is_constructible<_Tp,
typename add_lvalue_reference<typename add_const<_Tp>::type>::type> {};
# 3357 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_move_constructible
: public is_copy_constructible<_Tp>
{};
# 3428 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class _A0 = __is_construct::__nat,
class _A1 = __is_construct::__nat>
struct __attribute__ ((__type_visibility__("default"))) is_trivially_constructible
: false_type
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_trivially_constructible<_Tp, __is_construct::__nat,
__is_construct::__nat>
: integral_constant<bool, __is_trivially_constructible(_Tp)>
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_trivially_constructible<_Tp, _Tp,
__is_construct::__nat>
: integral_constant<bool, __is_trivially_constructible(_Tp, _Tp)>
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_trivially_constructible<_Tp, const _Tp&,
__is_construct::__nat>
: integral_constant<bool, __is_trivially_constructible(_Tp, const _Tp&)>
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_trivially_constructible<_Tp, _Tp&,
__is_construct::__nat>
: integral_constant<bool, __is_trivially_constructible(_Tp, _Tp&)>
{
};
# 3507 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_default_constructible
: public is_trivially_constructible<_Tp>
{};
# 3519 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_copy_constructible
: public is_trivially_constructible<_Tp, typename add_lvalue_reference<const _Tp>::type>
{};
# 3531 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_move_constructible
: public is_trivially_copy_constructible<_Tp>
{};
# 3549 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class _Arg>
struct is_trivially_assignable
: integral_constant<bool, __is_trivially_assignable(_Tp, _Arg)>
{
};
# 3591 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_copy_assignable
: public is_trivially_assignable<typename add_lvalue_reference<_Tp>::type,
typename add_lvalue_reference<typename add_const<_Tp>::type>::type> {};
# 3603 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_move_assignable
: public is_trivially_assignable<typename add_lvalue_reference<_Tp>::type,
typename add_lvalue_reference<_Tp>::type>
{};
# 3622 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_destructible
: public integral_constant<bool, is_destructible<_Tp>::value && __has_trivial_destructor(_Tp)> {};
# 3751 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class _A0 = __is_construct::__nat,
class _A1 = __is_construct::__nat>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_constructible
: false_type
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_constructible<_Tp, __is_construct::__nat,
__is_construct::__nat>
: integral_constant<bool, __has_nothrow_constructor(_Tp)>
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_constructible<_Tp, _Tp,
__is_construct::__nat>
: integral_constant<bool, __has_nothrow_copy(_Tp)>
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_constructible<_Tp, const _Tp&,
__is_construct::__nat>
: integral_constant<bool, __has_nothrow_copy(_Tp)>
{
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_constructible<_Tp, _Tp&,
__is_construct::__nat>
: integral_constant<bool, __has_nothrow_copy(_Tp)>
{
};
# 3813 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_nothrow_default_constructible
: public is_nothrow_constructible<_Tp>
{};
# 3825 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_nothrow_copy_constructible
: public is_nothrow_constructible<_Tp,
typename add_lvalue_reference<typename add_const<_Tp>::type>::type> {};
# 3837 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_nothrow_move_constructible
: public is_nothrow_copy_constructible<_Tp>
{};
# 3877 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, class _Arg>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_assignable
: public false_type {};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_assignable<_Tp&, _Tp>
: integral_constant<bool, __has_nothrow_assign(_Tp)> {};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_assignable<_Tp&, _Tp&>
: integral_constant<bool, __has_nothrow_assign(_Tp)> {};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_assignable<_Tp&, const _Tp&>
: integral_constant<bool, __has_nothrow_assign(_Tp)> {};
# 3927 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_nothrow_copy_assignable
: public is_nothrow_assignable<typename add_lvalue_reference<_Tp>::type,
typename add_lvalue_reference<typename add_const<_Tp>::type>::type> {};
# 3939 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_nothrow_move_assignable
: public is_nothrow_assignable<typename add_lvalue_reference<_Tp>::type,
typename add_lvalue_reference<_Tp>::type>
{};
# 4002 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __libcpp_nothrow_destructor
: public integral_constant<bool, is_scalar<_Tp>::value ||
is_reference<_Tp>::value> {};
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_nothrow_destructible
: public __libcpp_nothrow_destructor<typename remove_all_extents<_Tp>::type> {};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_nothrow_destructible<_Tp[]>
: public false_type {};
# 4025 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_pod
: public integral_constant<bool, __is_pod(_Tp)> {};
# 4046 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_literal_type
: public integral_constant<bool, __is_literal(_Tp)>
{};
# 4063 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_standard_layout
: public integral_constant<bool, __is_standard_layout(_Tp)>
{};
# 4079 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivially_copyable
: public integral_constant<bool, __is_trivially_copyable(_Tp)>
{};
# 4097 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_trivial
: public integral_constant<bool, __is_trivial(_Tp)>
{};
template <class _Tp> struct __is_reference_wrapper_impl : public false_type {};
template <class _Tp> struct __is_reference_wrapper_impl<reference_wrapper<_Tp> > : public true_type {};
template <class _Tp> struct __is_reference_wrapper
: public __is_reference_wrapper_impl<typename remove_cv<_Tp>::type> {};
# 4575 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp> struct __is_swappable;
template <class _Tp> struct __is_nothrow_swappable;
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(_Tp& __x, _Tp& __y)
{
_Tp __t(std::__1::move(__x));
__x = std::__1::move(__y);
__y = std::__1::move(__t);
}
template<class _Tp, size_t _Np>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<
__is_swappable<_Tp>::value
>::type
swap(_Tp (&__a)[_Np], _Tp (&__b)[_Np]) ;
template <class _ForwardIterator1, class _ForwardIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
iter_swap(_ForwardIterator1 __a, _ForwardIterator2 __b)
{
swap(*__a, *__b);
}
namespace __detail
{
template <class _Tp, class _Up = _Tp,
bool _NotVoid = !is_void<_Tp>::value && !is_void<_Up>::value>
struct __swappable_with
{
template <class _LHS, class _RHS>
static __decltype(swap(std::__1::declval<_LHS>(), std::__1::declval<_RHS>()))
__test_swap(int);
template <class, class>
static __nat __test_swap(long);
typedef __decltype((__test_swap<_Tp, _Up>(0))) __swap1;
typedef __decltype((__test_swap<_Up, _Tp>(0))) __swap2;
static const bool value = !is_same<__swap1, __nat>::value
&& !is_same<__swap2, __nat>::value;
};
template <class _Tp, class _Up>
struct __swappable_with<_Tp, _Up, false> : false_type {};
template <class _Tp, class _Up = _Tp, bool _Swappable = __swappable_with<_Tp, _Up>::value>
struct __nothrow_swappable_with {
static const bool value =
false;
};
template <class _Tp, class _Up>
struct __nothrow_swappable_with<_Tp, _Up, false> : false_type {};
}
template <class _Tp>
struct __is_swappable
: public integral_constant<bool, __detail::__swappable_with<_Tp&>::value>
{
};
template <class _Tp>
struct __is_nothrow_swappable
: public integral_constant<bool, __detail::__nothrow_swappable_with<_Tp&>::value>
{
};
# 4728 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp>
struct underlying_type
{
typedef __underlying_type(_Tp) type;
};
# 4751 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
template <class _Tp, bool = is_enum<_Tp>::value>
struct __sfinae_underlying_type
{
typedef typename underlying_type<_Tp>::type type;
typedef __decltype(((type)1) + 0) __promoted_type;
};
template <class _Tp>
struct __sfinae_underlying_type<_Tp, false> {};
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __convert_to_integral(int __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned __convert_to_integral(unsigned __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
long __convert_to_integral(long __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long __convert_to_integral(unsigned long __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
long long __convert_to_integral(long long __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long __convert_to_integral(unsigned long long __val) {return __val; }
template<typename _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<is_floating_point<_Fp>::value, long long>::type
__convert_to_integral(_Fp __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__int128_t __convert_to_integral(__int128_t __val) { return __val; }
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__uint128_t __convert_to_integral(__uint128_t __val) { return __val; }
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __sfinae_underlying_type<_Tp>::__promoted_type
__convert_to_integral(_Tp __val) { return __val; }
# 4890 "/Library/Developer/CommandLineTools/usr/include/c++/v1/type_traits" 3
} }
# 641 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 1 3
# 198 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__tuple" 1 3
# 20 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__tuple" 3
namespace std {inline namespace __1 {
template <class _Tp> class __attribute__ ((__type_visibility__("default"))) tuple_size;
# 52 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__tuple" 3
template <class _Tp> class __attribute__ ((__type_visibility__("default"))) tuple_size<const _Tp> : public tuple_size<_Tp> {};
template <class _Tp> class __attribute__ ((__type_visibility__("default"))) tuple_size<volatile _Tp> : public tuple_size<_Tp> {};
template <class _Tp> class __attribute__ ((__type_visibility__("default"))) tuple_size<const volatile _Tp> : public tuple_size<_Tp> {};
template <size_t _Ip, class _Tp> class __attribute__ ((__type_visibility__("default"))) tuple_element;
template <size_t _Ip, class _Tp>
class __attribute__ ((__type_visibility__("default"))) tuple_element<_Ip, const _Tp>
{
public:
typedef typename add_const<typename tuple_element<_Ip, _Tp>::type>::type type;
};
template <size_t _Ip, class _Tp>
class __attribute__ ((__type_visibility__("default"))) tuple_element<_Ip, volatile _Tp>
{
public:
typedef typename add_volatile<typename tuple_element<_Ip, _Tp>::type>::type type;
};
template <size_t _Ip, class _Tp>
class __attribute__ ((__type_visibility__("default"))) tuple_element<_Ip, const volatile _Tp>
{
public:
typedef typename add_cv<typename tuple_element<_Ip, _Tp>::type>::type type;
};
template <class _Tp> struct __tuple_like : false_type {};
template <class _Tp> struct __tuple_like<const _Tp> : public __tuple_like<_Tp> {};
template <class _Tp> struct __tuple_like<volatile _Tp> : public __tuple_like<_Tp> {};
template <class _Tp> struct __tuple_like<const volatile _Tp> : public __tuple_like<_Tp> {};
# 197 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__tuple" 3
template <class _T1, class _T2> struct __tuple_like<pair<_T1, _T2> > : true_type {};
template <size_t _Ip, class _T1, class _T2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename tuple_element<_Ip, pair<_T1, _T2> >::type&
get(pair<_T1, _T2>&) throw();
template <size_t _Ip, class _T1, class _T2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
const typename tuple_element<_Ip, pair<_T1, _T2> >::type&
get(const pair<_T1, _T2>&) throw();
# 223 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__tuple" 3
template <class _Tp, size_t _Size> struct __attribute__ ((__type_visibility__("default"))) array;
template <class _Tp, size_t _Size> struct __tuple_like<array<_Tp, _Size> > : true_type {};
template <size_t _Ip, class _Tp, size_t _Size>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp&
get(array<_Tp, _Size>&) throw();
template <size_t _Ip, class _Tp, size_t _Size>
__attribute__ ((__visibility__("hidden"), __always_inline__))
const _Tp&
get(const array<_Tp, _Size>&) throw();
# 554 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__tuple" 3
} }
# 199 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdint" 1 3
# 149 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdint" 3
namespace std {inline namespace __1 {
using::int8_t;
using::int16_t;
using::int32_t;
using::int64_t;
using::uint8_t;
using::uint16_t;
using::uint32_t;
using::uint64_t;
using::int_least8_t;
using::int_least16_t;
using::int_least32_t;
using::int_least64_t;
using::uint_least8_t;
using::uint_least16_t;
using::uint_least32_t;
using::uint_least64_t;
using::int_fast8_t;
using::int_fast16_t;
using::int_fast32_t;
using::int_fast64_t;
using::uint_fast8_t;
using::uint_fast16_t;
using::uint_fast32_t;
using::uint_fast64_t;
using::intptr_t;
using::uintptr_t;
using::intmax_t;
using::uintmax_t;
} }
# 204 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__debug" 1 3
# 18 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__debug" 3
# 54 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__debug" 3
class __attribute__ ((__visibility__("default"))) __libcpp_debug_exception;
namespace std {inline namespace __1 {
struct __attribute__ ((__type_visibility__("default"))) __libcpp_debug_info {
__attribute__ ((__visibility__("hidden"), __always_inline__))
__libcpp_debug_info()
: __file_(std::__1::__get_nullptr_t()), __line_(-1), __pred_(std::__1::__get_nullptr_t()), __msg_(std::__1::__get_nullptr_t()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__libcpp_debug_info(const char* __f, int __l, const char* __p, const char* __m)
: __file_(__f), __line_(__l), __pred_(__p), __msg_(__m) {}
const char* __file_;
int __line_;
const char* __pred_;
const char* __msg_;
};
typedef void(*__libcpp_debug_function_type)(__libcpp_debug_info const&);
extern __libcpp_debug_function_type __libcpp_debug_function;
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default")))
void __libcpp_abort_debug_function(__libcpp_debug_info const&);
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default")))
void __libcpp_throw_debug_function(__libcpp_debug_info const&);
__attribute__ ((__visibility__("default")))
bool __libcpp_set_debug_function(__libcpp_debug_function_type __func);
# 299 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__debug" 3
} }
# 205 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 2 3
# 208 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
namespace std {inline namespace __1 {
namespace rel_ops
{
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const _Tp& __x, const _Tp& __y)
{
return !(__x == __y);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const _Tp& __x, const _Tp& __y)
{
return __y < __x;
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const _Tp& __x, const _Tp& __y)
{
return !(__y < __x);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const _Tp& __x, const _Tp& __y)
{
return !(__x < __y);
}
}
template <class _ForwardIterator1, class _ForwardIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator2
swap_ranges(_ForwardIterator1 __first1, _ForwardIterator1 __last1, _ForwardIterator2 __first2)
{
for(; __first1 != __last1; ++__first1, (void) ++__first2)
swap(*__first1, *__first2);
return __first2;
}
template<class _Tp, size_t _Np>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<
__is_swappable<_Tp>::value
>::type
swap(_Tp (&__a)[_Np], _Tp (&__b)[_Np])
{
std::__1::swap_ranges(__a, __a + _Np, __b);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
# 283 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
const _Tp&
move_if_noexcept(_Tp& __x) throw()
{
return std::__1::move(__x);
}
struct __attribute__ ((__type_visibility__("default"))) piecewise_construct_t { };
extern const piecewise_construct_t piecewise_construct;
# 311 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
template <class _T1, class _T2>
struct __attribute__ ((__type_visibility__("default"))) pair
{
typedef _T1 first_type;
typedef _T2 second_type;
_T1 first;
_T2 second;
# 331 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
pair() : first(), second() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pair(_T1 const& __t1, _T2 const& __t2) : first(__t1), second(__t2) {}
template <class _U1, class _U2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
pair(const pair<_U1, _U2>& __p) : first(__p.first), second(__p.second) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pair& operator=(pair const& __p) {
first = __p.first;
second = __p.second;
return *this;
}
# 528 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(pair& __p)
{
using std::__1::swap;
swap(first, __p.first);
swap(second, __p.second);
}
private:
# 546 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
};
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const pair<_T1,_T2>& __x, const pair<_T1,_T2>& __y)
{
return __x.first == __y.first && __x.second == __y.second;
}
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const pair<_T1,_T2>& __x, const pair<_T1,_T2>& __y)
{
return !(__x == __y);
}
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator< (const pair<_T1,_T2>& __x, const pair<_T1,_T2>& __y)
{
return __x.first < __y.first || (!(__y.first < __x.first) && __x.second < __y.second);
}
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const pair<_T1,_T2>& __x, const pair<_T1,_T2>& __y)
{
return __y < __x;
}
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const pair<_T1,_T2>& __x, const pair<_T1,_T2>& __y)
{
return !(__x < __y);
}
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const pair<_T1,_T2>& __x, const pair<_T1,_T2>& __y)
{
return !(__y < __x);
}
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__is_swappable<_T1>::value &&
__is_swappable<_T2>::value,
void
>::type
swap(pair<_T1, _T2>& __x, pair<_T1, _T2>& __y)
{
__x.swap(__y);
}
# 647 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<_T1,_T2>
make_pair(_T1 __x, _T2 __y)
{
return pair<_T1, _T2>(__x, __y);
}
template <class _T1, class _T2>
class __attribute__ ((__type_visibility__("default"))) tuple_size<pair<_T1, _T2> >
: public integral_constant<size_t, 2> {};
template <size_t _Ip, class _T1, class _T2>
class __attribute__ ((__type_visibility__("default"))) tuple_element<_Ip, pair<_T1, _T2> >
{
_Static_assert(_Ip < 2, "Index out of bounds in std::tuple_element<std::pair<T1, T2>>");
};
template <class _T1, class _T2>
class __attribute__ ((__type_visibility__("default"))) tuple_element<0, pair<_T1, _T2> >
{
public:
typedef _T1 type;
};
template <class _T1, class _T2>
class __attribute__ ((__type_visibility__("default"))) tuple_element<1, pair<_T1, _T2> >
{
public:
typedef _T2 type;
};
template <size_t _Ip> struct __get_pair;
template <>
struct __get_pair<0>
{
template <class _T1, class _T2>
static
__attribute__ ((__visibility__("hidden"), __always_inline__))
_T1&
get(pair<_T1, _T2>& __p) throw() {return __p.first;}
template <class _T1, class _T2>
static
__attribute__ ((__visibility__("hidden"), __always_inline__))
const _T1&
get(const pair<_T1, _T2>& __p) throw() {return __p.first;}
# 711 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
};
template <>
struct __get_pair<1>
{
template <class _T1, class _T2>
static
__attribute__ ((__visibility__("hidden"), __always_inline__))
_T2&
get(pair<_T1, _T2>& __p) throw() {return __p.second;}
template <class _T1, class _T2>
static
__attribute__ ((__visibility__("hidden"), __always_inline__))
const _T2&
get(const pair<_T1, _T2>& __p) throw() {return __p.second;}
# 741 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
};
template <size_t _Ip, class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename tuple_element<_Ip, pair<_T1, _T2> >::type&
get(pair<_T1, _T2>& __p) throw()
{
return __get_pair<_Ip>::get(__p);
}
template <size_t _Ip, class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const typename tuple_element<_Ip, pair<_T1, _T2> >::type&
get(const pair<_T1, _T2>& __p) throw()
{
return __get_pair<_Ip>::get(__p);
}
# 937 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
template <class _Arg, class _Result>
struct __attribute__ ((__type_visibility__("default"))) unary_function
{
typedef _Arg argument_type;
typedef _Result result_type;
};
template <class _Size>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Size
__loadword(const void* __p)
{
_Size __r;
std::memcpy(&__r, __p, sizeof(__r));
return __r;
}
template <class _Size, size_t = sizeof(_Size)*8>
struct __murmur2_or_cityhash;
template <class _Size>
struct __murmur2_or_cityhash<_Size, 32>
{
inline _Size operator()(const void* __key, _Size __len)
__attribute__((__no_sanitize__("unsigned-integer-overflow")));
};
template <class _Size>
_Size
__murmur2_or_cityhash<_Size, 32>::operator()(const void* __key, _Size __len)
{
const _Size __m = 0x5bd1e995;
const _Size __r = 24;
_Size __h = __len;
const unsigned char* __data = static_cast<const unsigned char*>(__key);
for (; __len >= 4; __data += 4, __len -= 4)
{
_Size __k = __loadword<_Size>(__data);
__k *= __m;
__k ^= __k >> __r;
__k *= __m;
__h *= __m;
__h ^= __k;
}
switch (__len)
{
case 3:
__h ^= __data[2] << 16;
case 2:
__h ^= __data[1] << 8;
case 1:
__h ^= __data[0];
__h *= __m;
}
__h ^= __h >> 13;
__h *= __m;
__h ^= __h >> 15;
return __h;
}
template <class _Size>
struct __murmur2_or_cityhash<_Size, 64>
{
inline _Size operator()(const void* __key, _Size __len) __attribute__((__no_sanitize__("unsigned-integer-overflow")));
private:
static const _Size __k0 = 0xc3a5c85c97cb3127ULL;
static const _Size __k1 = 0xb492b66fbe98f273ULL;
static const _Size __k2 = 0x9ae16a3b2f90404fULL;
static const _Size __k3 = 0xc949d7c7509e6557ULL;
static _Size __rotate(_Size __val, int __shift) {
return __shift == 0 ? __val : ((__val >> __shift) | (__val << (64 - __shift)));
}
static _Size __rotate_by_at_least_1(_Size __val, int __shift) {
return (__val >> __shift) | (__val << (64 - __shift));
}
static _Size __shift_mix(_Size __val) {
return __val ^ (__val >> 47);
}
static _Size __hash_len_16(_Size __u, _Size __v)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
const _Size __mul = 0x9ddfea08eb382d69ULL;
_Size __a = (__u ^ __v) * __mul;
__a ^= (__a >> 47);
_Size __b = (__v ^ __a) * __mul;
__b ^= (__b >> 47);
__b *= __mul;
return __b;
}
static _Size __hash_len_0_to_16(const char* __s, _Size __len)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
if (__len > 8) {
const _Size __a = __loadword<_Size>(__s);
const _Size __b = __loadword<_Size>(__s + __len - 8);
return __hash_len_16(__a, __rotate_by_at_least_1(__b + __len, __len)) ^ __b;
}
if (__len >= 4) {
const uint32_t __a = __loadword<uint32_t>(__s);
const uint32_t __b = __loadword<uint32_t>(__s + __len - 4);
return __hash_len_16(__len + (__a << 3), __b);
}
if (__len > 0) {
const unsigned char __a = __s[0];
const unsigned char __b = __s[__len >> 1];
const unsigned char __c = __s[__len - 1];
const uint32_t __y = static_cast<uint32_t>(__a) +
(static_cast<uint32_t>(__b) << 8);
const uint32_t __z = __len + (static_cast<uint32_t>(__c) << 2);
return __shift_mix(__y * __k2 ^ __z * __k3) * __k2;
}
return __k2;
}
static _Size __hash_len_17_to_32(const char *__s, _Size __len)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
const _Size __a = __loadword<_Size>(__s) * __k1;
const _Size __b = __loadword<_Size>(__s + 8);
const _Size __c = __loadword<_Size>(__s + __len - 8) * __k2;
const _Size __d = __loadword<_Size>(__s + __len - 16) * __k0;
return __hash_len_16(__rotate(__a - __b, 43) + __rotate(__c, 30) + __d,
__a + __rotate(__b ^ __k3, 20) - __c + __len);
}
static pair<_Size, _Size> __weak_hash_len_32_with_seeds(
_Size __w, _Size __x, _Size __y, _Size __z, _Size __a, _Size __b)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
__a += __w;
__b = __rotate(__b + __a + __z, 21);
const _Size __c = __a;
__a += __x;
__a += __y;
__b += __rotate(__a, 44);
return pair<_Size, _Size>(__a + __z, __b + __c);
}
static pair<_Size, _Size> __weak_hash_len_32_with_seeds(
const char* __s, _Size __a, _Size __b)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
return __weak_hash_len_32_with_seeds(__loadword<_Size>(__s),
__loadword<_Size>(__s + 8),
__loadword<_Size>(__s + 16),
__loadword<_Size>(__s + 24),
__a,
__b);
}
static _Size __hash_len_33_to_64(const char *__s, size_t __len)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
_Size __z = __loadword<_Size>(__s + 24);
_Size __a = __loadword<_Size>(__s) +
(__len + __loadword<_Size>(__s + __len - 16)) * __k0;
_Size __b = __rotate(__a + __z, 52);
_Size __c = __rotate(__a, 37);
__a += __loadword<_Size>(__s + 8);
__c += __rotate(__a, 7);
__a += __loadword<_Size>(__s + 16);
_Size __vf = __a + __z;
_Size __vs = __b + __rotate(__a, 31) + __c;
__a = __loadword<_Size>(__s + 16) + __loadword<_Size>(__s + __len - 32);
__z += __loadword<_Size>(__s + __len - 8);
__b = __rotate(__a + __z, 52);
__c = __rotate(__a, 37);
__a += __loadword<_Size>(__s + __len - 24);
__c += __rotate(__a, 7);
__a += __loadword<_Size>(__s + __len - 16);
_Size __wf = __a + __z;
_Size __ws = __b + __rotate(__a, 31) + __c;
_Size __r = __shift_mix((__vf + __ws) * __k2 + (__wf + __vs) * __k0);
return __shift_mix(__r * __k0 + __vs) * __k2;
}
};
template <class _Size>
_Size
__murmur2_or_cityhash<_Size, 64>::operator()(const void* __key, _Size __len)
{
const char* __s = static_cast<const char*>(__key);
if (__len <= 32) {
if (__len <= 16) {
return __hash_len_0_to_16(__s, __len);
} else {
return __hash_len_17_to_32(__s, __len);
}
} else if (__len <= 64) {
return __hash_len_33_to_64(__s, __len);
}
_Size __x = __loadword<_Size>(__s + __len - 40);
_Size __y = __loadword<_Size>(__s + __len - 16) +
__loadword<_Size>(__s + __len - 56);
_Size __z = __hash_len_16(__loadword<_Size>(__s + __len - 48) + __len,
__loadword<_Size>(__s + __len - 24));
pair<_Size, _Size> __v = __weak_hash_len_32_with_seeds(__s + __len - 64, __len, __z);
pair<_Size, _Size> __w = __weak_hash_len_32_with_seeds(__s + __len - 32, __y + __k1, __x);
__x = __x * __k1 + __loadword<_Size>(__s);
__len = (__len - 1) & ~static_cast<_Size>(63);
do {
__x = __rotate(__x + __y + __v.first + __loadword<_Size>(__s + 8), 37) * __k1;
__y = __rotate(__y + __v.second + __loadword<_Size>(__s + 48), 42) * __k1;
__x ^= __w.second;
__y += __v.first + __loadword<_Size>(__s + 40);
__z = __rotate(__z + __w.first, 33) * __k1;
__v = __weak_hash_len_32_with_seeds(__s, __v.second * __k1, __x + __w.first);
__w = __weak_hash_len_32_with_seeds(__s + 32, __z + __w.second,
__y + __loadword<_Size>(__s + 16));
std::swap(__z, __x);
__s += 64;
__len -= 64;
} while (__len != 0);
return __hash_len_16(
__hash_len_16(__v.first, __w.first) + __shift_mix(__y) * __k1 + __z,
__hash_len_16(__v.second, __w.second) + __x);
}
template <class _Tp, size_t = sizeof(_Tp) / sizeof(size_t)>
struct __scalar_hash;
template <class _Tp>
struct __scalar_hash<_Tp, 0>
: public unary_function<_Tp, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(_Tp __v) const throw()
{
union
{
_Tp __t;
size_t __a;
} __u;
__u.__a = 0;
__u.__t = __v;
return __u.__a;
}
};
template <class _Tp>
struct __scalar_hash<_Tp, 1>
: public unary_function<_Tp, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(_Tp __v) const throw()
{
union
{
_Tp __t;
size_t __a;
} __u;
__u.__t = __v;
return __u.__a;
}
};
template <class _Tp>
struct __scalar_hash<_Tp, 2>
: public unary_function<_Tp, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(_Tp __v) const throw()
{
union
{
_Tp __t;
struct
{
size_t __a;
size_t __b;
} __s;
} __u;
__u.__t = __v;
return __murmur2_or_cityhash<size_t>()(&__u, sizeof(__u));
}
};
template <class _Tp>
struct __scalar_hash<_Tp, 3>
: public unary_function<_Tp, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(_Tp __v) const throw()
{
union
{
_Tp __t;
struct
{
size_t __a;
size_t __b;
size_t __c;
} __s;
} __u;
__u.__t = __v;
return __murmur2_or_cityhash<size_t>()(&__u, sizeof(__u));
}
};
template <class _Tp>
struct __scalar_hash<_Tp, 4>
: public unary_function<_Tp, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(_Tp __v) const throw()
{
union
{
_Tp __t;
struct
{
size_t __a;
size_t __b;
size_t __c;
size_t __d;
} __s;
} __u;
__u.__t = __v;
return __murmur2_or_cityhash<size_t>()(&__u, sizeof(__u));
}
};
struct _PairT {
size_t first;
size_t second;
};
__attribute__ ((__visibility__("hidden"), __always_inline__))
inline size_t __hash_combine(size_t __lhs, size_t __rhs) throw() {
typedef __scalar_hash<_PairT> _HashT;
const _PairT __p = {__lhs, __rhs};
return _HashT()(__p);
}
template<class _Tp>
struct __attribute__ ((__type_visibility__("default"))) hash<_Tp*>
: public unary_function<_Tp*, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(_Tp* __v) const throw()
{
union
{
_Tp* __t;
size_t __a;
} __u;
__u.__t = __v;
return __murmur2_or_cityhash<size_t>()(&__u, sizeof(__u));
}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<bool>
: public unary_function<bool, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(bool __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<char>
: public unary_function<char, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(char __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<signed char>
: public unary_function<signed char, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(signed char __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<unsigned char>
: public unary_function<unsigned char, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(unsigned char __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<char16_t>
: public unary_function<char16_t, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(char16_t __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<char32_t>
: public unary_function<char32_t, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(char32_t __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<wchar_t>
: public unary_function<wchar_t, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(wchar_t __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<short>
: public unary_function<short, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(short __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<unsigned short>
: public unary_function<unsigned short, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(unsigned short __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<int>
: public unary_function<int, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(int __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<unsigned int>
: public unary_function<unsigned int, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(unsigned int __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<long>
: public unary_function<long, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(long __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<unsigned long>
: public unary_function<unsigned long, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(unsigned long __v) const throw() {return static_cast<size_t>(__v);}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<long long>
: public __scalar_hash<long long>
{
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<unsigned long long>
: public __scalar_hash<unsigned long long>
{
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<__int128_t>
: public __scalar_hash<__int128_t>
{
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<__uint128_t>
: public __scalar_hash<__uint128_t>
{
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<float>
: public __scalar_hash<float>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(float __v) const throw()
{
if (__v == 0)
return 0;
return __scalar_hash<float>::operator()(__v);
}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<double>
: public __scalar_hash<double>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(double __v) const throw()
{
if (__v == 0)
return 0;
return __scalar_hash<double>::operator()(__v);
}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<long double>
: public __scalar_hash<long double>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(long double __v) const throw()
{
if (__v == 0)
return 0;
# 1505 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
union
{
long double __t;
struct
{
size_t __a;
size_t __b;
} __s;
} __u;
__u.__s.__a = 0;
__u.__s.__b = 0;
__u.__t = __v;
return __u.__s.__a ^ __u.__s.__b;
}
};
# 1592 "/Library/Developer/CommandLineTools/usr/include/c++/v1/utility" 3
} }
# 643 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 1 3
# 653 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 1 3
# 61 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/exception" 1 3
# 91 "/Library/Developer/CommandLineTools/usr/include/c++/v1/exception" 3
namespace std
{
class __attribute__ ((__visibility__("default"))) exception
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) exception() throw() {}
virtual ~exception() throw();
virtual const char* what() const throw();
};
class __attribute__ ((__visibility__("default"))) bad_exception
: public exception
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) bad_exception() throw() {}
virtual ~bad_exception() throw();
virtual const char* what() const throw();
};
typedef void (*unexpected_handler)();
__attribute__ ((__visibility__("default"))) unexpected_handler set_unexpected(unexpected_handler) throw();
__attribute__ ((__visibility__("default"))) unexpected_handler get_unexpected() throw();
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default"))) void unexpected();
typedef void (*terminate_handler)();
__attribute__ ((__visibility__("default"))) terminate_handler set_terminate(terminate_handler) throw();
__attribute__ ((__visibility__("default"))) terminate_handler get_terminate() throw();
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default"))) void terminate() throw();
__attribute__ ((__visibility__("default"))) bool uncaught_exception() throw();
__attribute__ ((__visibility__("default"))) __attribute__((availability(macosx,strict,introduced=10.12))) __attribute__((availability(ios,strict,introduced=10.0))) __attribute__((availability(tvos,strict,introduced=10.0))) __attribute__((availability(watchos,strict,introduced=3.0))) int uncaught_exceptions() throw();
class __attribute__ ((__visibility__("default"))) exception_ptr;
__attribute__ ((__visibility__("default"))) exception_ptr current_exception() throw();
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default"))) void rethrow_exception(exception_ptr);
class __attribute__ ((__visibility__("default"))) exception_ptr
{
void* __ptr_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) exception_ptr() throw() : __ptr_() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) exception_ptr(nullptr_t) throw() : __ptr_() {}
exception_ptr(const exception_ptr&) throw();
exception_ptr& operator=(const exception_ptr&) throw();
~exception_ptr() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator bool() const throw()
{return __ptr_ != std::__1::__get_nullptr_t();}
friend __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const exception_ptr& __x, const exception_ptr& __y) throw()
{return __x.__ptr_ == __y.__ptr_;}
friend __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const exception_ptr& __x, const exception_ptr& __y) throw()
{return !(__x == __y);}
friend __attribute__ ((__visibility__("default"))) exception_ptr current_exception() throw();
friend __attribute__ ((__visibility__("default"))) void rethrow_exception(exception_ptr);
};
template<class _Ep>
exception_ptr
make_exception_ptr(_Ep __e) throw()
{
try
{
throw __e;
}
catch (...)
{
return current_exception();
}
}
# 234 "/Library/Developer/CommandLineTools/usr/include/c++/v1/exception" 3
class __attribute__ ((__visibility__("default"))) nested_exception
{
exception_ptr __ptr_;
public:
nested_exception() throw();
virtual ~nested_exception() throw();
__attribute__ ((noreturn)) void rethrow_nested() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) exception_ptr nested_ptr() const throw() {return __ptr_;}
};
template <class _Tp>
struct __nested
: public _Tp,
public nested_exception
{
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __nested(const _Tp& __t) : _Tp(__t) {}
};
template <class _Tp, class _Up, bool>
struct __throw_with_nested;
template <class _Tp, class _Up>
struct __throw_with_nested<_Tp, _Up, true> {
__attribute__ ((noreturn)) static inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void
__do_throw (_Tp& __t)
{
throw __nested<_Up>(std::__1::forward<_Tp>(__t));
}
};
template <class _Tp, class _Up>
struct __throw_with_nested<_Tp, _Up, false> {
__attribute__ ((noreturn)) static inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void
__do_throw (_Tp& __t)
{
throw std::__1::forward<_Tp>(__t);
}
};
template <class _Tp>
__attribute__ ((noreturn))
void
throw_with_nested (_Tp& __t)
{
typedef typename decay<_Tp>::type _Up;
_Static_assert(is_copy_constructible<_Up>::value, "type thrown must be CopyConstructible");
__throw_with_nested<_Tp, _Up,
is_class<_Up>::value &&
!is_base_of<nested_exception, _Up>::value &&
!__libcpp_is_final<_Up>::value>::
__do_throw(std::__1::forward<_Tp>(__t));
}
template <class _From, class _To>
struct __can_dynamic_cast : public integral_constant<bool,(is_polymorphic<_From>::value && (!is_base_of<_To, _From>::value || is_convertible<const _From*, const _To*>::value))> {};
template <class _Ep>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
rethrow_if_nested(const _Ep& __e,
typename enable_if< __can_dynamic_cast<_Ep, nested_exception>::value>::type* = 0)
{
const nested_exception* __nep = dynamic_cast<const nested_exception*>(std::__1::addressof(__e));
if (__nep)
__nep->rethrow_nested();
}
template <class _Ep>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
rethrow_if_nested(const _Ep&,
typename enable_if<!__can_dynamic_cast<_Ep, nested_exception>::value>::type* = 0)
{
}
}
# 62 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 2 3
# 70 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 3
# 80 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 3
namespace std
{
class __attribute__ ((__visibility__("default"))) type_info
{
type_info& operator=(const type_info&);
type_info(const type_info&);
# 103 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 3
protected:
# 113 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 3
const char *__type_name;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit type_info(const char* __n) : __type_name(__n) {}
public:
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
virtual ~type_info();
# 179 "/Library/Developer/CommandLineTools/usr/include/c++/v1/typeinfo" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char* name() const throw()
{ return __type_name; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool before(const type_info& __arg) const throw()
{ return __type_name < __arg.__type_name; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t hash_code() const throw()
{ return reinterpret_cast<size_t>(__type_name); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const type_info& __arg) const throw()
{ return __type_name == __arg.__type_name; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const type_info& __arg) const throw()
{ return !operator==(__arg); }
};
class __attribute__ ((__visibility__("default"))) bad_cast
: public exception
{
public:
bad_cast() throw();
virtual ~bad_cast() throw();
virtual const char* what() const throw();
};
class __attribute__ ((__visibility__("default"))) bad_typeid
: public exception
{
public:
bad_typeid() throw();
virtual ~bad_typeid() throw();
virtual const char* what() const throw();
};
}
namespace std {inline namespace __1 {
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_bad_cast()
{
throw bad_cast();
}
} }
# 654 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 1 3
# 103 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
# 116 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
namespace std
{
struct __attribute__ ((__visibility__("default"))) nothrow_t {};
extern __attribute__ ((__visibility__("default"))) const nothrow_t nothrow;
class __attribute__ ((__visibility__("default"))) bad_alloc
: public exception
{
public:
bad_alloc() throw();
virtual ~bad_alloc() throw();
virtual const char* what() const throw();
};
class __attribute__ ((__visibility__("default"))) bad_array_new_length
: public bad_alloc
{
public:
bad_array_new_length() throw();
virtual ~bad_array_new_length() throw();
virtual const char* what() const throw();
};
typedef void (*new_handler)();
__attribute__ ((__visibility__("default"))) new_handler set_new_handler(new_handler) throw();
__attribute__ ((__visibility__("default"))) new_handler get_new_handler() throw();
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default"))) void __throw_bad_alloc();
# 171 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
}
# 181 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
__attribute__ ((__visibility__("default"))) void* operator new(std::size_t __sz) throw(std::bad_alloc);
__attribute__ ((__visibility__("default"))) void* operator new(std::size_t __sz, const std::nothrow_t&) throw() __attribute__((__malloc__));
__attribute__ ((__visibility__("default"))) void operator delete(void* __p) throw();
__attribute__ ((__visibility__("default"))) void operator delete(void* __p, const std::nothrow_t&) throw();
__attribute__ ((__visibility__("default"))) void* operator new[](std::size_t __sz) throw(std::bad_alloc);
__attribute__ ((__visibility__("default"))) void* operator new[](std::size_t __sz, const std::nothrow_t&) throw() __attribute__((__malloc__));
__attribute__ ((__visibility__("default"))) void operator delete[](void* __p) throw();
__attribute__ ((__visibility__("default"))) void operator delete[](void* __p, const std::nothrow_t&) throw();
# 215 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void* operator new (std::size_t, void* __p) throw() {return __p;}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void* operator new[](std::size_t, void* __p) throw() {return __p;}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void operator delete (void*, void*) throw() {}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void operator delete[](void*, void*) throw() {}
namespace std {inline namespace __1 {
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void *__allocate(size_t __size) {
return __builtin_operator_new(__size);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) void __libcpp_deallocate(void *__ptr) {
__builtin_operator_delete(__ptr);
}
# 255 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
template <class _Tp>
inline
_Tp* __launder(_Tp* __p) throw()
{
_Static_assert(!(is_function<_Tp>::value), "can't launder functions");
_Static_assert(!(is_same<void, typename remove_cv<_Tp>::type>::value), "can't launder cv-void");
return __p;
}
# 278 "/Library/Developer/CommandLineTools/usr/include/c++/v1/new" 3
} }
# 657 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits" 1 3
# 117 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 121 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits" 2 3
namespace std {inline namespace __1 {
enum float_round_style
{
round_indeterminate = -1,
round_toward_zero = 0,
round_to_nearest = 1,
round_toward_infinity = 2,
round_toward_neg_infinity = 3
};
enum float_denorm_style
{
denorm_indeterminate = -1,
denorm_absent = 0,
denorm_present = 1
};
template <class _Tp, bool = is_arithmetic<_Tp>::value>
class __libcpp_numeric_limits
{
protected:
typedef _Tp type;
static const bool is_specialized = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return type();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return type();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return type();}
static const int digits = 0;
static const int digits10 = 0;
static const int max_digits10 = 0;
static const bool is_signed = false;
static const bool is_integer = false;
static const bool is_exact = false;
static const int radix = 0;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return type();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return type();}
static const int min_exponent = 0;
static const int min_exponent10 = 0;
static const int max_exponent = 0;
static const int max_exponent10 = 0;
static const bool has_infinity = false;
static const bool has_quiet_NaN = false;
static const bool has_signaling_NaN = false;
static const float_denorm_style has_denorm = denorm_absent;
static const bool has_denorm_loss = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return type();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return type();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return type();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return type();}
static const bool is_iec559 = false;
static const bool is_bounded = false;
static const bool is_modulo = false;
static const bool traps = false;
static const bool tinyness_before = false;
static const float_round_style round_style = round_toward_zero;
};
template <class _Tp, int __digits, bool _IsSigned>
struct __libcpp_compute_min
{
static const _Tp value = _Tp(_Tp(1) << __digits);
};
template <class _Tp, int __digits>
struct __libcpp_compute_min<_Tp, __digits, false>
{
static const _Tp value = _Tp(0);
};
template <class _Tp>
class __libcpp_numeric_limits<_Tp, true>
{
protected:
typedef _Tp type;
static const bool is_specialized = true;
static const bool is_signed = type(-1) < type(0);
static const int digits = static_cast<int>(sizeof(type) * 8 - is_signed);
static const int digits10 = digits * 3 / 10;
static const int max_digits10 = 0;
static const type __min = __libcpp_compute_min<type, digits, is_signed>::value;
static const type __max = is_signed ? type(type(~0) ^ __min) : type(~0);
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return __min;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return __max;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return min();}
static const bool is_integer = true;
static const bool is_exact = true;
static const int radix = 2;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return type(0);}
static const int min_exponent = 0;
static const int min_exponent10 = 0;
static const int max_exponent = 0;
static const int max_exponent10 = 0;
static const bool has_infinity = false;
static const bool has_quiet_NaN = false;
static const bool has_signaling_NaN = false;
static const float_denorm_style has_denorm = denorm_absent;
static const bool has_denorm_loss = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return type(0);}
static const bool is_iec559 = false;
static const bool is_bounded = true;
static const bool is_modulo = !std::__1::is_signed<_Tp>::value;
static const bool traps = true;
static const bool tinyness_before = false;
static const float_round_style round_style = round_toward_zero;
};
template <>
class __libcpp_numeric_limits<bool, true>
{
protected:
typedef bool type;
static const bool is_specialized = true;
static const bool is_signed = false;
static const int digits = 1;
static const int digits10 = 0;
static const int max_digits10 = 0;
static const type __min = false;
static const type __max = true;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return __min;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return __max;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return min();}
static const bool is_integer = true;
static const bool is_exact = true;
static const int radix = 2;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return type(0);}
static const int min_exponent = 0;
static const int min_exponent10 = 0;
static const int max_exponent = 0;
static const int max_exponent10 = 0;
static const bool has_infinity = false;
static const bool has_quiet_NaN = false;
static const bool has_signaling_NaN = false;
static const float_denorm_style has_denorm = denorm_absent;
static const bool has_denorm_loss = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return type(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return type(0);}
static const bool is_iec559 = false;
static const bool is_bounded = true;
static const bool is_modulo = false;
static const bool traps = false;
static const bool tinyness_before = false;
static const float_round_style round_style = round_toward_zero;
};
template <>
class __libcpp_numeric_limits<float, true>
{
protected:
typedef float type;
static const bool is_specialized = true;
static const bool is_signed = true;
static const int digits = 24;
static const int digits10 = 6;
static const int max_digits10 = 2+(digits * 30103l)/100000l;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return 1.17549435e-38F;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return 3.40282347e+38F;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return -max();}
static const bool is_integer = false;
static const bool is_exact = false;
static const int radix = 2;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return 1.19209290e-7F;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return 0.5F;}
static const int min_exponent = (-125);
static const int min_exponent10 = (-37);
static const int max_exponent = 128;
static const int max_exponent10 = 38;
static const bool has_infinity = true;
static const bool has_quiet_NaN = true;
static const bool has_signaling_NaN = true;
static const float_denorm_style has_denorm = denorm_present;
static const bool has_denorm_loss = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __builtin_huge_valf();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __builtin_nanf("");}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __builtin_nansf("");}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return 1.40129846e-45F;}
static const bool is_iec559 = true;
static const bool is_bounded = true;
static const bool is_modulo = false;
static const bool traps = false;
static const bool tinyness_before = false;
static const float_round_style round_style = round_to_nearest;
};
template <>
class __libcpp_numeric_limits<double, true>
{
protected:
typedef double type;
static const bool is_specialized = true;
static const bool is_signed = true;
static const int digits = 53;
static const int digits10 = 15;
static const int max_digits10 = 2+(digits * 30103l)/100000l;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return 2.2250738585072014e-308;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return 1.7976931348623157e+308;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return -max();}
static const bool is_integer = false;
static const bool is_exact = false;
static const int radix = 2;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return 2.2204460492503131e-16;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return 0.5;}
static const int min_exponent = (-1021);
static const int min_exponent10 = (-307);
static const int max_exponent = 1024;
static const int max_exponent10 = 308;
static const bool has_infinity = true;
static const bool has_quiet_NaN = true;
static const bool has_signaling_NaN = true;
static const float_denorm_style has_denorm = denorm_present;
static const bool has_denorm_loss = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __builtin_huge_val();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __builtin_nan("");}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __builtin_nans("");}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return 4.9406564584124654e-324;}
static const bool is_iec559 = true;
static const bool is_bounded = true;
static const bool is_modulo = false;
static const bool traps = false;
static const bool tinyness_before = false;
static const float_round_style round_style = round_to_nearest;
};
template <>
class __libcpp_numeric_limits<long double, true>
{
protected:
typedef long double type;
static const bool is_specialized = true;
static const bool is_signed = true;
static const int digits = 64;
static const int digits10 = 18;
static const int max_digits10 = 2+(digits * 30103l)/100000l;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return 3.36210314311209350626e-4932L;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return 1.18973149535723176502e+4932L;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return -max();}
static const bool is_integer = false;
static const bool is_exact = false;
static const int radix = 2;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return 1.08420217248550443401e-19L;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return 0.5;}
static const int min_exponent = (-16381);
static const int min_exponent10 = (-4931);
static const int max_exponent = 16384;
static const int max_exponent10 = 4932;
static const bool has_infinity = true;
static const bool has_quiet_NaN = true;
static const bool has_signaling_NaN = true;
static const float_denorm_style has_denorm = denorm_present;
static const bool has_denorm_loss = false;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __builtin_huge_vall();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __builtin_nanl("");}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __builtin_nansl("");}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return 3.64519953188247460253e-4951L;}
static const bool is_iec559 = true;
static const bool is_bounded = true;
static const bool is_modulo = false;
static const bool traps = false;
static const bool tinyness_before = false;
static const float_round_style round_style = round_to_nearest;
};
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) numeric_limits
: private __libcpp_numeric_limits<typename remove_cv<_Tp>::type>
{
typedef __libcpp_numeric_limits<typename remove_cv<_Tp>::type> __base;
typedef typename __base::type type;
public:
static const bool is_specialized = __base::is_specialized;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return __base::min();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return __base::max();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return __base::lowest();}
static const int digits = __base::digits;
static const int digits10 = __base::digits10;
static const int max_digits10 = __base::max_digits10;
static const bool is_signed = __base::is_signed;
static const bool is_integer = __base::is_integer;
static const bool is_exact = __base::is_exact;
static const int radix = __base::radix;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return __base::epsilon();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return __base::round_error();}
static const int min_exponent = __base::min_exponent;
static const int min_exponent10 = __base::min_exponent10;
static const int max_exponent = __base::max_exponent;
static const int max_exponent10 = __base::max_exponent10;
static const bool has_infinity = __base::has_infinity;
static const bool has_quiet_NaN = __base::has_quiet_NaN;
static const bool has_signaling_NaN = __base::has_signaling_NaN;
static const float_denorm_style has_denorm = __base::has_denorm;
static const bool has_denorm_loss = __base::has_denorm_loss;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __base::infinity();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __base::quiet_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __base::signaling_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return __base::denorm_min();}
static const bool is_iec559 = __base::is_iec559;
static const bool is_bounded = __base::is_bounded;
static const bool is_modulo = __base::is_modulo;
static const bool traps = __base::traps;
static const bool tinyness_before = __base::tinyness_before;
static const float_round_style round_style = __base::round_style;
};
template <class _Tp>
const bool numeric_limits<_Tp>::is_specialized;
template <class _Tp>
const int numeric_limits<_Tp>::digits;
template <class _Tp>
const int numeric_limits<_Tp>::digits10;
template <class _Tp>
const int numeric_limits<_Tp>::max_digits10;
template <class _Tp>
const bool numeric_limits<_Tp>::is_signed;
template <class _Tp>
const bool numeric_limits<_Tp>::is_integer;
template <class _Tp>
const bool numeric_limits<_Tp>::is_exact;
template <class _Tp>
const int numeric_limits<_Tp>::radix;
template <class _Tp>
const int numeric_limits<_Tp>::min_exponent;
template <class _Tp>
const int numeric_limits<_Tp>::min_exponent10;
template <class _Tp>
const int numeric_limits<_Tp>::max_exponent;
template <class _Tp>
const int numeric_limits<_Tp>::max_exponent10;
template <class _Tp>
const bool numeric_limits<_Tp>::has_infinity;
template <class _Tp>
const bool numeric_limits<_Tp>::has_quiet_NaN;
template <class _Tp>
const bool numeric_limits<_Tp>::has_signaling_NaN;
template <class _Tp>
const float_denorm_style numeric_limits<_Tp>::has_denorm;
template <class _Tp>
const bool numeric_limits<_Tp>::has_denorm_loss;
template <class _Tp>
const bool numeric_limits<_Tp>::is_iec559;
template <class _Tp>
const bool numeric_limits<_Tp>::is_bounded;
template <class _Tp>
const bool numeric_limits<_Tp>::is_modulo;
template <class _Tp>
const bool numeric_limits<_Tp>::traps;
template <class _Tp>
const bool numeric_limits<_Tp>::tinyness_before;
template <class _Tp>
const float_round_style numeric_limits<_Tp>::round_style;
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) numeric_limits<const _Tp>
: private numeric_limits<_Tp>
{
typedef numeric_limits<_Tp> __base;
typedef _Tp type;
public:
static const bool is_specialized = __base::is_specialized;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return __base::min();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return __base::max();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return __base::lowest();}
static const int digits = __base::digits;
static const int digits10 = __base::digits10;
static const int max_digits10 = __base::max_digits10;
static const bool is_signed = __base::is_signed;
static const bool is_integer = __base::is_integer;
static const bool is_exact = __base::is_exact;
static const int radix = __base::radix;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return __base::epsilon();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return __base::round_error();}
static const int min_exponent = __base::min_exponent;
static const int min_exponent10 = __base::min_exponent10;
static const int max_exponent = __base::max_exponent;
static const int max_exponent10 = __base::max_exponent10;
static const bool has_infinity = __base::has_infinity;
static const bool has_quiet_NaN = __base::has_quiet_NaN;
static const bool has_signaling_NaN = __base::has_signaling_NaN;
static const float_denorm_style has_denorm = __base::has_denorm;
static const bool has_denorm_loss = __base::has_denorm_loss;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __base::infinity();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __base::quiet_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __base::signaling_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return __base::denorm_min();}
static const bool is_iec559 = __base::is_iec559;
static const bool is_bounded = __base::is_bounded;
static const bool is_modulo = __base::is_modulo;
static const bool traps = __base::traps;
static const bool tinyness_before = __base::tinyness_before;
static const float_round_style round_style = __base::round_style;
};
template <class _Tp>
const bool numeric_limits<const _Tp>::is_specialized;
template <class _Tp>
const int numeric_limits<const _Tp>::digits;
template <class _Tp>
const int numeric_limits<const _Tp>::digits10;
template <class _Tp>
const int numeric_limits<const _Tp>::max_digits10;
template <class _Tp>
const bool numeric_limits<const _Tp>::is_signed;
template <class _Tp>
const bool numeric_limits<const _Tp>::is_integer;
template <class _Tp>
const bool numeric_limits<const _Tp>::is_exact;
template <class _Tp>
const int numeric_limits<const _Tp>::radix;
template <class _Tp>
const int numeric_limits<const _Tp>::min_exponent;
template <class _Tp>
const int numeric_limits<const _Tp>::min_exponent10;
template <class _Tp>
const int numeric_limits<const _Tp>::max_exponent;
template <class _Tp>
const int numeric_limits<const _Tp>::max_exponent10;
template <class _Tp>
const bool numeric_limits<const _Tp>::has_infinity;
template <class _Tp>
const bool numeric_limits<const _Tp>::has_quiet_NaN;
template <class _Tp>
const bool numeric_limits<const _Tp>::has_signaling_NaN;
template <class _Tp>
const float_denorm_style numeric_limits<const _Tp>::has_denorm;
template <class _Tp>
const bool numeric_limits<const _Tp>::has_denorm_loss;
template <class _Tp>
const bool numeric_limits<const _Tp>::is_iec559;
template <class _Tp>
const bool numeric_limits<const _Tp>::is_bounded;
template <class _Tp>
const bool numeric_limits<const _Tp>::is_modulo;
template <class _Tp>
const bool numeric_limits<const _Tp>::traps;
template <class _Tp>
const bool numeric_limits<const _Tp>::tinyness_before;
template <class _Tp>
const float_round_style numeric_limits<const _Tp>::round_style;
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) numeric_limits<volatile _Tp>
: private numeric_limits<_Tp>
{
typedef numeric_limits<_Tp> __base;
typedef _Tp type;
public:
static const bool is_specialized = __base::is_specialized;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return __base::min();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return __base::max();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return __base::lowest();}
static const int digits = __base::digits;
static const int digits10 = __base::digits10;
static const int max_digits10 = __base::max_digits10;
static const bool is_signed = __base::is_signed;
static const bool is_integer = __base::is_integer;
static const bool is_exact = __base::is_exact;
static const int radix = __base::radix;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return __base::epsilon();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return __base::round_error();}
static const int min_exponent = __base::min_exponent;
static const int min_exponent10 = __base::min_exponent10;
static const int max_exponent = __base::max_exponent;
static const int max_exponent10 = __base::max_exponent10;
static const bool has_infinity = __base::has_infinity;
static const bool has_quiet_NaN = __base::has_quiet_NaN;
static const bool has_signaling_NaN = __base::has_signaling_NaN;
static const float_denorm_style has_denorm = __base::has_denorm;
static const bool has_denorm_loss = __base::has_denorm_loss;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __base::infinity();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __base::quiet_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __base::signaling_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return __base::denorm_min();}
static const bool is_iec559 = __base::is_iec559;
static const bool is_bounded = __base::is_bounded;
static const bool is_modulo = __base::is_modulo;
static const bool traps = __base::traps;
static const bool tinyness_before = __base::tinyness_before;
static const float_round_style round_style = __base::round_style;
};
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_specialized;
template <class _Tp>
const int numeric_limits<volatile _Tp>::digits;
template <class _Tp>
const int numeric_limits<volatile _Tp>::digits10;
template <class _Tp>
const int numeric_limits<volatile _Tp>::max_digits10;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_signed;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_integer;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_exact;
template <class _Tp>
const int numeric_limits<volatile _Tp>::radix;
template <class _Tp>
const int numeric_limits<volatile _Tp>::min_exponent;
template <class _Tp>
const int numeric_limits<volatile _Tp>::min_exponent10;
template <class _Tp>
const int numeric_limits<volatile _Tp>::max_exponent;
template <class _Tp>
const int numeric_limits<volatile _Tp>::max_exponent10;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::has_infinity;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::has_quiet_NaN;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::has_signaling_NaN;
template <class _Tp>
const float_denorm_style numeric_limits<volatile _Tp>::has_denorm;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::has_denorm_loss;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_iec559;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_bounded;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::is_modulo;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::traps;
template <class _Tp>
const bool numeric_limits<volatile _Tp>::tinyness_before;
template <class _Tp>
const float_round_style numeric_limits<volatile _Tp>::round_style;
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) numeric_limits<const volatile _Tp>
: private numeric_limits<_Tp>
{
typedef numeric_limits<_Tp> __base;
typedef _Tp type;
public:
static const bool is_specialized = __base::is_specialized;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type min() throw() {return __base::min();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type max() throw() {return __base::max();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type lowest() throw() {return __base::lowest();}
static const int digits = __base::digits;
static const int digits10 = __base::digits10;
static const int max_digits10 = __base::max_digits10;
static const bool is_signed = __base::is_signed;
static const bool is_integer = __base::is_integer;
static const bool is_exact = __base::is_exact;
static const int radix = __base::radix;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type epsilon() throw() {return __base::epsilon();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type round_error() throw() {return __base::round_error();}
static const int min_exponent = __base::min_exponent;
static const int min_exponent10 = __base::min_exponent10;
static const int max_exponent = __base::max_exponent;
static const int max_exponent10 = __base::max_exponent10;
static const bool has_infinity = __base::has_infinity;
static const bool has_quiet_NaN = __base::has_quiet_NaN;
static const bool has_signaling_NaN = __base::has_signaling_NaN;
static const float_denorm_style has_denorm = __base::has_denorm;
static const bool has_denorm_loss = __base::has_denorm_loss;
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type infinity() throw() {return __base::infinity();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type quiet_NaN() throw() {return __base::quiet_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type signaling_NaN() throw() {return __base::signaling_NaN();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static type denorm_min() throw() {return __base::denorm_min();}
static const bool is_iec559 = __base::is_iec559;
static const bool is_bounded = __base::is_bounded;
static const bool is_modulo = __base::is_modulo;
static const bool traps = __base::traps;
static const bool tinyness_before = __base::tinyness_before;
static const float_round_style round_style = __base::round_style;
};
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_specialized;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::digits;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::digits10;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::max_digits10;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_signed;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_integer;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_exact;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::radix;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::min_exponent;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::min_exponent10;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::max_exponent;
template <class _Tp>
const int numeric_limits<const volatile _Tp>::max_exponent10;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::has_infinity;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::has_quiet_NaN;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::has_signaling_NaN;
template <class _Tp>
const float_denorm_style numeric_limits<const volatile _Tp>::has_denorm;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::has_denorm_loss;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_iec559;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_bounded;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::is_modulo;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::traps;
template <class _Tp>
const bool numeric_limits<const volatile _Tp>::tinyness_before;
template <class _Tp>
const float_round_style numeric_limits<const volatile _Tp>::round_style;
} }
# 659 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 1 3
# 416 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iosfwd" 1 3
# 90 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iosfwd" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wchar.h" 1 3
# 113 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wchar.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 1 3 4
# 76 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_mbstate_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_mbstate_t.h" 3 4
typedef __darwin_mbstate_t mbstate_t;
# 77 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_wchar_t.h" 1 3 4
# 80 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 2 3 4
# 89 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 3 4
# 1 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stdarg.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stdarg.h" 3 4
typedef __builtin_va_list va_list;
# 48 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/stdarg.h" 3 4
typedef __builtin_va_list __gnuc_va_list;
# 90 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdio.h" 1 3 4
# 106 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdio.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 1 3 4
# 64 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_stdio.h" 1 3 4
# 75 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_stdio.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_va_list.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_va_list.h" 3 4
typedef __darwin_va_list va_list;
# 76 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_stdio.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/stdio.h" 1 3 4
# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/stdio.h" 3 4
extern "C" {
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/MacOSX10.14.sdk/usr/include/_stdio.h" 2 3 4
typedef __darwin_off_t fpos_t;
# 92 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_stdio.h" 3 4
struct __sbuf {
unsigned char *_base;
int _size;
};
struct __sFILEX;
# 126 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.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/MacOSX10.14.sdk/usr/include/stdio.h" 2 3 4
extern "C" {
extern FILE *__stdinp;
extern FILE *__stdoutp;
extern FILE *__stderrp;
}
# 141 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
extern "C" {
void clearerr(FILE *);
int fclose(FILE *);
int feof(FILE *);
int ferror(FILE *);
int fflush(FILE *);
int fgetc(FILE *);
int fgetpos(FILE * , fpos_t *);
char *fgets(char * , int, FILE *);
FILE *fopen(const char * __filename, const char * __mode) __asm("_" "fopen" );
int fprintf(FILE * , const char * , ...) __attribute__((__format__ (__printf__, 2, 3)));
int fputc(int, FILE *);
int fputs(const char * , FILE * ) __asm("_" "fputs" );
size_t fread(void * __ptr, size_t __size, size_t __nitems, FILE * __stream);
FILE *freopen(const char * , const char * ,
FILE * ) __asm("_" "freopen" );
int fscanf(FILE * , const char * , ...) __attribute__((__format__ (__scanf__, 2, 3)));
int fseek(FILE *, long, int);
int fsetpos(FILE *, const fpos_t *);
long ftell(FILE *);
size_t fwrite(const void * __ptr, size_t __size, size_t __nitems, FILE * __stream) __asm("_" "fwrite" );
int getc(FILE *);
int getchar(void);
char *gets(char *);
void perror(const char *);
int printf(const char * , ...) __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 * , ...) __attribute__((__format__ (__scanf__, 1, 2)));
void setbuf(FILE * , char * );
int setvbuf(FILE * , char * , int, size_t);
int sprintf(char * , const char * , ...) __attribute__((__format__ (__printf__, 2, 3))) __attribute__((__availability__(swift, unavailable, message="Use snprintf instead.")));
int sscanf(const char * , const char * , ...) __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 * , const char * , va_list) __attribute__((__format__ (__printf__, 2, 0)));
int vprintf(const char * , va_list) __attribute__((__format__ (__printf__, 1, 0)));
int vsprintf(char * , const char * , va_list) __attribute__((__format__ (__printf__, 2, 0))) __attribute__((__availability__(swift, unavailable, message="Use vsnprintf instead.")));
}
# 204 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
extern "C" {
char *ctermid(char *);
FILE *fdopen(int, const char *) __asm("_" "fdopen" );
int fileno(FILE *);
}
# 231 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
extern "C" {
int pclose(FILE *) __attribute__((__availability__(swift, unavailable, message="Use posix_spawn APIs or NSTask instead.")));
FILE *popen(const char *, const char *) __asm("_" "popen" ) __attribute__((__availability__(swift, unavailable, message="Use posix_spawn APIs or NSTask instead.")));
}
# 252 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
extern "C" {
int __srget(FILE *);
int __svfscanf(FILE *, const char *, va_list) __attribute__((__format__ (__scanf__, 2, 0)));
int __swbuf(int, FILE *);
}
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));
}
# 289 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
extern "C" {
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" );
}
# 328 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_off_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_off_t.h" 3 4
typedef __darwin_off_t off_t;
# 329 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 2 3 4
extern "C" {
int fseeko(FILE * __stream, off_t __offset, int __whence);
off_t ftello(FILE * __stream);
}
extern "C" {
int snprintf(char * __str, size_t __size, const char * __format, ...) __attribute__((__format__ (__printf__, 3, 4)));
int vfscanf(FILE * __stream, const char * __format, va_list) __attribute__((__format__ (__scanf__, 2, 0)));
int vscanf(const char * __format, va_list) __attribute__((__format__ (__scanf__, 1, 0)));
int vsnprintf(char * __str, size_t __size, const char * __format, va_list) __attribute__((__format__ (__printf__, 3, 0)));
int vsscanf(const char * __str, const char * __format, va_list) __attribute__((__format__ (__scanf__, 2, 0)));
}
# 355 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/stdio.h" 3 4
extern "C" {
int dprintf(int, const char * , ...) __attribute__((__format__ (__printf__, 2, 3))) __attribute__((availability(macosx,introduced=10.7)));
int vdprintf(int, const char * , va_list) __attribute__((__format__ (__printf__, 2, 0))) __attribute__((availability(macosx,introduced=10.7)));
ssize_t getdelim(char ** __linep, size_t * __linecapp, int __delimiter, FILE * __stream) __attribute__((availability(macosx,introduced=10.7)));
ssize_t getline(char ** __linep, size_t * __linecapp, FILE * __stream) __attribute__((availability(macosx,introduced=10.7)));
FILE *fmemopen(void * __buf, size_t __size, const char * __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)));
}
extern "C" {
extern const int sys_nerr;
extern const char *const sys_errlist[];
int asprintf(char ** , const char * , ...) __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 ** , const char * , va_list) __attribute__((__format__ (__printf__, 2, 0)));
FILE *zopen(const char *, const char *, int);
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 *));
}
# 109 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdio.h" 2 3
# 91 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_wctype.h" 1 3 4
# 42 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_wctype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/__wctype.h" 1 3 4
# 60 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/__wctype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_wint_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_wint_t.h" 3 4
typedef __darwin_wint_t wint_t;
# 61 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/__wctype.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_wctype_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_wctype_t.h" 3 4
typedef __darwin_wctype_t wctype_t;
# 63 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/__wctype.h" 2 3 4
# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/__wctype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctype.h" 1 3 4
# 37 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctype.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/ctype.h" 1 3 4
# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/ctype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_ctype.h" 1 3 4
# 70 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_ctype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/runetype.h" 1 3 4
# 49 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/runetype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_wchar_t.h" 1 3 4
# 50 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/runetype.h" 2 3 4
# 60 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/runetype.h" 3 4
typedef struct {
__darwin_rune_t __min;
__darwin_rune_t __max;
__darwin_rune_t __map;
__uint32_t *__types;
} _RuneEntry;
typedef struct {
int __nranges;
_RuneEntry *__ranges;
} _RuneRange;
typedef struct {
char __name[14];
__uint32_t __mask;
} _RuneCharClass;
typedef struct {
char __magic[8];
char __encoding[32];
__darwin_rune_t (*__sgetrune)(const char *, __darwin_size_t, char const **);
int (*__sputrune)(__darwin_rune_t, char *, __darwin_size_t, char **);
__darwin_rune_t __invalid_rune;
__uint32_t __runetype[(1 <<8 )];
__darwin_rune_t __maplower[(1 <<8 )];
__darwin_rune_t __mapupper[(1 <<8 )];
_RuneRange __runetype_ext;
_RuneRange __maplower_ext;
_RuneRange __mapupper_ext;
void *__variable;
int __variable_len;
int __ncharclasses;
_RuneCharClass *__charclasses;
} _RuneLocale;
extern "C" {
extern _RuneLocale _DefaultRuneLocale;
extern _RuneLocale *_CurrentRuneLocale;
}
# 71 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_ctype.h" 2 3 4
# 128 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_ctype.h" 3 4
extern "C" {
unsigned long ___runetype(__darwin_ct_rune_t);
__darwin_ct_rune_t ___tolower(__darwin_ct_rune_t);
__darwin_ct_rune_t ___toupper(__darwin_ct_rune_t);
}
inline int
isascii(int _c)
{
return ((_c & ~0x7F) == 0);
}
# 147 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_ctype.h" 3 4
extern "C" {
int __maskrune(__darwin_ct_rune_t, unsigned long);
}
inline int
__istype(__darwin_ct_rune_t _c, unsigned long _f)
{
return (isascii(_c) ? !!(_DefaultRuneLocale.__runetype[_c] & _f)
: !!__maskrune(_c, _f));
}
inline __darwin_ct_rune_t
__isctype(__darwin_ct_rune_t _c, unsigned long _f)
{
return (_c < 0 || _c >= (1 <<8 )) ? 0 :
!!(_DefaultRuneLocale.__runetype[_c] & _f);
}
# 187 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_ctype.h" 3 4
extern "C" {
__darwin_ct_rune_t __toupper(__darwin_ct_rune_t);
__darwin_ct_rune_t __tolower(__darwin_ct_rune_t);
}
inline int
__wcwidth(__darwin_ct_rune_t _c)
{
unsigned int _x;
if (_c == 0)
return (0);
_x = (unsigned int)__maskrune(_c, 0xe0000000L|0x00040000L);
if ((_x & 0xe0000000L) != 0)
return ((_x & 0xe0000000L) >> 30);
return ((_x & 0x00040000L) != 0 ? 1 : -1);
}
inline int
isalnum(int _c)
{
return (__istype(_c, 0x00000100L|0x00000400L));
}
inline int
isalpha(int _c)
{
return (__istype(_c, 0x00000100L));
}
inline int
isblank(int _c)
{
return (__istype(_c, 0x00020000L));
}
inline int
iscntrl(int _c)
{
return (__istype(_c, 0x00000200L));
}
inline int
isdigit(int _c)
{
return (__isctype(_c, 0x00000400L));
}
inline int
isgraph(int _c)
{
return (__istype(_c, 0x00000800L));
}
inline int
islower(int _c)
{
return (__istype(_c, 0x00001000L));
}
inline int
isprint(int _c)
{
return (__istype(_c, 0x00040000L));
}
inline int
ispunct(int _c)
{
return (__istype(_c, 0x00002000L));
}
inline int
isspace(int _c)
{
return (__istype(_c, 0x00004000L));
}
inline int
isupper(int _c)
{
return (__istype(_c, 0x00008000L));
}
inline int
isxdigit(int _c)
{
return (__isctype(_c, 0x00010000L));
}
inline int
toascii(int _c)
{
return (_c & 0x7F);
}
inline int
tolower(int _c)
{
return (__tolower(_c));
}
inline int
toupper(int _c)
{
return (__toupper(_c));
}
inline int
digittoint(int _c)
{
return (__maskrune(_c, 0x0F));
}
inline int
ishexnumber(int _c)
{
return (__istype(_c, 0x00010000L));
}
inline int
isideogram(int _c)
{
return (__istype(_c, 0x00080000L));
}
inline int
isnumber(int _c)
{
return (__istype(_c, 0x00000400L));
}
inline int
isphonogram(int _c)
{
return (__istype(_c, 0x00200000L));
}
inline int
isrune(int _c)
{
return (__istype(_c, 0xFFFFFFF0L));
}
inline int
isspecial(int _c)
{
return (__istype(_c, 0x00100000L));
}
# 70 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/ctype.h" 2 3 4
# 40 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ctype.h" 2 3
# 73 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/__wctype.h" 2 3 4
# 43 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_wctype.h" 2 3 4
inline int
iswalnum(wint_t _wc)
{
return (__istype(_wc, 0x00000100L|0x00000400L));
}
inline int
iswalpha(wint_t _wc)
{
return (__istype(_wc, 0x00000100L));
}
inline int
iswcntrl(wint_t _wc)
{
return (__istype(_wc, 0x00000200L));
}
inline int
iswctype(wint_t _wc, wctype_t _charclass)
{
return (__istype(_wc, _charclass));
}
inline int
iswdigit(wint_t _wc)
{
return (__isctype(_wc, 0x00000400L));
}
inline int
iswgraph(wint_t _wc)
{
return (__istype(_wc, 0x00000800L));
}
inline int
iswlower(wint_t _wc)
{
return (__istype(_wc, 0x00001000L));
}
inline int
iswprint(wint_t _wc)
{
return (__istype(_wc, 0x00040000L));
}
inline int
iswpunct(wint_t _wc)
{
return (__istype(_wc, 0x00002000L));
}
inline int
iswspace(wint_t _wc)
{
return (__istype(_wc, 0x00004000L));
}
inline int
iswupper(wint_t _wc)
{
return (__istype(_wc, 0x00008000L));
}
inline int
iswxdigit(wint_t _wc)
{
return (__isctype(_wc, 0x00010000L));
}
inline wint_t
towlower(wint_t _wc)
{
return (__tolower(_wc));
}
inline wint_t
towupper(wint_t _wc)
{
return (__toupper(_wc));
}
# 155 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_wctype.h" 3 4
extern "C" {
wctype_t
wctype(const char *);
}
# 93 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 2 3 4
extern "C" {
wint_t btowc(int);
wint_t fgetwc(FILE *);
wchar_t *fgetws(wchar_t * , int, FILE * );
wint_t fputwc(wchar_t, FILE *);
int fputws(const wchar_t * , FILE * );
int fwide(FILE *, int);
int fwprintf(FILE * , const wchar_t * , ...);
int fwscanf(FILE * , const wchar_t * , ...);
wint_t getwc(FILE *);
wint_t getwchar(void);
size_t mbrlen(const char * , size_t, mbstate_t * );
size_t mbrtowc(wchar_t * , const char * , size_t,
mbstate_t * );
int mbsinit(const mbstate_t *);
size_t mbsrtowcs(wchar_t * , const char ** , size_t,
mbstate_t * );
wint_t putwc(wchar_t, FILE *);
wint_t putwchar(wchar_t);
int swprintf(wchar_t * , size_t, const wchar_t * , ...);
int swscanf(const wchar_t * , const wchar_t * , ...);
wint_t ungetwc(wint_t, FILE *);
int vfwprintf(FILE * , const wchar_t * ,
__darwin_va_list);
int vswprintf(wchar_t * , size_t, const wchar_t * ,
__darwin_va_list);
int vwprintf(const wchar_t * , __darwin_va_list);
size_t wcrtomb(char * , wchar_t, mbstate_t * );
wchar_t *wcscat(wchar_t * , const wchar_t * );
wchar_t *wcschr(const wchar_t *, wchar_t);
int wcscmp(const wchar_t *, const wchar_t *);
int wcscoll(const wchar_t *, const wchar_t *);
wchar_t *wcscpy(wchar_t * , const wchar_t * );
size_t wcscspn(const wchar_t *, const wchar_t *);
size_t wcsftime(wchar_t * , size_t, const wchar_t * ,
const struct tm * ) __asm("_" "wcsftime" );
size_t wcslen(const wchar_t *);
wchar_t *wcsncat(wchar_t * , const wchar_t * , size_t);
int wcsncmp(const wchar_t *, const wchar_t *, size_t);
wchar_t *wcsncpy(wchar_t * , const wchar_t * , size_t);
wchar_t *wcspbrk(const wchar_t *, const wchar_t *);
wchar_t *wcsrchr(const wchar_t *, wchar_t);
size_t wcsrtombs(char * , const wchar_t ** , size_t,
mbstate_t * );
size_t wcsspn(const wchar_t *, const wchar_t *);
wchar_t *wcsstr(const wchar_t * , const wchar_t * );
size_t wcsxfrm(wchar_t * , const wchar_t * , size_t);
int wctob(wint_t);
double wcstod(const wchar_t * , wchar_t ** );
wchar_t *wcstok(wchar_t * , const wchar_t * ,
wchar_t ** );
long wcstol(const wchar_t * , wchar_t ** , int);
unsigned long
wcstoul(const wchar_t * , wchar_t ** , int);
wchar_t *wmemchr(const wchar_t *, wchar_t, size_t);
int wmemcmp(const wchar_t *, const wchar_t *, size_t);
wchar_t *wmemcpy(wchar_t * , const wchar_t * , size_t);
wchar_t *wmemmove(wchar_t *, const wchar_t *, size_t);
wchar_t *wmemset(wchar_t *, wchar_t, size_t);
int wprintf(const wchar_t * , ...);
int wscanf(const wchar_t * , ...);
int wcswidth(const wchar_t *, size_t);
int wcwidth(wchar_t);
}
# 169 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 3 4
extern "C" {
int vfwscanf(FILE * , const wchar_t * ,
__darwin_va_list);
int vswscanf(const wchar_t * , const wchar_t * ,
__darwin_va_list);
int vwscanf(const wchar_t * , __darwin_va_list);
float wcstof(const wchar_t * , wchar_t ** );
long double
wcstold(const wchar_t * , wchar_t ** );
long long
wcstoll(const wchar_t * , wchar_t ** , int);
unsigned long long
wcstoull(const wchar_t * , wchar_t ** , int);
}
# 194 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wchar.h" 3 4
extern "C" {
size_t mbsnrtowcs(wchar_t * , const char ** , size_t,
size_t, mbstate_t * );
wchar_t *wcpcpy(wchar_t * , const wchar_t * ) __attribute__((availability(macosx,introduced=10.7)));
wchar_t *wcpncpy(wchar_t * , const wchar_t * , size_t) __attribute__((availability(macosx,introduced=10.7)));
wchar_t *wcsdup(const wchar_t *) __attribute__((availability(macosx,introduced=10.7)));
int wcscasecmp(const wchar_t *, const wchar_t *) __attribute__((availability(macosx,introduced=10.7)));
int wcsncasecmp(const wchar_t *, const wchar_t *, size_t n) __attribute__((availability(macosx,introduced=10.7)));
size_t wcsnlen(const wchar_t *, size_t) __attribute__((availability(macosx,introduced=10.7)));
size_t wcsnrtombs(char * , const wchar_t ** , size_t,
size_t, mbstate_t * );
FILE *open_wmemstream(wchar_t ** __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)));
}
extern "C" {
wchar_t *fgetwln(FILE * , size_t *) __attribute__((availability(macosx,introduced=10.7)));
size_t wcslcat(wchar_t *, const wchar_t *, size_t);
size_t wcslcpy(wchar_t *, const wchar_t *, size_t);
}
# 120 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wchar.h" 2 3
# 135 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wchar.h" 3
extern "C++" {
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
wchar_t* __libcpp_wcschr(const wchar_t* __s, wchar_t __c) {return (wchar_t*)wcschr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const wchar_t* wcschr(const wchar_t* __s, wchar_t __c) {return __libcpp_wcschr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
wchar_t* wcschr( wchar_t* __s, wchar_t __c) {return __libcpp_wcschr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
wchar_t* __libcpp_wcspbrk(const wchar_t* __s1, const wchar_t* __s2) {return (wchar_t*)wcspbrk(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const wchar_t* wcspbrk(const wchar_t* __s1, const wchar_t* __s2) {return __libcpp_wcspbrk(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
wchar_t* wcspbrk( wchar_t* __s1, const wchar_t* __s2) {return __libcpp_wcspbrk(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
wchar_t* __libcpp_wcsrchr(const wchar_t* __s, wchar_t __c) {return (wchar_t*)wcsrchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const wchar_t* wcsrchr(const wchar_t* __s, wchar_t __c) {return __libcpp_wcsrchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
wchar_t* wcsrchr( wchar_t* __s, wchar_t __c) {return __libcpp_wcsrchr(__s, __c);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
wchar_t* __libcpp_wcsstr(const wchar_t* __s1, const wchar_t* __s2) {return (wchar_t*)wcsstr(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const wchar_t* wcsstr(const wchar_t* __s1, const wchar_t* __s2) {return __libcpp_wcsstr(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
wchar_t* wcsstr( wchar_t* __s1, const wchar_t* __s2) {return __libcpp_wcsstr(__s1, __s2);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
wchar_t* __libcpp_wmemchr(const wchar_t* __s, wchar_t __c, size_t __n) {return (wchar_t*)wmemchr(__s, __c, __n);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
const wchar_t* wmemchr(const wchar_t* __s, wchar_t __c, size_t __n) {return __libcpp_wmemchr(__s, __c, __n);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) __attribute__ ((__enable_if__(true, "")))
wchar_t* wmemchr( wchar_t* __s, wchar_t __c, size_t __n) {return __libcpp_wmemchr(__s, __c, __n);}
}
# 91 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iosfwd" 2 3
# 94 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iosfwd" 3
namespace std {inline namespace __1 {
class __attribute__ ((__visibility__("default"))) ios_base;
template<class _CharT> struct __attribute__ ((__type_visibility__("default"))) char_traits;
template<class _Tp> class __attribute__ ((__type_visibility__("default"))) allocator;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_ios;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_streambuf;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_istream;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_ostream;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_iostream;
template <class _CharT, class _Traits = char_traits<_CharT>,
class _Allocator = allocator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_stringbuf;
template <class _CharT, class _Traits = char_traits<_CharT>,
class _Allocator = allocator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_istringstream;
template <class _CharT, class _Traits = char_traits<_CharT>,
class _Allocator = allocator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_ostringstream;
template <class _CharT, class _Traits = char_traits<_CharT>,
class _Allocator = allocator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_stringstream;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_filebuf;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_ifstream;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_ofstream;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_fstream;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) istreambuf_iterator;
template <class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) ostreambuf_iterator;
typedef basic_ios<char> ios;
typedef basic_ios<wchar_t> wios;
typedef basic_streambuf<char> streambuf;
typedef basic_istream<char> istream;
typedef basic_ostream<char> ostream;
typedef basic_iostream<char> iostream;
typedef basic_stringbuf<char> stringbuf;
typedef basic_istringstream<char> istringstream;
typedef basic_ostringstream<char> ostringstream;
typedef basic_stringstream<char> stringstream;
typedef basic_filebuf<char> filebuf;
typedef basic_ifstream<char> ifstream;
typedef basic_ofstream<char> ofstream;
typedef basic_fstream<char> fstream;
typedef basic_streambuf<wchar_t> wstreambuf;
typedef basic_istream<wchar_t> wistream;
typedef basic_ostream<wchar_t> wostream;
typedef basic_iostream<wchar_t> wiostream;
typedef basic_stringbuf<wchar_t> wstringbuf;
typedef basic_istringstream<wchar_t> wistringstream;
typedef basic_ostringstream<wchar_t> wostringstream;
typedef basic_stringstream<wchar_t> wstringstream;
typedef basic_filebuf<wchar_t> wfilebuf;
typedef basic_ifstream<wchar_t> wifstream;
typedef basic_ofstream<wchar_t> wofstream;
typedef basic_fstream<wchar_t> wfstream;
template <class _State> class __attribute__ ((__type_visibility__("default"))) fpos;
typedef fpos<mbstate_t> streampos;
typedef fpos<mbstate_t> wstreampos;
typedef fpos<mbstate_t> u16streampos;
typedef fpos<mbstate_t> u32streampos;
typedef long long streamoff;
template <class _CharT,
class _Traits = char_traits<_CharT>,
class _Allocator = allocator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_string;
typedef basic_string<char, char_traits<char>, allocator<char> > string;
typedef basic_string<wchar_t, char_traits<wchar_t>, allocator<wchar_t> > wstring;
template <class _Tp, class _Alloc = allocator<_Tp> >
class __attribute__ ((__type_visibility__("default"))) vector;
} }
# 417 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 1 3
# 23 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 3
namespace std {inline namespace __1 {
template <class _Arg1, class _Arg2, class _Result>
struct __attribute__ ((__type_visibility__("default"))) binary_function
{
typedef _Arg1 first_argument_type;
typedef _Arg2 second_argument_type;
typedef _Result result_type;
};
template <class _Tp>
struct __has_result_type
{
private:
struct __two {char __lx; char __lxx;};
template <class _Up> static __two __test(...);
template <class _Up> static char __test(typename _Up::result_type* = 0);
public:
static const bool value = sizeof(__test<_Tp>(0)) == 1;
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) less : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x < __y;}
};
# 74 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 3
template <class _Tp>
struct __derives_from_unary_function
{
private:
struct __two {char __lx; char __lxx;};
static __two __test(...);
template <class _Ap, class _Rp>
static unary_function<_Ap, _Rp>
__test(const volatile unary_function<_Ap, _Rp>*);
public:
static const bool value = !is_same<__decltype(__test((_Tp*)0)), __two>::value;
typedef __decltype(__test((_Tp*)0)) type;
};
template <class _Tp>
struct __derives_from_binary_function
{
private:
struct __two {char __lx; char __lxx;};
static __two __test(...);
template <class _A1, class _A2, class _Rp>
static binary_function<_A1, _A2, _Rp>
__test(const volatile binary_function<_A1, _A2, _Rp>*);
public:
static const bool value = !is_same<__decltype(__test((_Tp*)0)), __two>::value;
typedef __decltype(__test((_Tp*)0)) type;
};
template <class _Tp, bool = __derives_from_unary_function<_Tp>::value>
struct __maybe_derive_from_unary_function
: public __derives_from_unary_function<_Tp>::type
{
};
template <class _Tp>
struct __maybe_derive_from_unary_function<_Tp, false>
{
};
template <class _Tp, bool = __derives_from_binary_function<_Tp>::value>
struct __maybe_derive_from_binary_function
: public __derives_from_binary_function<_Tp>::type
{
};
template <class _Tp>
struct __maybe_derive_from_binary_function<_Tp, false>
{
};
template <class _Tp, bool = __has_result_type<_Tp>::value>
struct __weak_result_type_imp
: public __maybe_derive_from_unary_function<_Tp>,
public __maybe_derive_from_binary_function<_Tp>
{
typedef typename _Tp::result_type result_type;
};
template <class _Tp>
struct __weak_result_type_imp<_Tp, false>
: public __maybe_derive_from_unary_function<_Tp>,
public __maybe_derive_from_binary_function<_Tp>
{
};
template <class _Tp>
struct __weak_result_type
: public __weak_result_type_imp<_Tp>
{
};
template <class _Rp>
struct __weak_result_type<_Rp ()>
{
typedef _Rp result_type;
};
template <class _Rp>
struct __weak_result_type<_Rp (&)()>
{
typedef _Rp result_type;
};
template <class _Rp>
struct __weak_result_type<_Rp (*)()>
{
typedef _Rp result_type;
};
template <class _Rp, class _A1>
struct __weak_result_type<_Rp (_A1)>
: public unary_function<_A1, _Rp>
{
};
template <class _Rp, class _A1>
struct __weak_result_type<_Rp (&)(_A1)>
: public unary_function<_A1, _Rp>
{
};
template <class _Rp, class _A1>
struct __weak_result_type<_Rp (*)(_A1)>
: public unary_function<_A1, _Rp>
{
};
template <class _Rp, class _Cp>
struct __weak_result_type<_Rp (_Cp::*)()>
: public unary_function<_Cp*, _Rp>
{
};
template <class _Rp, class _Cp>
struct __weak_result_type<_Rp (_Cp::*)() const>
: public unary_function<const _Cp*, _Rp>
{
};
template <class _Rp, class _Cp>
struct __weak_result_type<_Rp (_Cp::*)() volatile>
: public unary_function<volatile _Cp*, _Rp>
{
};
template <class _Rp, class _Cp>
struct __weak_result_type<_Rp (_Cp::*)() const volatile>
: public unary_function<const volatile _Cp*, _Rp>
{
};
template <class _Rp, class _A1, class _A2>
struct __weak_result_type<_Rp (_A1, _A2)>
: public binary_function<_A1, _A2, _Rp>
{
};
template <class _Rp, class _A1, class _A2>
struct __weak_result_type<_Rp (*)(_A1, _A2)>
: public binary_function<_A1, _A2, _Rp>
{
};
template <class _Rp, class _A1, class _A2>
struct __weak_result_type<_Rp (&)(_A1, _A2)>
: public binary_function<_A1, _A2, _Rp>
{
};
template <class _Rp, class _Cp, class _A1>
struct __weak_result_type<_Rp (_Cp::*)(_A1)>
: public binary_function<_Cp*, _A1, _Rp>
{
};
template <class _Rp, class _Cp, class _A1>
struct __weak_result_type<_Rp (_Cp::*)(_A1) const>
: public binary_function<const _Cp*, _A1, _Rp>
{
};
template <class _Rp, class _Cp, class _A1>
struct __weak_result_type<_Rp (_Cp::*)(_A1) volatile>
: public binary_function<volatile _Cp*, _A1, _Rp>
{
};
template <class _Rp, class _Cp, class _A1>
struct __weak_result_type<_Rp (_Cp::*)(_A1) const volatile>
: public binary_function<const volatile _Cp*, _A1, _Rp>
{
};
# 307 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base_03" 1 3
# 18 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base_03" 3
template <class _Ret, class _T1, bool _IsFunc, bool _IsBase>
struct __enable_invoke_imp;
template <class _Ret, class _T1>
struct __enable_invoke_imp<_Ret, _T1, true, true> {
typedef _Ret _Bullet1;
typedef _Bullet1 type;
};
template <class _Ret, class _T1>
struct __enable_invoke_imp<_Ret, _T1, true, false> {
typedef _Ret _Bullet2;
typedef _Bullet2 type;
};
template <class _Ret, class _T1>
struct __enable_invoke_imp<_Ret, _T1, false, true> {
typedef typename add_lvalue_reference<
typename __apply_cv<_T1, _Ret>::type
>::type _Bullet3;
typedef _Bullet3 type;
};
template <class _Ret, class _T1>
struct __enable_invoke_imp<_Ret, _T1, false, false> {
typedef typename add_lvalue_reference<
typename __apply_cv<__decltype(*std::__1::declval<_T1>()), _Ret>::type
>::type _Bullet4;
typedef _Bullet4 type;
};
template <class _Ret, class _T1>
struct __enable_invoke_imp<_Ret, _T1*, false, false> {
typedef typename add_lvalue_reference<
typename __apply_cv<_T1, _Ret>::type
>::type _Bullet4;
typedef _Bullet4 type;
};
template <class _Fn, class _T1,
class _Traits = __member_pointer_traits<_Fn>,
class _Ret = typename _Traits::_ReturnType,
class _Class = typename _Traits::_ClassType>
struct __enable_invoke : __enable_invoke_imp<
_Ret, _T1,
is_member_function_pointer<_Fn>::value,
is_base_of<_Class, typename remove_reference<_T1>::type>::value>
{
};
__nat __invoke(__any, ...);
template <class _Fn, class _T1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet1
__invoke(_Fn __f, _T1& __t1) {
return (__t1.*__f)();
}
template <class _Fn, class _T1, class _A0>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet1
__invoke(_Fn __f, _T1& __t1, _A0& __a0) {
return (__t1.*__f)(__a0);
}
template <class _Fn, class _T1, class _A0, class _A1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet1
__invoke(_Fn __f, _T1& __t1, _A0& __a0, _A1& __a1) {
return (__t1.*__f)(__a0, __a1);
}
template <class _Fn, class _T1, class _A0, class _A1, class _A2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet1
__invoke(_Fn __f, _T1& __t1, _A0& __a0, _A1& __a1, _A2& __a2) {
return (__t1.*__f)(__a0, __a1, __a2);
}
template <class _Fn, class _T1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet2
__invoke(_Fn __f, _T1& __t1) {
return ((*__t1).*__f)();
}
template <class _Fn, class _T1, class _A0>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet2
__invoke(_Fn __f, _T1& __t1, _A0& __a0) {
return ((*__t1).*__f)(__a0);
}
template <class _Fn, class _T1, class _A0, class _A1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet2
__invoke(_Fn __f, _T1& __t1, _A0& __a0, _A1& __a1) {
return ((*__t1).*__f)(__a0, __a1);
}
template <class _Fn, class _T1, class _A0, class _A1, class _A2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet2
__invoke(_Fn __f, _T1& __t1, _A0& __a0, _A1& __a1, _A2& __a2) {
return ((*__t1).*__f)(__a0, __a1, __a2);
}
template <class _Fn, class _T1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet3
__invoke(_Fn __f, _T1& __t1) {
return __t1.*__f;
}
template <class _Fn, class _T1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __enable_invoke<_Fn, _T1>::_Bullet4
__invoke(_Fn __f, _T1& __t1) {
return (*__t1).*__f;
}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__decltype(std::__1::declval<_Fp&>()())
__invoke(_Fp& __f)
{
return __f();
}
template <class _Fp, class _A0>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__decltype(std::__1::declval<_Fp&>()(std::__1::declval<_A0&>()))
__invoke(_Fp& __f, _A0& __a0)
{
return __f(__a0);
}
template <class _Fp, class _A0, class _A1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__decltype(std::__1::declval<_Fp&>()(std::__1::declval<_A0&>(), std::__1::declval<_A1&>()))
__invoke(_Fp& __f, _A0& __a0, _A1& __a1)
{
return __f(__a0, __a1);
}
template <class _Fp, class _A0, class _A1, class _A2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__decltype(std::__1::declval<_Fp&>()(std::__1::declval<_A0&>(), std::__1::declval<_A1&>(), std::__1::declval<_A2&>()))
__invoke(_Fp& __f, _A0& __a0, _A1& __a1, _A2& __a2)
{
return __f(__a0, __a1, __a2);
}
template <class _Fp, bool = __has_result_type<__weak_result_type<_Fp> >::value>
struct __invoke_return
{
typedef typename __weak_result_type<_Fp>::result_type type;
};
template <class _Fp>
struct __invoke_return<_Fp, false>
{
typedef __decltype(__invoke(std::__1::declval<_Fp&>())) type;
};
template <class _Tp, class _A0>
struct __invoke_return0
{
typedef __decltype(__invoke(std::__1::declval<_Tp&>(), std::__1::declval<_A0&>())) type;
};
template <class _Rp, class _Tp, class _A0>
struct __invoke_return0<_Rp _Tp::*, _A0>
{
typedef typename __enable_invoke<_Rp _Tp::*, _A0>::type type;
};
template <class _Tp, class _A0, class _A1>
struct __invoke_return1
{
typedef __decltype(__invoke(std::__1::declval<_Tp&>(), std::__1::declval<_A0&>(), std::__1::declval<_A1&>())) type;
};
template <class _Rp, class _Class, class _A0, class _A1>
struct __invoke_return1<_Rp _Class::*, _A0, _A1> {
typedef typename __enable_invoke<_Rp _Class::*, _A0>::type type;
};
template <class _Tp, class _A0, class _A1, class _A2>
struct __invoke_return2
{
typedef __decltype(__invoke(std::__1::declval<_Tp&>(), std::__1::declval<_A0&>(), std::__1::declval<_A1&>(), std::__1::declval<_A2&>())) type;
};
template <class _Ret, class _Class, class _A0, class _A1, class _A2>
struct __invoke_return2<_Ret _Class::*, _A0, _A1, _A2> {
typedef typename __enable_invoke<_Ret _Class::*, _A0>::type type;
};
# 308 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 2 3
template <class _Ret>
struct __invoke_void_return_wrapper
{
template <class _Fn>
static _Ret __call(_Fn __f) {
return __invoke(__f);
}
template <class _Fn, class _A0>
static _Ret __call(_Fn __f, _A0& __a0) {
return __invoke(__f, __a0);
}
template <class _Fn, class _A0, class _A1>
static _Ret __call(_Fn __f, _A0& __a0, _A1& __a1) {
return __invoke(__f, __a0, __a1);
}
template <class _Fn, class _A0, class _A1, class _A2>
static _Ret __call(_Fn __f, _A0& __a0, _A1& __a1, _A2& __a2){
return __invoke(__f, __a0, __a1, __a2);
}
};
template <>
struct __invoke_void_return_wrapper<void>
{
template <class _Fn>
static void __call(_Fn __f) {
__invoke(__f);
}
template <class _Fn, class _A0>
static void __call(_Fn __f, _A0& __a0) {
__invoke(__f, __a0);
}
template <class _Fn, class _A0, class _A1>
static void __call(_Fn __f, _A0& __a0, _A1& __a1) {
__invoke(__f, __a0, __a1);
}
template <class _Fn, class _A0, class _A1, class _A2>
static void __call(_Fn __f, _A0& __a0, _A1& __a1, _A2& __a2) {
__invoke(__f, __a0, __a1, __a2);
}
};
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) reference_wrapper
: public __weak_result_type<_Tp>
{
public:
typedef _Tp type;
private:
type* __f_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference_wrapper(type& __f) throw()
: __f_(std::__1::addressof(__f)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator type& () const throw() {return *__f_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) type& get() const throw() {return *__f_;}
# 406 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return<type>::type
operator() () const {
return __invoke(get());
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return0<type, _A0>::type
operator() (_A0& __a0) const {
return __invoke(get(), __a0);
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return0<type, _A0 const>::type
operator() (_A0 const& __a0) const {
return __invoke(get(), __a0);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0, _A1>::type
operator() (_A0& __a0, _A1& __a1) const {
return __invoke(get(), __a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0 const, _A1>::type
operator() (_A0 const& __a0, _A1& __a1) const {
return __invoke(get(), __a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0, _A1 const>::type
operator() (_A0& __a0, _A1 const& __a1) const {
return __invoke(get(), __a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0 const, _A1 const>::type
operator() (_A0 const& __a0, _A1 const& __a1) const {
return __invoke(get(), __a0, __a1);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1, _A2>::type
operator() (_A0& __a0, _A1& __a1, _A2& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1, _A2>::type
operator() (_A0 const& __a0, _A1& __a1, _A2& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1 const, _A2>::type
operator() (_A0& __a0, _A1 const& __a1, _A2& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1, _A2 const>::type
operator() (_A0& __a0, _A1& __a1, _A2 const& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1 const, _A2>::type
operator() (_A0 const& __a0, _A1 const& __a1, _A2& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1, _A2 const>::type
operator() (_A0 const& __a0, _A1& __a1, _A2 const& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1 const, _A2 const>::type
operator() (_A0& __a0, _A1 const& __a1, _A2 const& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1 const, _A2 const>::type
operator() (_A0 const& __a0, _A1 const& __a1, _A2 const& __a2) const {
return __invoke(get(), __a0, __a1, __a2);
}
};
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
reference_wrapper<_Tp>
ref(_Tp& __t) throw()
{
return reference_wrapper<_Tp>(__t);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
reference_wrapper<_Tp>
ref(reference_wrapper<_Tp> __t) throw()
{
return ref(__t.get());
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
reference_wrapper<const _Tp>
cref(const _Tp& __t) throw()
{
return reference_wrapper<const _Tp>(__t);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
reference_wrapper<const _Tp>
cref(reference_wrapper<_Tp> __t) throw()
{
return cref(__t.get());
}
# 562 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 3
struct __attribute__ ((__type_visibility__("default"))) allocator_arg_t { };
extern const allocator_arg_t allocator_arg;
template <class _Tp>
struct __has_allocator_type
{
private:
struct __two {char __lx; char __lxx;};
template <class _Up> static __two __test(...);
template <class _Up> static char __test(typename _Up::allocator_type* = 0);
public:
static const bool value = sizeof(__test<_Tp>(0)) == 1;
};
template <class _Tp, class _Alloc, bool = __has_allocator_type<_Tp>::value>
struct __uses_allocator
: public integral_constant<bool,
is_convertible<_Alloc, typename _Tp::allocator_type>::value>
{
};
template <class _Tp, class _Alloc>
struct __uses_allocator<_Tp, _Alloc, false>
: public false_type
{
};
template <class _Tp, class _Alloc>
struct __attribute__ ((__type_visibility__("default"))) uses_allocator
: public __uses_allocator<_Tp, _Alloc>
{
};
# 661 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_base" 3
} }
# 418 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 2 3
# 429 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
namespace std {inline namespace __1 {
struct __attribute__ ((__type_visibility__("default"))) input_iterator_tag {};
struct __attribute__ ((__type_visibility__("default"))) output_iterator_tag {};
struct __attribute__ ((__type_visibility__("default"))) forward_iterator_tag : public input_iterator_tag {};
struct __attribute__ ((__type_visibility__("default"))) bidirectional_iterator_tag : public forward_iterator_tag {};
struct __attribute__ ((__type_visibility__("default"))) random_access_iterator_tag : public bidirectional_iterator_tag {};
template <class _Tp>
struct __has_iterator_category
{
private:
struct __two {char __lx; char __lxx;};
template <class _Up> static __two __test(...);
template <class _Up> static char __test(typename _Up::iterator_category* = 0);
public:
static const bool value = sizeof(__test<_Tp>(0)) == 1;
};
template <class _Iter, bool> struct __iterator_traits_impl {};
template <class _Iter>
struct __iterator_traits_impl<_Iter, true>
{
typedef typename _Iter::difference_type difference_type;
typedef typename _Iter::value_type value_type;
typedef typename _Iter::pointer pointer;
typedef typename _Iter::reference reference;
typedef typename _Iter::iterator_category iterator_category;
};
template <class _Iter, bool> struct __iterator_traits {};
template <class _Iter>
struct __iterator_traits<_Iter, true>
: __iterator_traits_impl
<
_Iter,
is_convertible<typename _Iter::iterator_category, input_iterator_tag>::value ||
is_convertible<typename _Iter::iterator_category, output_iterator_tag>::value
>
{};
template <class _Iter>
struct __attribute__ ((__type_visibility__("default"))) iterator_traits
: __iterator_traits<_Iter, __has_iterator_category<_Iter>::value> {};
template<class _Tp>
struct __attribute__ ((__type_visibility__("default"))) iterator_traits<_Tp*>
{
typedef ptrdiff_t difference_type;
typedef typename remove_cv<_Tp>::type value_type;
typedef _Tp* pointer;
typedef _Tp& reference;
typedef random_access_iterator_tag iterator_category;
};
template <class _Tp, class _Up, bool = __has_iterator_category<iterator_traits<_Tp> >::value>
struct __has_iterator_category_convertible_to
: public integral_constant<bool, is_convertible<typename iterator_traits<_Tp>::iterator_category, _Up>::value>
{};
template <class _Tp, class _Up>
struct __has_iterator_category_convertible_to<_Tp, _Up, false> : public false_type {};
template <class _Tp>
struct __is_input_iterator : public __has_iterator_category_convertible_to<_Tp, input_iterator_tag> {};
template <class _Tp>
struct __is_forward_iterator : public __has_iterator_category_convertible_to<_Tp, forward_iterator_tag> {};
template <class _Tp>
struct __is_bidirectional_iterator : public __has_iterator_category_convertible_to<_Tp, bidirectional_iterator_tag> {};
template <class _Tp>
struct __is_random_access_iterator : public __has_iterator_category_convertible_to<_Tp, random_access_iterator_tag> {};
template <class _Tp>
struct __is_exactly_input_iterator
: public integral_constant<bool,
__has_iterator_category_convertible_to<_Tp, input_iterator_tag>::value &&
!__has_iterator_category_convertible_to<_Tp, forward_iterator_tag>::value> {};
template<class _Category, class _Tp, class _Distance = ptrdiff_t,
class _Pointer = _Tp*, class _Reference = _Tp&>
struct __attribute__ ((__type_visibility__("default"))) iterator
{
typedef _Tp value_type;
typedef _Distance difference_type;
typedef _Pointer pointer;
typedef _Reference reference;
typedef _Category iterator_category;
};
template <class _InputIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __advance(_InputIter& __i,
typename iterator_traits<_InputIter>::difference_type __n, input_iterator_tag)
{
for (; __n > 0; --__n)
++__i;
}
template <class _BiDirIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __advance(_BiDirIter& __i,
typename iterator_traits<_BiDirIter>::difference_type __n, bidirectional_iterator_tag)
{
if (__n >= 0)
for (; __n > 0; --__n)
++__i;
else
for (; __n < 0; ++__n)
--__i;
}
template <class _RandIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __advance(_RandIter& __i,
typename iterator_traits<_RandIter>::difference_type __n, random_access_iterator_tag)
{
__i += __n;
}
template <class _InputIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void advance(_InputIter& __i,
typename iterator_traits<_InputIter>::difference_type __n)
{
__advance(__i, __n, typename iterator_traits<_InputIter>::iterator_category());
}
template <class _InputIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename iterator_traits<_InputIter>::difference_type
__distance(_InputIter __first, _InputIter __last, input_iterator_tag)
{
typename iterator_traits<_InputIter>::difference_type __r(0);
for (; __first != __last; ++__first)
++__r;
return __r;
}
template <class _RandIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename iterator_traits<_RandIter>::difference_type
__distance(_RandIter __first, _RandIter __last, random_access_iterator_tag)
{
return __last - __first;
}
template <class _InputIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename iterator_traits<_InputIter>::difference_type
distance(_InputIter __first, _InputIter __last)
{
return __distance(__first, __last, typename iterator_traits<_InputIter>::iterator_category());
}
template <class _InputIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__is_input_iterator<_InputIter>::value,
_InputIter
>::type
next(_InputIter __x,
typename iterator_traits<_InputIter>::difference_type __n = 1)
{
std::__1::advance(__x, __n);
return __x;
}
template <class _BidirectionalIter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__is_bidirectional_iterator<_BidirectionalIter>::value,
_BidirectionalIter
>::type
prev(_BidirectionalIter __x,
typename iterator_traits<_BidirectionalIter>::difference_type __n = 1)
{
std::__1::advance(__x, -__n);
return __x;
}
template <class _Tp, class = void>
struct __is_stashing_iterator : false_type {};
template <class _Tp>
struct __is_stashing_iterator<_Tp, typename __void_t<typename _Tp::__stashing_iterator_tag>::type>
: true_type {};
template <class _Iter>
class __attribute__ ((__type_visibility__("default"))) reverse_iterator
: public iterator<typename iterator_traits<_Iter>::iterator_category,
typename iterator_traits<_Iter>::value_type,
typename iterator_traits<_Iter>::difference_type,
typename iterator_traits<_Iter>::pointer,
typename iterator_traits<_Iter>::reference>
{
private:
_Iter __t;
_Static_assert(!__is_stashing_iterator<_Iter>::value, "The specified iterator type cannot be used with reverse_iterator; " "Using stashing iterators with reverse_iterator causes undefined behavior");
protected:
_Iter current;
public:
typedef _Iter iterator_type;
typedef typename iterator_traits<_Iter>::difference_type difference_type;
typedef typename iterator_traits<_Iter>::reference reference;
typedef typename iterator_traits<_Iter>::pointer pointer;
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator() : __t(), current() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit reverse_iterator(_Iter __x) : __t(__x), current(__x) {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator(const reverse_iterator<_Up>& __u) : __t(__u.base()), current(__u.base()) {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator& operator=(const reverse_iterator<_Up>& __u)
{ __t = current = __u.base(); return *this; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Iter base() const {return current;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reference operator*() const {_Iter __tmp = current; return *--__tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer operator->() const {return std::__1::addressof(operator*());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator& operator++() {--current; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator operator++(int) {reverse_iterator __tmp(*this); --current; return __tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator& operator--() {++current; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator operator--(int) {reverse_iterator __tmp(*this); ++current; return __tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator operator+ (difference_type __n) const {return reverse_iterator(current - __n);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator& operator+=(difference_type __n) {current -= __n; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator operator- (difference_type __n) const {return reverse_iterator(current + __n);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator& operator-=(difference_type __n) {current += __n; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reference operator[](difference_type __n) const {return *(*this + __n);}
};
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __x.base() == __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __x.base() > __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __x.base() != __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __x.base() < __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __x.base() <= __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __x.base() >= __y.base();
}
# 749 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename reverse_iterator<_Iter1>::difference_type
operator-(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y)
{
return __y.base() - __x.base();
}
template <class _Iter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator<_Iter>
operator+(typename reverse_iterator<_Iter>::difference_type __n, const reverse_iterator<_Iter>& __x)
{
return reverse_iterator<_Iter>(__x.base() - __n);
}
# 775 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Container>
class __attribute__ ((__type_visibility__("default"))) back_insert_iterator
: public iterator<output_iterator_tag,
void,
void,
void,
void>
{
protected:
_Container* container;
public:
typedef _Container container_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit back_insert_iterator(_Container& __x) : container(std::__1::addressof(__x)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) back_insert_iterator& operator=(const typename _Container::value_type& __value_)
{container->push_back(__value_); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) back_insert_iterator& operator*() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) back_insert_iterator& operator++() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) back_insert_iterator operator++(int) {return *this;}
};
template <class _Container>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
back_insert_iterator<_Container>
back_inserter(_Container& __x)
{
return back_insert_iterator<_Container>(__x);
}
template <class _Container>
class __attribute__ ((__type_visibility__("default"))) front_insert_iterator
: public iterator<output_iterator_tag,
void,
void,
void,
void>
{
protected:
_Container* container;
public:
typedef _Container container_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit front_insert_iterator(_Container& __x) : container(std::__1::addressof(__x)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) front_insert_iterator& operator=(const typename _Container::value_type& __value_)
{container->push_front(__value_); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) front_insert_iterator& operator*() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) front_insert_iterator& operator++() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) front_insert_iterator operator++(int) {return *this;}
};
template <class _Container>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
front_insert_iterator<_Container>
front_inserter(_Container& __x)
{
return front_insert_iterator<_Container>(__x);
}
template <class _Container>
class __attribute__ ((__type_visibility__("default"))) insert_iterator
: public iterator<output_iterator_tag,
void,
void,
void,
void>
{
protected:
_Container* container;
typename _Container::iterator iter;
public:
typedef _Container container_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) insert_iterator(_Container& __x, typename _Container::iterator __i)
: container(std::__1::addressof(__x)), iter(__i) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) insert_iterator& operator=(const typename _Container::value_type& __value_)
{iter = container->insert(iter, __value_); ++iter; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) insert_iterator& operator*() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) insert_iterator& operator++() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) insert_iterator& operator++(int) {return *this;}
};
template <class _Container>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
insert_iterator<_Container>
inserter(_Container& __x, typename _Container::iterator __i)
{
return insert_iterator<_Container>(__x, __i);
}
template <class _Tp, class _CharT = char,
class _Traits = char_traits<_CharT>, class _Distance = ptrdiff_t>
class __attribute__ ((__type_visibility__("default"))) istream_iterator
: public iterator<input_iterator_tag, _Tp, _Distance, const _Tp*, const _Tp&>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef basic_istream<_CharT,_Traits> istream_type;
private:
istream_type* __in_stream_;
_Tp __value_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) istream_iterator() : __in_stream_(0), __value_() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istream_iterator(istream_type& __s) : __in_stream_(std::__1::addressof(__s))
{
if (!(*__in_stream_ >> __value_))
__in_stream_ = 0;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const _Tp& operator*() const {return __value_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const _Tp* operator->() const {return std::__1::addressof((operator*()));}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istream_iterator& operator++()
{
if (!(*__in_stream_ >> __value_))
__in_stream_ = 0;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istream_iterator operator++(int)
{istream_iterator __t(*this); ++(*this); return __t;}
template <class _Up, class _CharU, class _TraitsU, class _DistanceU>
friend __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const istream_iterator<_Up, _CharU, _TraitsU, _DistanceU>& __x,
const istream_iterator<_Up, _CharU, _TraitsU, _DistanceU>& __y);
template <class _Up, class _CharU, class _TraitsU, class _DistanceU>
friend __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const istream_iterator<_Up, _CharU, _TraitsU, _DistanceU>& __x,
const istream_iterator<_Up, _CharU, _TraitsU, _DistanceU>& __y);
};
template <class _Tp, class _CharT, class _Traits, class _Distance>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const istream_iterator<_Tp, _CharT, _Traits, _Distance>& __x,
const istream_iterator<_Tp, _CharT, _Traits, _Distance>& __y)
{
return __x.__in_stream_ == __y.__in_stream_;
}
template <class _Tp, class _CharT, class _Traits, class _Distance>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const istream_iterator<_Tp, _CharT, _Traits, _Distance>& __x,
const istream_iterator<_Tp, _CharT, _Traits, _Distance>& __y)
{
return !(__x == __y);
}
template <class _Tp, class _CharT = char, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) ostream_iterator
: public iterator<output_iterator_tag, void, void, void, void>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef basic_ostream<_CharT,_Traits> ostream_type;
private:
ostream_type* __out_stream_;
const char_type* __delim_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostream_iterator(ostream_type& __s) throw()
: __out_stream_(std::__1::addressof(__s)), __delim_(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostream_iterator(ostream_type& __s, const _CharT* __delimiter) throw()
: __out_stream_(std::__1::addressof(__s)), __delim_(__delimiter) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostream_iterator& operator=(const _Tp& __value_)
{
*__out_stream_ << __value_;
if (__delim_)
*__out_stream_ << __delim_;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostream_iterator& operator*() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostream_iterator& operator++() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostream_iterator& operator++(int) {return *this;}
};
template<class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) istreambuf_iterator
: public iterator<input_iterator_tag, _CharT,
typename _Traits::off_type, _CharT*,
_CharT>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename _Traits::int_type int_type;
typedef basic_streambuf<_CharT,_Traits> streambuf_type;
typedef basic_istream<_CharT,_Traits> istream_type;
private:
mutable streambuf_type* __sbuf_;
class __proxy
{
char_type __keep_;
streambuf_type* __sbuf_;
__attribute__ ((__visibility__("hidden"), __always_inline__)) __proxy(char_type __c, streambuf_type* __s)
: __keep_(__c), __sbuf_(__s) {}
friend class istreambuf_iterator;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type operator*() const {return __keep_;}
};
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __test_for_eof() const
{
if (__sbuf_ && traits_type::eq_int_type(__sbuf_->sgetc(), traits_type::eof()))
__sbuf_ = 0;
return __sbuf_ == 0;
}
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) istreambuf_iterator() throw() : __sbuf_(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istreambuf_iterator(istream_type& __s) throw()
: __sbuf_(__s.rdbuf()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istreambuf_iterator(streambuf_type* __s) throw()
: __sbuf_(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istreambuf_iterator(const __proxy& __p) throw()
: __sbuf_(__p.__sbuf_) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type operator*() const
{return static_cast<char_type>(__sbuf_->sgetc());}
__attribute__ ((__visibility__("hidden"), __always_inline__)) istreambuf_iterator& operator++()
{
__sbuf_->sbumpc();
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __proxy operator++(int)
{
return __proxy(__sbuf_->sbumpc(), __sbuf_);
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool equal(const istreambuf_iterator& __b) const
{return __test_for_eof() == __b.__test_for_eof();}
};
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const istreambuf_iterator<_CharT,_Traits>& __a,
const istreambuf_iterator<_CharT,_Traits>& __b)
{return __a.equal(__b);}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const istreambuf_iterator<_CharT,_Traits>& __a,
const istreambuf_iterator<_CharT,_Traits>& __b)
{return !__a.equal(__b);}
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) ostreambuf_iterator
: public iterator<output_iterator_tag, void, void, void, void>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef basic_streambuf<_CharT,_Traits> streambuf_type;
typedef basic_ostream<_CharT,_Traits> ostream_type;
private:
streambuf_type* __sbuf_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostreambuf_iterator(ostream_type& __s) throw()
: __sbuf_(__s.rdbuf()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostreambuf_iterator(streambuf_type* __s) throw()
: __sbuf_(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostreambuf_iterator& operator=(_CharT __c)
{
if (__sbuf_ && traits_type::eq_int_type(__sbuf_->sputc(__c), traits_type::eof()))
__sbuf_ = 0;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostreambuf_iterator& operator*() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostreambuf_iterator& operator++() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ostreambuf_iterator& operator++(int) {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool failed() const throw() {return __sbuf_ == 0;}
template <class _Ch, class _Tr>
friend
__attribute__ ((__visibility__("hidden")))
ostreambuf_iterator<_Ch, _Tr>
__pad_and_output(ostreambuf_iterator<_Ch, _Tr> __s,
const _Ch* __ob, const _Ch* __op, const _Ch* __oe,
ios_base& __iob, _Ch __fl);
};
template <class _Iter>
class __attribute__ ((__type_visibility__("default"))) move_iterator
{
private:
_Iter __i;
public:
typedef _Iter iterator_type;
typedef typename iterator_traits<iterator_type>::iterator_category iterator_category;
typedef typename iterator_traits<iterator_type>::value_type value_type;
typedef typename iterator_traits<iterator_type>::difference_type difference_type;
typedef iterator_type pointer;
# 1097 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
typedef typename iterator_traits<iterator_type>::reference reference;
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator() : __i() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit move_iterator(_Iter __x) : __i(__x) {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator(const move_iterator<_Up>& __u) : __i(__u.base()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Iter base() const {return __i;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reference operator*() const { return static_cast<reference>(*__i); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer operator->() const { return __i;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator& operator++() {++__i; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator operator++(int) {move_iterator __tmp(*this); ++__i; return __tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator& operator--() {--__i; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator operator--(int) {move_iterator __tmp(*this); --__i; return __tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator operator+ (difference_type __n) const {return move_iterator(__i + __n);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator& operator+=(difference_type __n) {__i += __n; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator operator- (difference_type __n) const {return move_iterator(__i - __n);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator& operator-=(difference_type __n) {__i -= __n; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reference operator[](difference_type __n) const { return static_cast<reference>(__i[__n]); }
};
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() == __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() < __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() != __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() > __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() >= __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() <= __y.base();
}
# 1190 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename move_iterator<_Iter1>::difference_type
operator-(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y)
{
return __x.base() - __y.base();
}
template <class _Iter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator<_Iter>
operator+(typename move_iterator<_Iter>::difference_type __n, const move_iterator<_Iter>& __x)
{
return move_iterator<_Iter>(__x.base() + __n);
}
template <class _Iter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
move_iterator<_Iter>
make_move_iterator(_Iter __i)
{
return move_iterator<_Iter>(__i);
}
template <class _Iter> class __wrap_iter;
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
# 1256 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Iter1, class _Iter2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __wrap_iter<_Iter1>::difference_type
operator-(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter>
__attribute__ ((__visibility__("hidden"), __always_inline__))
__wrap_iter<_Iter>
operator+(typename __wrap_iter<_Iter>::difference_type, __wrap_iter<_Iter>) throw();
template <class _Ip, class _Op> _Op __attribute__ ((__visibility__("hidden"), __always_inline__)) copy(_Ip, _Ip, _Op);
template <class _B1, class _B2> _B2 __attribute__ ((__visibility__("hidden"), __always_inline__)) copy_backward(_B1, _B1, _B2);
template <class _Ip, class _Op> _Op __attribute__ ((__visibility__("hidden"), __always_inline__)) move(_Ip, _Ip, _Op);
template <class _B1, class _B2> _B2 __attribute__ ((__visibility__("hidden"), __always_inline__)) move_backward(_B1, _B1, _B2);
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
_Tp*
>::type
__unwrap_iter(__wrap_iter<_Tp*>);
# 1296 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Iter>
class __wrap_iter
{
public:
typedef _Iter iterator_type;
typedef typename iterator_traits<iterator_type>::iterator_category iterator_category;
typedef typename iterator_traits<iterator_type>::value_type value_type;
typedef typename iterator_traits<iterator_type>::difference_type difference_type;
typedef typename iterator_traits<iterator_type>::pointer pointer;
typedef typename iterator_traits<iterator_type>::reference reference;
private:
iterator_type __i;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter() throw()
{
}
template <class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter(const __wrap_iter<_Up>& __u,
typename enable_if<is_convertible<_Up, iterator_type>::value>::type* = 0) throw()
: __i(__u.base())
{
}
# 1349 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference operator*() const throw()
{
return *__i;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) pointer operator->() const throw()
{
return (pointer)std::__1::addressof(*__i);
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter& operator++() throw()
{
++__i;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter operator++(int) throw()
{__wrap_iter __tmp(*this); ++(*this); return __tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter& operator--() throw()
{
--__i;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter operator--(int) throw()
{__wrap_iter __tmp(*this); --(*this); return __tmp;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter operator+ (difference_type __n) const throw()
{__wrap_iter __w(*this); __w += __n; return __w;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter& operator+=(difference_type __n) throw()
{
__i += __n;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter operator- (difference_type __n) const throw()
{return *this + (-__n);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter& operator-=(difference_type __n) throw()
{*this += -__n; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference operator[](difference_type __n) const throw()
{
return __i[__n];
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iterator_type base() const throw() {return __i;}
private:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __wrap_iter(iterator_type __x) throw() : __i(__x) {}
template <class _Up> friend class __wrap_iter;
template <class _CharT, class _Traits, class _Alloc> friend class basic_string;
template <class _Tp, class _Alloc> friend class __attribute__ ((__type_visibility__("default"))) vector;
template <class _Iter1, class _Iter2>
friend
bool
operator==(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
friend
bool
operator<(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
friend
bool
operator!=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
friend
bool
operator>(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
friend
bool
operator>=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1, class _Iter2>
friend
bool
operator<=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
# 1464 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Iter1, class _Iter2>
friend
typename __wrap_iter<_Iter1>::difference_type
operator-(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) throw();
template <class _Iter1>
friend
__wrap_iter<_Iter1>
operator+(typename __wrap_iter<_Iter1>::difference_type, __wrap_iter<_Iter1>) throw();
template <class _Ip, class _Op> friend _Op copy(_Ip, _Ip, _Op);
template <class _B1, class _B2> friend _B2 copy_backward(_B1, _B1, _B2);
template <class _Ip, class _Op> friend _Op move(_Ip, _Ip, _Op);
template <class _B1, class _B2> friend _B2 move_backward(_B1, _B1, _B2);
template <class _Tp>
friend
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
_Tp*
>::type
__unwrap_iter(__wrap_iter<_Tp*>);
# 1499 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
};
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return __x.base() == __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return __x.base() < __y.base();
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return !(__x == __y);
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return __y < __x;
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return !(__x < __y);
}
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return !(__y < __x);
}
template <class _Iter1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter1>& __y) throw()
{
return !(__x == __y);
}
template <class _Iter1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter1>& __y) throw()
{
return __y < __x;
}
template <class _Iter1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter1>& __y) throw()
{
return !(__x < __y);
}
template <class _Iter1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter1>& __y) throw()
{
return !(__y < __x);
}
# 1599 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Iter1, class _Iter2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __wrap_iter<_Iter1>::difference_type
operator-(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) throw()
{
return __x.base() - __y.base();
}
template <class _Iter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__wrap_iter<_Iter>
operator+(typename __wrap_iter<_Iter>::difference_type __n,
__wrap_iter<_Iter> __x) throw()
{
__x += __n;
return __x;
}
template <class _Iter>
struct __libcpp_is_trivial_iterator
: public integral_constant<bool,(is_pointer<_Iter>::value)> {};
template <class _Iter>
struct __libcpp_is_trivial_iterator<move_iterator<_Iter> >
: public integral_constant<bool,(__libcpp_is_trivial_iterator<_Iter>::value)> {};
template <class _Iter>
struct __libcpp_is_trivial_iterator<reverse_iterator<_Iter> >
: public integral_constant<bool,(__libcpp_is_trivial_iterator<_Iter>::value)> {};
template <class _Iter>
struct __libcpp_is_trivial_iterator<__wrap_iter<_Iter> >
: public integral_constant<bool,(__libcpp_is_trivial_iterator<_Iter>::value)> {};
template <class _Tp, size_t _Np>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
begin(_Tp (&__array)[_Np])
{
return __array;
}
template <class _Tp, size_t _Np>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
end(_Tp (&__array)[_Np])
{
return __array + _Np;
}
# 1780 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Cp::iterator
begin(_Cp& __c)
{
return __c.begin();
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Cp::const_iterator
begin(const _Cp& __c)
{
return __c.begin();
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Cp::iterator
end(_Cp& __c)
{
return __c.end();
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Cp::const_iterator
end(const _Cp& __c)
{
return __c.end();
}
# 1880 "/Library/Developer/CommandLineTools/usr/include/c++/v1/iterator" 3
} }
# 660 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/tuple" 1 3
# 147 "/Library/Developer/CommandLineTools/usr/include/c++/v1/tuple" 3
namespace std {inline namespace __1 {
# 1415 "/Library/Developer/CommandLineTools/usr/include/c++/v1/tuple" 3
} }
# 663 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdexcept" 1 3
# 54 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdexcept" 3
namespace std {inline namespace __1 {
class __attribute__ ((__visibility__("hidden"))) __libcpp_refstring
{
const char* __imp_;
bool __uses_refcount() const;
public:
explicit __libcpp_refstring(const char* __msg);
__libcpp_refstring(const __libcpp_refstring& __s) throw();
__libcpp_refstring& operator=(const __libcpp_refstring& __s) throw();
~__libcpp_refstring();
const char* c_str() const throw() {return __imp_;}
};
} }
namespace std
{
class __attribute__ ((__visibility__("default"))) logic_error
: public exception
{
private:
std::__1::__libcpp_refstring __imp_;
public:
explicit logic_error(const string&);
explicit logic_error(const char*);
logic_error(const logic_error&) throw();
logic_error& operator=(const logic_error&) throw();
virtual ~logic_error() throw();
virtual const char* what() const throw();
};
class __attribute__ ((__visibility__("default"))) runtime_error
: public exception
{
private:
std::__1::__libcpp_refstring __imp_;
public:
explicit runtime_error(const string&);
explicit runtime_error(const char*);
runtime_error(const runtime_error&) throw();
runtime_error& operator=(const runtime_error&) throw();
virtual ~runtime_error() throw();
virtual const char* what() const throw();
};
class __attribute__ ((__visibility__("default"))) domain_error
: public logic_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit domain_error(const string& __s) : logic_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit domain_error(const char* __s) : logic_error(__s) {}
virtual ~domain_error() throw();
};
class __attribute__ ((__visibility__("default"))) invalid_argument
: public logic_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit invalid_argument(const string& __s) : logic_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit invalid_argument(const char* __s) : logic_error(__s) {}
virtual ~invalid_argument() throw();
};
class __attribute__ ((__visibility__("default"))) length_error
: public logic_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit length_error(const string& __s) : logic_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit length_error(const char* __s) : logic_error(__s) {}
virtual ~length_error() throw();
};
class __attribute__ ((__visibility__("default"))) out_of_range
: public logic_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit out_of_range(const string& __s) : logic_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit out_of_range(const char* __s) : logic_error(__s) {}
virtual ~out_of_range() throw();
};
class __attribute__ ((__visibility__("default"))) range_error
: public runtime_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit range_error(const string& __s) : runtime_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit range_error(const char* __s) : runtime_error(__s) {}
virtual ~range_error() throw();
};
class __attribute__ ((__visibility__("default"))) overflow_error
: public runtime_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit overflow_error(const string& __s) : runtime_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit overflow_error(const char* __s) : runtime_error(__s) {}
virtual ~overflow_error() throw();
};
class __attribute__ ((__visibility__("default"))) underflow_error
: public runtime_error
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit underflow_error(const string& __s) : runtime_error(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit underflow_error(const char* __s) : runtime_error(__s) {}
virtual ~underflow_error() throw();
};
}
namespace std {inline namespace __1 {
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default"))) void __throw_runtime_error(const char*);
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_logic_error(const char*__msg)
{
throw logic_error(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_domain_error(const char*__msg)
{
throw domain_error(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_invalid_argument(const char*__msg)
{
throw invalid_argument(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_length_error(const char*__msg)
{
throw length_error(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_out_of_range(const char*__msg)
{
throw out_of_range(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_range_error(const char*__msg)
{
throw range_error(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_overflow_error(const char*__msg)
{
throw overflow_error(__msg);
}
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_underflow_error(const char*__msg)
{
throw underflow_error(__msg);
}
} }
# 664 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cassert" 1 3
# 21 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cassert" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h" 1 3 4
# 44 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h" 3 4
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdlib.h" 1 3 4
# 45 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h" 2 3 4
# 75 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h" 3 4
extern "C" {
void __assert_rtn(const char *, const char *, int, const char *) __attribute__((noreturn)) __attribute__((__disable_tail_calls__));
}
# 22 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cassert" 2 3
# 25 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cassert" 3
# 666 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/atomic" 1 3
# 550 "/Library/Developer/CommandLineTools/usr/include/c++/v1/atomic" 3
# 582 "/Library/Developer/CommandLineTools/usr/include/c++/v1/atomic" 3
namespace std {inline namespace __1 {
typedef enum memory_order
{
memory_order_relaxed, memory_order_consume, memory_order_acquire,
memory_order_release, memory_order_acq_rel, memory_order_seq_cst
} memory_order;
# 859 "/Library/Developer/CommandLineTools/usr/include/c++/v1/atomic" 3
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
kill_dependency(_Tp __y) throw()
{
return __y;
}
# 893 "/Library/Developer/CommandLineTools/usr/include/c++/v1/atomic" 3
template <class _Tp, bool = is_integral<_Tp>::value && !is_same<_Tp, bool>::value>
struct __atomic_base
{
mutable _Atomic(_Tp) __a_;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool is_lock_free() const volatile throw()
{
return __c11_atomic_is_lock_free(sizeof(_Tp));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool is_lock_free() const throw()
{return static_cast<__atomic_base const volatile*>(this)->is_lock_free();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void store(_Tp __d, memory_order __m = memory_order_seq_cst) volatile throw()
__attribute__((diagnose_if(__m == memory_order_consume || __m == memory_order_acquire || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{__c11_atomic_store(&__a_, __d, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void store(_Tp __d, memory_order __m = memory_order_seq_cst) throw()
__attribute__((diagnose_if(__m == memory_order_consume || __m == memory_order_acquire || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{__c11_atomic_store(&__a_, __d, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp load(memory_order __m = memory_order_seq_cst) const volatile throw()
__attribute__((diagnose_if(__m == memory_order_release || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{return __c11_atomic_load(&__a_, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp load(memory_order __m = memory_order_seq_cst) const throw()
__attribute__((diagnose_if(__m == memory_order_release || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{return __c11_atomic_load(&__a_, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator _Tp() const volatile throw() {return load();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator _Tp() const throw() {return load();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp exchange(_Tp __d, memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_exchange(&__a_, __d, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp exchange(_Tp __d, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_exchange(&__a_, __d, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_weak(_Tp& __e, _Tp __d,
memory_order __s, memory_order __f) volatile throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __s, __f);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_weak(_Tp& __e, _Tp __d,
memory_order __s, memory_order __f) throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __s, __f);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_strong(_Tp& __e, _Tp __d,
memory_order __s, memory_order __f) volatile throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __s, __f);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_strong(_Tp& __e, _Tp __d,
memory_order __s, memory_order __f) throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __s, __f);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_weak(_Tp& __e, _Tp __d,
memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __m, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_weak(_Tp& __e, _Tp __d,
memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __m, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_strong(_Tp& __e, _Tp __d,
memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __m, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool compare_exchange_strong(_Tp& __e, _Tp __d,
memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __m, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__atomic_base() throw() : __a_() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__atomic_base(_Tp __d) throw() : __a_(__d) {}
private:
__atomic_base(const __atomic_base&);
__atomic_base& operator=(const __atomic_base&);
__atomic_base& operator=(const __atomic_base&) volatile;
};
# 1005 "/Library/Developer/CommandLineTools/usr/include/c++/v1/atomic" 3
template <class _Tp>
struct __atomic_base<_Tp, true>
: public __atomic_base<_Tp, false>
{
typedef __atomic_base<_Tp, false> __base;
__attribute__ ((__visibility__("hidden"), __always_inline__))
__atomic_base() throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__atomic_base(_Tp __d) throw() : __base(__d) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_add(_Tp __op, memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_fetch_add(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_add(_Tp __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_add(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_sub(_Tp __op, memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_fetch_sub(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_sub(_Tp __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_sub(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_and(_Tp __op, memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_fetch_and(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_and(_Tp __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_and(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_or(_Tp __op, memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_fetch_or(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_or(_Tp __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_or(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_xor(_Tp __op, memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_fetch_xor(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp fetch_xor(_Tp __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_xor(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator++(int) volatile throw() {return fetch_add(_Tp(1));}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator++(int) throw() {return fetch_add(_Tp(1));}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator--(int) volatile throw() {return fetch_sub(_Tp(1));}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator--(int) throw() {return fetch_sub(_Tp(1));}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator++() volatile throw() {return fetch_add(_Tp(1)) + _Tp(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator++() throw() {return fetch_add(_Tp(1)) + _Tp(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator--() volatile throw() {return fetch_sub(_Tp(1)) - _Tp(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator--() throw() {return fetch_sub(_Tp(1)) - _Tp(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator+=(_Tp __op) volatile throw() {return fetch_add(__op) + __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator+=(_Tp __op) throw() {return fetch_add(__op) + __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator-=(_Tp __op) volatile throw() {return fetch_sub(__op) - __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator-=(_Tp __op) throw() {return fetch_sub(__op) - __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator&=(_Tp __op) volatile throw() {return fetch_and(__op) & __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator&=(_Tp __op) throw() {return fetch_and(__op) & __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator|=(_Tp __op) volatile throw() {return fetch_or(__op) | __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator|=(_Tp __op) throw() {return fetch_or(__op) | __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator^=(_Tp __op) volatile throw() {return fetch_xor(__op) ^ __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator^=(_Tp __op) throw() {return fetch_xor(__op) ^ __op;}
};
template <class _Tp>
struct atomic
: public __atomic_base<_Tp>
{
typedef __atomic_base<_Tp> __base;
__attribute__ ((__visibility__("hidden"), __always_inline__))
atomic() throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
atomic(_Tp __d) throw() : __base(__d) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator=(_Tp __d) volatile throw()
{__base::store(__d); return __d;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator=(_Tp __d) throw()
{__base::store(__d); return __d;}
};
template <class _Tp>
struct atomic<_Tp*>
: public __atomic_base<_Tp*>
{
typedef __atomic_base<_Tp*> __base;
__attribute__ ((__visibility__("hidden"), __always_inline__))
atomic() throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
atomic(_Tp* __d) throw() : __base(__d) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator=(_Tp* __d) volatile throw()
{__base::store(__d); return __d;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator=(_Tp* __d) throw()
{__base::store(__d); return __d;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* fetch_add(ptrdiff_t __op, memory_order __m = memory_order_seq_cst)
volatile throw()
{return __c11_atomic_fetch_add(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* fetch_add(ptrdiff_t __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_add(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* fetch_sub(ptrdiff_t __op, memory_order __m = memory_order_seq_cst)
volatile throw()
{return __c11_atomic_fetch_sub(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* fetch_sub(ptrdiff_t __op, memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_fetch_sub(&this->__a_, __op, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator++(int) volatile throw() {return fetch_add(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator++(int) throw() {return fetch_add(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator--(int) volatile throw() {return fetch_sub(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator--(int) throw() {return fetch_sub(1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator++() volatile throw() {return fetch_add(1) + 1;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator++() throw() {return fetch_add(1) + 1;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator--() volatile throw() {return fetch_sub(1) - 1;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator--() throw() {return fetch_sub(1) - 1;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator+=(ptrdiff_t __op) volatile throw() {return fetch_add(__op) + __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator+=(ptrdiff_t __op) throw() {return fetch_add(__op) + __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator-=(ptrdiff_t __op) volatile throw() {return fetch_sub(__op) - __op;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* operator-=(ptrdiff_t __op) throw() {return fetch_sub(__op) - __op;}
};
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_is_lock_free(const volatile atomic<_Tp>* __o) throw()
{
return __o->is_lock_free();
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_is_lock_free(const atomic<_Tp>* __o) throw()
{
return __o->is_lock_free();
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_init(volatile atomic<_Tp>* __o, _Tp __d) throw()
{
__c11_atomic_init(&__o->__a_, __d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_init(atomic<_Tp>* __o, _Tp __d) throw()
{
__c11_atomic_init(&__o->__a_, __d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_store(volatile atomic<_Tp>* __o, _Tp __d) throw()
{
__o->store(__d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_store(atomic<_Tp>* __o, _Tp __d) throw()
{
__o->store(__d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_store_explicit(volatile atomic<_Tp>* __o, _Tp __d, memory_order __m) throw()
__attribute__((diagnose_if(__m == memory_order_consume || __m == memory_order_acquire || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
__o->store(__d, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_store_explicit(atomic<_Tp>* __o, _Tp __d, memory_order __m) throw()
__attribute__((diagnose_if(__m == memory_order_consume || __m == memory_order_acquire || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
__o->store(__d, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_load(const volatile atomic<_Tp>* __o) throw()
{
return __o->load();
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_load(const atomic<_Tp>* __o) throw()
{
return __o->load();
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_load_explicit(const volatile atomic<_Tp>* __o, memory_order __m) throw()
__attribute__((diagnose_if(__m == memory_order_release || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
return __o->load(__m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_load_explicit(const atomic<_Tp>* __o, memory_order __m) throw()
__attribute__((diagnose_if(__m == memory_order_release || __m == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
return __o->load(__m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_exchange(volatile atomic<_Tp>* __o, _Tp __d) throw()
{
return __o->exchange(__d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_exchange(atomic<_Tp>* __o, _Tp __d) throw()
{
return __o->exchange(__d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_exchange_explicit(volatile atomic<_Tp>* __o, _Tp __d, memory_order __m) throw()
{
return __o->exchange(__d, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp
atomic_exchange_explicit(atomic<_Tp>* __o, _Tp __d, memory_order __m) throw()
{
return __o->exchange(__d, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_weak(volatile atomic<_Tp>* __o, _Tp* __e, _Tp __d) throw()
{
return __o->compare_exchange_weak(*__e, __d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_weak(atomic<_Tp>* __o, _Tp* __e, _Tp __d) throw()
{
return __o->compare_exchange_weak(*__e, __d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_strong(volatile atomic<_Tp>* __o, _Tp* __e, _Tp __d) throw()
{
return __o->compare_exchange_strong(*__e, __d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_strong(atomic<_Tp>* __o, _Tp* __e, _Tp __d) throw()
{
return __o->compare_exchange_strong(*__e, __d);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_weak_explicit(volatile atomic<_Tp>* __o, _Tp* __e,
_Tp __d,
memory_order __s, memory_order __f) throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
return __o->compare_exchange_weak(*__e, __d, __s, __f);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_weak_explicit(atomic<_Tp>* __o, _Tp* __e, _Tp __d,
memory_order __s, memory_order __f) throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
return __o->compare_exchange_weak(*__e, __d, __s, __f);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_strong_explicit(volatile atomic<_Tp>* __o,
_Tp* __e, _Tp __d,
memory_order __s, memory_order __f) throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
return __o->compare_exchange_strong(*__e, __d, __s, __f);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_compare_exchange_strong_explicit(atomic<_Tp>* __o, _Tp* __e,
_Tp __d,
memory_order __s, memory_order __f) throw()
__attribute__((diagnose_if(__f == memory_order_release || __f == memory_order_acq_rel, "memory order argument to atomic operation is invalid", "warning")))
{
return __o->compare_exchange_strong(*__e, __d, __s, __f);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_add(volatile atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_add(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_add(atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_add(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_add(volatile atomic<_Tp*>* __o, ptrdiff_t __op) throw()
{
return __o->fetch_add(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_add(atomic<_Tp*>* __o, ptrdiff_t __op) throw()
{
return __o->fetch_add(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_add_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_add(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_add_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_add(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_add_explicit(volatile atomic<_Tp*>* __o, ptrdiff_t __op,
memory_order __m) throw()
{
return __o->fetch_add(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_add_explicit(atomic<_Tp*>* __o, ptrdiff_t __op, memory_order __m) throw()
{
return __o->fetch_add(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_sub(volatile atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_sub(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_sub(atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_sub(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_sub(volatile atomic<_Tp*>* __o, ptrdiff_t __op) throw()
{
return __o->fetch_sub(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_sub(atomic<_Tp*>* __o, ptrdiff_t __op) throw()
{
return __o->fetch_sub(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_sub_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_sub(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_sub_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_sub(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_sub_explicit(volatile atomic<_Tp*>* __o, ptrdiff_t __op,
memory_order __m) throw()
{
return __o->fetch_sub(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
atomic_fetch_sub_explicit(atomic<_Tp*>* __o, ptrdiff_t __op, memory_order __m) throw()
{
return __o->fetch_sub(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_and(volatile atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_and(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_and(atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_and(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_and_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_and(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_and_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_and(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_or(volatile atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_or(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_or(atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_or(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_or_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_or(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_or_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_or(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_xor(volatile atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_xor(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_xor(atomic<_Tp>* __o, _Tp __op) throw()
{
return __o->fetch_xor(__op);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_xor_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_xor(__op, __m);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && !is_same<_Tp, bool>::value,
_Tp
>::type
atomic_fetch_xor_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) throw()
{
return __o->fetch_xor(__op, __m);
}
typedef struct atomic_flag
{
_Atomic(bool) __a_;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool test_and_set(memory_order __m = memory_order_seq_cst) volatile throw()
{return __c11_atomic_exchange(&__a_, true, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool test_and_set(memory_order __m = memory_order_seq_cst) throw()
{return __c11_atomic_exchange(&__a_, true, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void clear(memory_order __m = memory_order_seq_cst) volatile throw()
{__c11_atomic_store(&__a_, false, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void clear(memory_order __m = memory_order_seq_cst) throw()
{__c11_atomic_store(&__a_, false, __m);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
atomic_flag() throw() : __a_() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
atomic_flag(bool __b) throw() : __a_(__b) {}
private:
atomic_flag(const atomic_flag&);
atomic_flag& operator=(const atomic_flag&);
atomic_flag& operator=(const atomic_flag&) volatile;
} atomic_flag;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_flag_test_and_set(volatile atomic_flag* __o) throw()
{
return __o->test_and_set();
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_flag_test_and_set(atomic_flag* __o) throw()
{
return __o->test_and_set();
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_flag_test_and_set_explicit(volatile atomic_flag* __o, memory_order __m) throw()
{
return __o->test_and_set(__m);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_flag_test_and_set_explicit(atomic_flag* __o, memory_order __m) throw()
{
return __o->test_and_set(__m);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_flag_clear(volatile atomic_flag* __o) throw()
{
__o->clear();
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_flag_clear(atomic_flag* __o) throw()
{
__o->clear();
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_flag_clear_explicit(volatile atomic_flag* __o, memory_order __m) throw()
{
__o->clear(__m);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_flag_clear_explicit(atomic_flag* __o, memory_order __m) throw()
{
__o->clear(__m);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_thread_fence(memory_order __m) throw()
{
__c11_atomic_thread_fence(__m);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
atomic_signal_fence(memory_order __m) throw()
{
__c11_atomic_signal_fence(__m);
}
typedef atomic<bool> atomic_bool;
typedef atomic<char> atomic_char;
typedef atomic<signed char> atomic_schar;
typedef atomic<unsigned char> atomic_uchar;
typedef atomic<short> atomic_short;
typedef atomic<unsigned short> atomic_ushort;
typedef atomic<int> atomic_int;
typedef atomic<unsigned int> atomic_uint;
typedef atomic<long> atomic_long;
typedef atomic<unsigned long> atomic_ulong;
typedef atomic<long long> atomic_llong;
typedef atomic<unsigned long long> atomic_ullong;
typedef atomic<char16_t> atomic_char16_t;
typedef atomic<char32_t> atomic_char32_t;
typedef atomic<wchar_t> atomic_wchar_t;
typedef atomic<int_least8_t> atomic_int_least8_t;
typedef atomic<uint_least8_t> atomic_uint_least8_t;
typedef atomic<int_least16_t> atomic_int_least16_t;
typedef atomic<uint_least16_t> atomic_uint_least16_t;
typedef atomic<int_least32_t> atomic_int_least32_t;
typedef atomic<uint_least32_t> atomic_uint_least32_t;
typedef atomic<int_least64_t> atomic_int_least64_t;
typedef atomic<uint_least64_t> atomic_uint_least64_t;
typedef atomic<int_fast8_t> atomic_int_fast8_t;
typedef atomic<uint_fast8_t> atomic_uint_fast8_t;
typedef atomic<int_fast16_t> atomic_int_fast16_t;
typedef atomic<uint_fast16_t> atomic_uint_fast16_t;
typedef atomic<int_fast32_t> atomic_int_fast32_t;
typedef atomic<uint_fast32_t> atomic_uint_fast32_t;
typedef atomic<int_fast64_t> atomic_int_fast64_t;
typedef atomic<uint_fast64_t> atomic_uint_fast64_t;
typedef atomic< int8_t> atomic_int8_t;
typedef atomic<uint8_t> atomic_uint8_t;
typedef atomic< int16_t> atomic_int16_t;
typedef atomic<uint16_t> atomic_uint16_t;
typedef atomic< int32_t> atomic_int32_t;
typedef atomic<uint32_t> atomic_uint32_t;
typedef atomic< int64_t> atomic_int64_t;
typedef atomic<uint64_t> atomic_uint64_t;
typedef atomic<intptr_t> atomic_intptr_t;
typedef atomic<uintptr_t> atomic_uintptr_t;
typedef atomic<size_t> atomic_size_t;
typedef atomic<ptrdiff_t> atomic_ptrdiff_t;
typedef atomic<intmax_t> atomic_intmax_t;
typedef atomic<uintmax_t> atomic_uintmax_t;
} }
# 668 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
# 672 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 676 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 2 3
namespace std {inline namespace __1 {
template <class _ValueType>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ValueType __libcpp_relaxed_load(_ValueType const* __value) {
return __atomic_load_n(__value, 0);
}
template <class _ValueType>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ValueType __libcpp_acquire_load(_ValueType const* __value) {
return __atomic_load_n(__value, 2);
}
template <class _Tp> class allocator;
template <>
class __attribute__ ((__type_visibility__("default"))) allocator<void>
{
public:
typedef void* pointer;
typedef const void* const_pointer;
typedef void value_type;
template <class _Up> struct rebind {typedef allocator<_Up> other;};
};
template <>
class __attribute__ ((__type_visibility__("default"))) allocator<const void>
{
public:
typedef const void* pointer;
typedef const void* const_pointer;
typedef const void value_type;
template <class _Up> struct rebind {typedef allocator<_Up> other;};
};
template <class _Tp, class = void>
struct __has_element_type : false_type {};
template <class _Tp>
struct __has_element_type<_Tp,
typename __void_t<typename _Tp::element_type>::type> : true_type {};
template <class _Ptr, bool = __has_element_type<_Ptr>::value>
struct __pointer_traits_element_type;
template <class _Ptr>
struct __pointer_traits_element_type<_Ptr, true>
{
typedef typename _Ptr::element_type type;
};
# 764 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <template <class> class _Sp, class _Tp>
struct __pointer_traits_element_type<_Sp<_Tp>, true>
{
typedef typename _Sp<_Tp>::element_type type;
};
template <template <class> class _Sp, class _Tp>
struct __pointer_traits_element_type<_Sp<_Tp>, false>
{
typedef _Tp type;
};
template <template <class, class> class _Sp, class _Tp, class _A0>
struct __pointer_traits_element_type<_Sp<_Tp, _A0>, true>
{
typedef typename _Sp<_Tp, _A0>::element_type type;
};
template <template <class, class> class _Sp, class _Tp, class _A0>
struct __pointer_traits_element_type<_Sp<_Tp, _A0>, false>
{
typedef _Tp type;
};
template <template <class, class, class> class _Sp, class _Tp, class _A0, class _A1>
struct __pointer_traits_element_type<_Sp<_Tp, _A0, _A1>, true>
{
typedef typename _Sp<_Tp, _A0, _A1>::element_type type;
};
template <template <class, class, class> class _Sp, class _Tp, class _A0, class _A1>
struct __pointer_traits_element_type<_Sp<_Tp, _A0, _A1>, false>
{
typedef _Tp type;
};
template <template <class, class, class, class> class _Sp, class _Tp, class _A0,
class _A1, class _A2>
struct __pointer_traits_element_type<_Sp<_Tp, _A0, _A1, _A2>, true>
{
typedef typename _Sp<_Tp, _A0, _A1, _A2>::element_type type;
};
template <template <class, class, class, class> class _Sp, class _Tp, class _A0,
class _A1, class _A2>
struct __pointer_traits_element_type<_Sp<_Tp, _A0, _A1, _A2>, false>
{
typedef _Tp type;
};
template <class _Tp, class = void>
struct __has_difference_type : false_type {};
template <class _Tp>
struct __has_difference_type<_Tp,
typename __void_t<typename _Tp::difference_type>::type> : true_type {};
template <class _Ptr, bool = __has_difference_type<_Ptr>::value>
struct __pointer_traits_difference_type
{
typedef ptrdiff_t type;
};
template <class _Ptr>
struct __pointer_traits_difference_type<_Ptr, true>
{
typedef typename _Ptr::difference_type type;
};
template <class _Tp, class _Up>
struct __has_rebind
{
private:
struct __two {char __lx; char __lxx;};
template <class _Xp> static __two __test(...);
template <class _Xp> static char __test(typename _Xp::template rebind<_Up>* = 0);
public:
static const bool value = sizeof(__test<_Tp>(0)) == 1;
};
template <class _Tp, class _Up, bool = __has_rebind<_Tp, _Up>::value>
struct __pointer_traits_rebind
{
typedef typename _Tp::template rebind<_Up>::other type;
};
# 876 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <template <class> class _Sp, class _Tp, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp>, _Up, true>
{
typedef typename _Sp<_Tp>::template rebind<_Up>::other type;
};
template <template <class> class _Sp, class _Tp, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp>, _Up, false>
{
typedef _Sp<_Up> type;
};
template <template <class, class> class _Sp, class _Tp, class _A0, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp, _A0>, _Up, true>
{
typedef typename _Sp<_Tp, _A0>::template rebind<_Up>::other type;
};
template <template <class, class> class _Sp, class _Tp, class _A0, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp, _A0>, _Up, false>
{
typedef _Sp<_Up, _A0> type;
};
template <template <class, class, class> class _Sp, class _Tp, class _A0,
class _A1, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp, _A0, _A1>, _Up, true>
{
typedef typename _Sp<_Tp, _A0, _A1>::template rebind<_Up>::other type;
};
template <template <class, class, class> class _Sp, class _Tp, class _A0,
class _A1, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp, _A0, _A1>, _Up, false>
{
typedef _Sp<_Up, _A0, _A1> type;
};
template <template <class, class, class, class> class _Sp, class _Tp, class _A0,
class _A1, class _A2, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp, _A0, _A1, _A2>, _Up, true>
{
typedef typename _Sp<_Tp, _A0, _A1, _A2>::template rebind<_Up>::other type;
};
template <template <class, class, class, class> class _Sp, class _Tp, class _A0,
class _A1, class _A2, class _Up>
struct __pointer_traits_rebind<_Sp<_Tp, _A0, _A1, _A2>, _Up, false>
{
typedef _Sp<_Up, _A0, _A1, _A2> type;
};
template <class _Ptr>
struct __attribute__ ((__type_visibility__("default"))) pointer_traits
{
typedef _Ptr pointer;
typedef typename __pointer_traits_element_type<pointer>::type element_type;
typedef typename __pointer_traits_difference_type<pointer>::type difference_type;
template <class _Up> struct rebind
{typedef typename __pointer_traits_rebind<pointer, _Up>::type other;};
private:
struct __nat {};
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
static pointer pointer_to(typename conditional<is_void<element_type>::value,
__nat, element_type>::type& __r)
{return pointer::pointer_to(__r);}
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) pointer_traits<_Tp*>
{
typedef _Tp* pointer;
typedef _Tp element_type;
typedef ptrdiff_t difference_type;
template <class _Up> struct rebind {typedef _Up* other;};
private:
struct __nat {};
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
static pointer pointer_to(typename conditional<is_void<element_type>::value,
__nat, element_type>::type& __r) throw()
{return std::__1::addressof(__r);}
};
template <class _From, class _To>
struct __rebind_pointer {
typedef typename pointer_traits<_From>::template rebind<_To>::other type;
};
template <class _Tp, class = void>
struct __has_pointer_type : false_type {};
template <class _Tp>
struct __has_pointer_type<_Tp,
typename __void_t<typename _Tp::pointer>::type> : true_type {};
namespace __pointer_type_imp
{
template <class _Tp, class _Dp, bool = __has_pointer_type<_Dp>::value>
struct __pointer_type
{
typedef typename _Dp::pointer type;
};
template <class _Tp, class _Dp>
struct __pointer_type<_Tp, _Dp, false>
{
typedef _Tp* type;
};
}
template <class _Tp, class _Dp>
struct __pointer_type
{
typedef typename __pointer_type_imp::__pointer_type<_Tp, typename remove_reference<_Dp>::type>::type type;
};
template <class _Tp, class = void>
struct __has_const_pointer : false_type {};
template <class _Tp>
struct __has_const_pointer<_Tp,
typename __void_t<typename _Tp::const_pointer>::type> : true_type {};
template <class _Tp, class _Ptr, class _Alloc, bool = __has_const_pointer<_Alloc>::value>
struct __const_pointer
{
typedef typename _Alloc::const_pointer type;
};
template <class _Tp, class _Ptr, class _Alloc>
struct __const_pointer<_Tp, _Ptr, _Alloc, false>
{
typedef typename pointer_traits<_Ptr>::template rebind<const _Tp>::other type;
};
template <class _Tp, class = void>
struct __has_void_pointer : false_type {};
template <class _Tp>
struct __has_void_pointer<_Tp,
typename __void_t<typename _Tp::void_pointer>::type> : true_type {};
template <class _Ptr, class _Alloc, bool = __has_void_pointer<_Alloc>::value>
struct __void_pointer
{
typedef typename _Alloc::void_pointer type;
};
template <class _Ptr, class _Alloc>
struct __void_pointer<_Ptr, _Alloc, false>
{
typedef typename pointer_traits<_Ptr>::template rebind<void>::other type;
};
template <class _Tp, class = void>
struct __has_const_void_pointer : false_type {};
template <class _Tp>
struct __has_const_void_pointer<_Tp,
typename __void_t<typename _Tp::const_void_pointer>::type> : true_type {};
template <class _Ptr, class _Alloc, bool = __has_const_void_pointer<_Alloc>::value>
struct __const_void_pointer
{
typedef typename _Alloc::const_void_pointer type;
};
template <class _Ptr, class _Alloc>
struct __const_void_pointer<_Ptr, _Alloc, false>
{
typedef typename pointer_traits<_Ptr>::template rebind<const void>::other type;
};
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
__to_raw_pointer(_Tp* __p) throw()
{
return __p;
}
template <class _Pointer>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename pointer_traits<_Pointer>::element_type*
__to_raw_pointer(_Pointer __p) throw()
{
return std::__1::__to_raw_pointer(__p.operator->());
}
# 1153 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Tp, class = void>
struct __has_size_type : false_type {};
template <class _Tp>
struct __has_size_type<_Tp,
typename __void_t<typename _Tp::size_type>::type> : true_type {};
template <class _Alloc, class _DiffType, bool = __has_size_type<_Alloc>::value>
struct __size_type
{
typedef typename make_unsigned<_DiffType>::type type;
};
template <class _Alloc, class _DiffType>
struct __size_type<_Alloc, _DiffType, true>
{
typedef typename _Alloc::size_type type;
};
template <class _Tp, class = void>
struct __has_propagate_on_container_copy_assignment : false_type {};
template <class _Tp>
struct __has_propagate_on_container_copy_assignment<_Tp,
typename __void_t<typename _Tp::propagate_on_container_copy_assignment>::type>
: true_type {};
template <class _Alloc, bool = __has_propagate_on_container_copy_assignment<_Alloc>::value>
struct __propagate_on_container_copy_assignment
{
typedef false_type type;
};
template <class _Alloc>
struct __propagate_on_container_copy_assignment<_Alloc, true>
{
typedef typename _Alloc::propagate_on_container_copy_assignment type;
};
template <class _Tp, class = void>
struct __has_propagate_on_container_move_assignment : false_type {};
template <class _Tp>
struct __has_propagate_on_container_move_assignment<_Tp,
typename __void_t<typename _Tp::propagate_on_container_move_assignment>::type>
: true_type {};
template <class _Alloc, bool = __has_propagate_on_container_move_assignment<_Alloc>::value>
struct __propagate_on_container_move_assignment
{
typedef false_type type;
};
template <class _Alloc>
struct __propagate_on_container_move_assignment<_Alloc, true>
{
typedef typename _Alloc::propagate_on_container_move_assignment type;
};
template <class _Tp, class = void>
struct __has_propagate_on_container_swap : false_type {};
template <class _Tp>
struct __has_propagate_on_container_swap<_Tp,
typename __void_t<typename _Tp::propagate_on_container_swap>::type>
: true_type {};
template <class _Alloc, bool = __has_propagate_on_container_swap<_Alloc>::value>
struct __propagate_on_container_swap
{
typedef false_type type;
};
template <class _Alloc>
struct __propagate_on_container_swap<_Alloc, true>
{
typedef typename _Alloc::propagate_on_container_swap type;
};
template <class _Tp, class = void>
struct __has_is_always_equal : false_type {};
template <class _Tp>
struct __has_is_always_equal<_Tp,
typename __void_t<typename _Tp::is_always_equal>::type>
: true_type {};
template <class _Alloc, bool = __has_is_always_equal<_Alloc>::value>
struct __is_always_equal
{
typedef typename std::__1::is_empty<_Alloc>::type type;
};
template <class _Alloc>
struct __is_always_equal<_Alloc, true>
{
typedef typename _Alloc::is_always_equal type;
};
template <class _Tp, class _Up, bool = __has_rebind<_Tp, _Up>::value>
struct __has_rebind_other
{
private:
struct __two {char __lx; char __lxx;};
template <class _Xp> static __two __test(...);
template <class _Xp> static char __test(typename _Xp::template rebind<_Up>::other* = 0);
public:
static const bool value = sizeof(__test<_Tp>(0)) == 1;
};
template <class _Tp, class _Up>
struct __has_rebind_other<_Tp, _Up, false>
{
static const bool value = false;
};
template <class _Tp, class _Up, bool = __has_rebind_other<_Tp, _Up>::value>
struct __allocator_traits_rebind
{
typedef typename _Tp::template rebind<_Up>::other type;
};
# 1291 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <template <class> class _Alloc, class _Tp, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp>, _Up, true>
{
typedef typename _Alloc<_Tp>::template rebind<_Up>::other type;
};
template <template <class> class _Alloc, class _Tp, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp>, _Up, false>
{
typedef _Alloc<_Up> type;
};
template <template <class, class> class _Alloc, class _Tp, class _A0, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _A0>, _Up, true>
{
typedef typename _Alloc<_Tp, _A0>::template rebind<_Up>::other type;
};
template <template <class, class> class _Alloc, class _Tp, class _A0, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _A0>, _Up, false>
{
typedef _Alloc<_Up, _A0> type;
};
template <template <class, class, class> class _Alloc, class _Tp, class _A0,
class _A1, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1>, _Up, true>
{
typedef typename _Alloc<_Tp, _A0, _A1>::template rebind<_Up>::other type;
};
template <template <class, class, class> class _Alloc, class _Tp, class _A0,
class _A1, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1>, _Up, false>
{
typedef _Alloc<_Up, _A0, _A1> type;
};
template <template <class, class, class, class> class _Alloc, class _Tp, class _A0,
class _A1, class _A2, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1, _A2>, _Up, true>
{
typedef typename _Alloc<_Tp, _A0, _A1, _A2>::template rebind<_Up>::other type;
};
template <template <class, class, class, class> class _Alloc, class _Tp, class _A0,
class _A1, class _A2, class _Up>
struct __allocator_traits_rebind<_Alloc<_Tp, _A0, _A1, _A2>, _Up, false>
{
typedef _Alloc<_Up, _A0, _A1, _A2> type;
};
# 1370 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Alloc, class _SizeType, class _ConstVoidPtr>
struct __has_allocate_hint
: true_type
{
};
# 1471 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Alloc, class _Pointer, class _Args>
struct __has_construct
: false_type
{
};
template <class _Alloc, class _Pointer>
struct __has_destroy
: false_type
{
};
template <class _Alloc>
struct __has_max_size
: true_type
{
};
template <class _Alloc>
struct __has_select_on_container_copy_construction
: false_type
{
};
template <class _Alloc, class _Ptr, bool = __has_difference_type<_Alloc>::value>
struct __alloc_traits_difference_type
{
typedef typename pointer_traits<_Ptr>::difference_type type;
};
template <class _Alloc, class _Ptr>
struct __alloc_traits_difference_type<_Alloc, _Ptr, true>
{
typedef typename _Alloc::difference_type type;
};
template <class _Alloc>
struct __attribute__ ((__type_visibility__("default"))) allocator_traits
{
typedef _Alloc allocator_type;
typedef typename allocator_type::value_type value_type;
typedef typename __pointer_type<value_type, allocator_type>::type pointer;
typedef typename __const_pointer<value_type, pointer, allocator_type>::type const_pointer;
typedef typename __void_pointer<pointer, allocator_type>::type void_pointer;
typedef typename __const_void_pointer<pointer, allocator_type>::type const_void_pointer;
typedef typename __alloc_traits_difference_type<allocator_type, pointer>::type difference_type;
typedef typename __size_type<allocator_type, difference_type>::type size_type;
typedef typename __propagate_on_container_copy_assignment<allocator_type>::type
propagate_on_container_copy_assignment;
typedef typename __propagate_on_container_move_assignment<allocator_type>::type
propagate_on_container_move_assignment;
typedef typename __propagate_on_container_swap<allocator_type>::type
propagate_on_container_swap;
typedef typename __is_always_equal<allocator_type>::type
is_always_equal;
template <class _Tp> struct rebind_alloc
{typedef typename __allocator_traits_rebind<allocator_type, _Tp>::type other;};
template <class _Tp> struct rebind_traits
{typedef allocator_traits<typename rebind_alloc<_Tp>::other> other;};
__attribute__ ((__visibility__("hidden"), __always_inline__))
static pointer allocate(allocator_type& __a, size_type __n)
{return __a.allocate(__n);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static pointer allocate(allocator_type& __a, size_type __n, const_void_pointer __hint)
{return __allocate(__a, __n, __hint,
__has_allocate_hint<allocator_type, size_type, const_void_pointer>());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void deallocate(allocator_type& __a, pointer __p, size_type __n) throw()
{__a.deallocate(__p, __n);}
# 1564 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void construct(allocator_type&, _Tp* __p)
{
::new ((void*)__p) _Tp();
}
template <class _Tp, class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void construct(allocator_type&, _Tp* __p, const _A0& __a0)
{
::new ((void*)__p) _Tp(__a0);
}
template <class _Tp, class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void construct(allocator_type&, _Tp* __p, const _A0& __a0,
const _A1& __a1)
{
::new ((void*)__p) _Tp(__a0, __a1);
}
template <class _Tp, class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void construct(allocator_type&, _Tp* __p, const _A0& __a0,
const _A1& __a1, const _A2& __a2)
{
::new ((void*)__p) _Tp(__a0, __a1, __a2);
}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void destroy(allocator_type& __a, _Tp* __p)
{__destroy(__has_destroy<allocator_type, _Tp*>(), __a, __p);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static size_type max_size(const allocator_type& __a) throw()
{return __max_size(__has_max_size<const allocator_type>(), __a);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static allocator_type
select_on_container_copy_construction(const allocator_type& __a)
{return __select_on_container_copy_construction(
__has_select_on_container_copy_construction<const allocator_type>(),
__a);}
template <class _Ptr>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static
void
__construct_forward(allocator_type& __a, _Ptr __begin1, _Ptr __end1, _Ptr& __begin2)
{
for (; __begin1 != __end1; ++__begin1, ++__begin2)
construct(__a, std::__1::__to_raw_pointer(__begin2), std::__1::move_if_noexcept(*__begin1));
}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static
typename enable_if
<
(is_same<allocator_type, allocator<_Tp> >::value
|| !__has_construct<allocator_type, _Tp*, _Tp>::value) &&
is_trivially_move_constructible<_Tp>::value,
void
>::type
__construct_forward(allocator_type&, _Tp* __begin1, _Tp* __end1, _Tp*& __begin2)
{
ptrdiff_t _Np = __end1 - __begin1;
if (_Np > 0)
{
std::__1::memcpy(__begin2, __begin1, _Np * sizeof(_Tp));
__begin2 += _Np;
}
}
template <class _Iter, class _Ptr>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static
void
__construct_range_forward(allocator_type& __a, _Iter __begin1, _Iter __end1, _Ptr& __begin2)
{
for (; __begin1 != __end1; ++__begin1, (void) ++__begin2)
construct(__a, std::__1::__to_raw_pointer(__begin2), *__begin1);
}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static
typename enable_if
<
(is_same<allocator_type, allocator<_Tp> >::value
|| !__has_construct<allocator_type, _Tp*, _Tp>::value) &&
is_trivially_move_constructible<_Tp>::value,
void
>::type
__construct_range_forward(allocator_type&, _Tp* __begin1, _Tp* __end1, _Tp*& __begin2)
{
typedef typename remove_const<_Tp>::type _Vp;
ptrdiff_t _Np = __end1 - __begin1;
if (_Np > 0)
{
std::__1::memcpy(const_cast<_Vp*>(__begin2), __begin1, _Np * sizeof(_Tp));
__begin2 += _Np;
}
}
template <class _Ptr>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static
void
__construct_backward(allocator_type& __a, _Ptr __begin1, _Ptr __end1, _Ptr& __end2)
{
while (__end1 != __begin1)
{
construct(__a, std::__1::__to_raw_pointer(__end2-1), std::__1::move_if_noexcept(*--__end1));
--__end2;
}
}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static
typename enable_if
<
(is_same<allocator_type, allocator<_Tp> >::value
|| !__has_construct<allocator_type, _Tp*, _Tp>::value) &&
is_trivially_move_constructible<_Tp>::value,
void
>::type
__construct_backward(allocator_type&, _Tp* __begin1, _Tp* __end1, _Tp*& __end2)
{
ptrdiff_t _Np = __end1 - __begin1;
__end2 -= _Np;
if (_Np > 0)
std::__1::memcpy(__end2, __begin1, _Np * sizeof(_Tp));
}
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
static pointer __allocate(allocator_type& __a, size_type __n,
const_void_pointer __hint, true_type)
{return __a.allocate(__n, __hint);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static pointer __allocate(allocator_type& __a, size_type __n,
const_void_pointer, false_type)
{return __a.allocate(__n);}
# 1724 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void __destroy(true_type, allocator_type& __a, _Tp* __p)
{__a.destroy(__p);}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
static void __destroy(false_type, allocator_type&, _Tp* __p)
{
__p->~_Tp();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static size_type __max_size(true_type, const allocator_type& __a) throw()
{return __a.max_size();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static size_type __max_size(false_type, const allocator_type&) throw()
{return numeric_limits<size_type>::max() / sizeof(value_type);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static allocator_type
__select_on_container_copy_construction(true_type, const allocator_type& __a)
{return __a.select_on_container_copy_construction();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
static allocator_type
__select_on_container_copy_construction(false_type, const allocator_type& __a)
{return __a;}
};
template <class _Traits, class _Tp>
struct __rebind_alloc_helper
{
typedef typename _Traits::template rebind_alloc<_Tp>::other type;
};
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) allocator
{
public:
typedef size_t size_type;
typedef ptrdiff_t difference_type;
typedef _Tp* pointer;
typedef const _Tp* const_pointer;
typedef _Tp& reference;
typedef const _Tp& const_reference;
typedef _Tp value_type;
typedef true_type propagate_on_container_move_assignment;
typedef true_type is_always_equal;
template <class _Up> struct rebind {typedef allocator<_Up> other;};
__attribute__ ((__visibility__("hidden"), __always_inline__)) allocator() throw() {}
template <class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) allocator(const allocator<_Up>&) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) pointer address(reference __x) const throw()
{return std::__1::addressof(__x);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_pointer address(const_reference __x) const throw()
{return std::__1::addressof(__x);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer allocate(size_type __n, allocator<void>::const_pointer = 0)
{
if (__n > max_size())
__throw_length_error("allocator<T>::allocate(size_t n)"
" 'n' exceeds maximum supported size");
return static_cast<pointer>(std::__1::__allocate(__n * sizeof(_Tp)));
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void deallocate(pointer __p, size_type) throw()
{std::__1::__libcpp_deallocate((void*)__p);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_type max_size() const throw()
{return size_type(~0) / sizeof(_Tp);}
# 1808 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p)
{
::new((void*)__p) _Tp();
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, _A0& __a0)
{
::new((void*)__p) _Tp(__a0);
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, const _A0& __a0)
{
::new((void*)__p) _Tp(__a0);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, _A0& __a0, _A1& __a1)
{
::new((void*)__p) _Tp(__a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, const _A0& __a0, _A1& __a1)
{
::new((void*)__p) _Tp(__a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, _A0& __a0, const _A1& __a1)
{
::new((void*)__p) _Tp(__a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, const _A0& __a0, const _A1& __a1)
{
::new((void*)__p) _Tp(__a0, __a1);
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void destroy(pointer __p) {__p->~_Tp();}
};
template <class _Tp>
class __attribute__ ((__type_visibility__("default"))) allocator<const _Tp>
{
public:
typedef size_t size_type;
typedef ptrdiff_t difference_type;
typedef const _Tp* pointer;
typedef const _Tp* const_pointer;
typedef const _Tp& reference;
typedef const _Tp& const_reference;
typedef const _Tp value_type;
typedef true_type propagate_on_container_move_assignment;
typedef true_type is_always_equal;
template <class _Up> struct rebind {typedef allocator<_Up> other;};
__attribute__ ((__visibility__("hidden"), __always_inline__)) allocator() throw() {}
template <class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) allocator(const allocator<_Up>&) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_pointer address(const_reference __x) const throw()
{return std::__1::addressof(__x);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) pointer allocate(size_type __n, allocator<void>::const_pointer = 0)
{
if (__n > max_size())
__throw_length_error("allocator<const T>::allocate(size_t n)"
" 'n' exceeds maximum supported size");
return static_cast<pointer>(std::__1::__allocate(__n * sizeof(_Tp)));
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void deallocate(pointer __p, size_type) throw()
{std::__1::__libcpp_deallocate((void*) const_cast<_Tp *>(__p));}
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_type max_size() const throw()
{return size_type(~0) / sizeof(_Tp);}
# 1904 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp();
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, _A0& __a0)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp(__a0);
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, const _A0& __a0)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp(__a0);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, _A0& __a0, _A1& __a1)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp(__a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, const _A0& __a0, _A1& __a1)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp(__a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, _A0& __a0, const _A1& __a1)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp(__a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
construct(pointer __p, const _A0& __a0, const _A1& __a1)
{
::new((void*) const_cast<_Tp *>(__p)) _Tp(__a0, __a1);
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void destroy(pointer __p) {__p->~_Tp();}
};
template <class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const allocator<_Tp>&, const allocator<_Up>&) throw() {return true;}
template <class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const allocator<_Tp>&, const allocator<_Up>&) throw() {return false;}
template <class _OutputIterator, class _Tp>
class __attribute__ ((__type_visibility__("default"))) raw_storage_iterator
: public iterator<output_iterator_tag,
_Tp,
ptrdiff_t,
_Tp*,
raw_storage_iterator<_OutputIterator, _Tp>&>
{
private:
_OutputIterator __x_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit raw_storage_iterator(_OutputIterator __x) : __x_(__x) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) raw_storage_iterator& operator*() {return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) raw_storage_iterator& operator=(const _Tp& __element)
{::new(&*__x_) _Tp(__element); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) raw_storage_iterator& operator++() {++__x_; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) raw_storage_iterator operator++(int)
{raw_storage_iterator __t(*this); ++__x_; return __t;}
};
template <class _Tp>
pair<_Tp*, ptrdiff_t>
get_temporary_buffer(ptrdiff_t __n) throw()
{
pair<_Tp*, ptrdiff_t> __r(0, 0);
const ptrdiff_t __m = (~ptrdiff_t(0) ^
ptrdiff_t(ptrdiff_t(1) << (sizeof(ptrdiff_t) * 8 - 1)))
/ sizeof(_Tp);
if (__n > __m)
__n = __m;
while (__n > 0)
{
__r.first = static_cast<_Tp*>(::operator new(__n * sizeof(_Tp), nothrow));
if (__r.first)
{
__r.second = __n;
break;
}
__n /= 2;
}
return __r;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void return_temporary_buffer(_Tp* __p) throw() {::operator delete(__p);}
template <class _Tp>
struct auto_ptr_ref
{
_Tp* __ptr_;
};
template<class _Tp>
class __attribute__ ((__type_visibility__("default"))) auto_ptr
{
private:
_Tp* __ptr_;
public:
typedef _Tp element_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit auto_ptr(_Tp* __p = 0) throw() : __ptr_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) auto_ptr(auto_ptr& __p) throw() : __ptr_(__p.release()) {}
template<class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) auto_ptr(auto_ptr<_Up>& __p) throw()
: __ptr_(__p.release()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) auto_ptr& operator=(auto_ptr& __p) throw()
{reset(__p.release()); return *this;}
template<class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) auto_ptr& operator=(auto_ptr<_Up>& __p) throw()
{reset(__p.release()); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) auto_ptr& operator=(auto_ptr_ref<_Tp> __p) throw()
{reset(__p.__ptr_); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) ~auto_ptr() throw() {delete __ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Tp& operator*() const throw()
{return *__ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Tp* operator->() const throw() {return __ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Tp* get() const throw() {return __ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Tp* release() throw()
{
_Tp* __t = __ptr_;
__ptr_ = 0;
return __t;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void reset(_Tp* __p = 0) throw()
{
if (__ptr_ != __p)
delete __ptr_;
__ptr_ = __p;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) auto_ptr(auto_ptr_ref<_Tp> __p) throw() : __ptr_(__p.__ptr_) {}
template<class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) operator auto_ptr_ref<_Up>() throw()
{auto_ptr_ref<_Up> __t; __t.__ptr_ = release(); return __t;}
template<class _Up> __attribute__ ((__visibility__("hidden"), __always_inline__)) operator auto_ptr<_Up>() throw()
{return auto_ptr<_Up>(release());}
};
template <>
class __attribute__ ((__type_visibility__("default"))) auto_ptr<void>
{
public:
typedef void element_type;
};
template <class _Tp, int _Idx,
bool _CanBeEmptyBase =
is_empty<_Tp>::value && !__libcpp_is_final<_Tp>::value>
struct __compressed_pair_elem {
typedef _Tp _ParamT;
typedef _Tp& reference;
typedef const _Tp& const_reference;
# 2105 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
__attribute__ ((__visibility__("hidden"), __always_inline__)) __compressed_pair_elem() : __value_() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__compressed_pair_elem(_ParamT __p) : __value_(std::forward<_ParamT>(__p)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference __get() throw() { return __value_; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference __get() const throw() { return __value_; }
private:
_Tp __value_;
};
template <class _Tp, int _Idx>
struct __compressed_pair_elem<_Tp, _Idx, true> : private _Tp {
typedef _Tp _ParamT;
typedef _Tp& reference;
typedef const _Tp& const_reference;
typedef _Tp __value_type;
# 2142 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
__attribute__ ((__visibility__("hidden"), __always_inline__)) __compressed_pair_elem() : __value_type() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__compressed_pair_elem(_ParamT __p)
: __value_type(std::forward<_ParamT>(__p)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference __get() throw() { return *this; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference __get() const throw() { return *this; }
};
struct __second_tag {};
template <class _T1, class _T2>
class __compressed_pair : private __compressed_pair_elem<_T1, 0>,
private __compressed_pair_elem<_T2, 1> {
typedef __compressed_pair_elem<_T1, 0> _Base1;
typedef __compressed_pair_elem<_T2, 1> _Base2;
_Static_assert((!is_same<_T1, _T2>::value), "__compressed_pair cannot be instantated when T1 and T2 are the same type; " "The current implementation is NOT ABI-compatible with the previous " "implementation for this configuration");
public:
# 2209 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
__compressed_pair() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit
__compressed_pair(_T1 __t1) : _Base1(std::__1::forward<_T1>(__t1)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__compressed_pair(__second_tag, _T2 __t2)
: _Base1(), _Base2(std::__1::forward<_T2>(__t2)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__compressed_pair(_T1 __t1, _T2 __t2)
: _Base1(std::__1::forward<_T1>(__t1)), _Base2(std::__1::forward<_T2>(__t2)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Base1::reference first() throw() {
return static_cast<_Base1&>(*this).__get();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Base1::const_reference first() const throw() {
return static_cast<_Base1 const&>(*this).__get();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Base2::reference second() throw() {
return static_cast<_Base2&>(*this).__get();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename _Base2::const_reference second() const throw() {
return static_cast<_Base2 const&>(*this).__get();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(__compressed_pair& __x)
{
using std::swap;
swap(first(), __x.first());
swap(second(), __x.second());
}
};
template <class _T1, class _T2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(__compressed_pair<_T1, _T2>& __x, __compressed_pair<_T1, _T2>& __y)
{
__x.swap(__y);
}
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) default_delete {
_Static_assert(!is_function<_Tp>::value, "default_delete cannot be instantiated for function types");
__attribute__ ((__visibility__("hidden"), __always_inline__)) default_delete() {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
default_delete(const default_delete<_Up>&,
typename enable_if<is_convertible<_Up*, _Tp*>::value>::type* =
0) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void operator()(_Tp* __ptr) const throw() {
_Static_assert(sizeof(_Tp) > 0, "default_delete can not delete incomplete type");
_Static_assert(!is_void<_Tp>::value, "default_delete can not delete incomplete type");
delete __ptr;
}
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) default_delete<_Tp[]> {
private:
template <class _Up>
struct _EnableIfConvertible
: enable_if<is_convertible<_Up(*)[], _Tp(*)[]>::value> {};
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) default_delete() {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
default_delete(const default_delete<_Up[]>&,
typename _EnableIfConvertible<_Up>::type* = 0) throw() {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename _EnableIfConvertible<_Up>::type
operator()(_Up* __ptr) const throw() {
_Static_assert(sizeof(_Tp) > 0, "default_delete can not delete incomplete type");
_Static_assert(!is_void<_Tp>::value, "default_delete can not delete void type");
delete[] __ptr;
}
};
# 2346 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Tp, class _Dp = default_delete<_Tp> >
class __attribute__ ((__type_visibility__("default"))) unique_ptr {
public:
typedef _Tp element_type;
typedef _Dp deleter_type;
typedef typename __pointer_type<_Tp, deleter_type>::type pointer;
_Static_assert(!is_rvalue_reference<deleter_type>::value, "the specified deleter type cannot be an rvalue reference");
private:
__compressed_pair<pointer, deleter_type> __ptr_;
struct __nat { int __for_bool_; };
# 2481 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
private:
unique_ptr(unique_ptr&);
template <class _Up, class _Ep> unique_ptr(unique_ptr<_Up, _Ep>&);
unique_ptr& operator=(unique_ptr&);
template <class _Up, class _Ep> unique_ptr& operator=(unique_ptr<_Up, _Ep>&);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr() : __ptr_(pointer())
{
_Static_assert(!is_pointer<deleter_type>::value, "unique_ptr constructed with null function pointer deleter");
_Static_assert(is_default_constructible<deleter_type>::value, "unique_ptr::deleter_type is not default constructible");
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(nullptr_t) : __ptr_(pointer())
{
_Static_assert(!is_pointer<deleter_type>::value, "unique_ptr constructed with null function pointer deleter");
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit unique_ptr(pointer __p)
: __ptr_(std::__1::move(__p)) {
_Static_assert(!is_pointer<deleter_type>::value, "unique_ptr constructed with null function pointer deleter");
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator __rv<unique_ptr>() {
return __rv<unique_ptr>(*this);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(__rv<unique_ptr> __u)
: __ptr_(__u->release(),
std::__1::forward<deleter_type>(__u->get_deleter())) {}
template <class _Up, class _Ep>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<
!is_array<_Up>::value &&
is_convertible<typename unique_ptr<_Up, _Ep>::pointer,
pointer>::value &&
is_assignable<deleter_type&, _Ep&>::value,
unique_ptr&>::type
operator=(unique_ptr<_Up, _Ep> __u) {
reset(__u.release());
__ptr_.second() = std::__1::forward<_Ep>(__u.get_deleter());
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(pointer __p, deleter_type __d)
: __ptr_(std::__1::move(__p), std::__1::move(__d)) {}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<is_convertible<_Up*, _Tp*>::value &&
is_same<_Dp, default_delete<_Tp> >::value,
unique_ptr&>::type
operator=(auto_ptr<_Up> __p) {
reset(__p.release());
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
~unique_ptr() { reset(); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr& operator=(nullptr_t) throw() {
reset();
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename add_lvalue_reference<_Tp>::type
operator*() const {
return *__ptr_.first();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer operator->() const throw() {
return __ptr_.first();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer get() const throw() {
return __ptr_.first();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
deleter_type& get_deleter() throw() {
return __ptr_.second();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const deleter_type& get_deleter() const throw() {
return __ptr_.second();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const throw() {
return __ptr_.first() != std::__1::__get_nullptr_t();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer release() throw() {
pointer __t = __ptr_.first();
__ptr_.first() = pointer();
return __t;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void reset(pointer __p = pointer()) throw() {
pointer __tmp = __ptr_.first();
__ptr_.first() = __p;
if (__tmp)
__ptr_.second()(__tmp);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(unique_ptr& __u) throw() {
__ptr_.swap(__u.__ptr_);
}
};
template <class _Tp, class _Dp>
class __attribute__ ((__type_visibility__("default"))) unique_ptr<_Tp[], _Dp> {
public:
typedef _Tp element_type;
typedef _Dp deleter_type;
typedef typename __pointer_type<_Tp, deleter_type>::type pointer;
private:
__compressed_pair<pointer, deleter_type> __ptr_;
template <class _From>
struct _CheckArrayPointerConversion : is_same<_From, pointer> {};
template <class _FromElem>
struct _CheckArrayPointerConversion<_FromElem*>
: integral_constant<bool,
is_same<_FromElem*, pointer>::value ||
(is_same<pointer, element_type*>::value &&
is_convertible<_FromElem(*)[], element_type(*)[]>::value)
>
{};
# 2770 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
private:
template <class _Up> explicit unique_ptr(_Up);
unique_ptr(unique_ptr&);
template <class _Up> unique_ptr(unique_ptr<_Up>&);
unique_ptr& operator=(unique_ptr&);
template <class _Up> unique_ptr& operator=(unique_ptr<_Up>&);
template <class _Up>
unique_ptr(_Up __u,
typename conditional<
is_reference<deleter_type>::value, deleter_type,
typename add_lvalue_reference<const deleter_type>::type>::type,
typename enable_if<is_convertible<_Up, pointer>::value,
__nat>::type = __nat());
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr() : __ptr_(pointer()) {
_Static_assert(!is_pointer<deleter_type>::value, "unique_ptr constructed with null function pointer deleter");
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(nullptr_t) : __ptr_(pointer()) {
_Static_assert(!is_pointer<deleter_type>::value, "unique_ptr constructed with null function pointer deleter");
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit unique_ptr(pointer __p) : __ptr_(__p) {
_Static_assert(!is_pointer<deleter_type>::value, "unique_ptr constructed with null function pointer deleter");
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(pointer __p, deleter_type __d)
: __ptr_(__p, std::__1::forward<deleter_type>(__d)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(nullptr_t, deleter_type __d)
: __ptr_(pointer(), std::__1::forward<deleter_type>(__d)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator __rv<unique_ptr>() {
return __rv<unique_ptr>(*this);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr(__rv<unique_ptr> __u)
: __ptr_(__u->release(),
std::__1::forward<deleter_type>(__u->get_deleter())) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr& operator=(__rv<unique_ptr> __u) {
reset(__u->release());
__ptr_.second() = std::__1::forward<deleter_type>(__u->get_deleter());
return *this;
}
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~unique_ptr() { reset(); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr& operator=(nullptr_t) throw() {
reset();
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename add_lvalue_reference<_Tp>::type
operator[](size_t __i) const {
return __ptr_.first()[__i];
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer get() const throw() {
return __ptr_.first();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
deleter_type& get_deleter() throw() {
return __ptr_.second();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const deleter_type& get_deleter() const throw() {
return __ptr_.second();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const throw() {
return __ptr_.first() != std::__1::__get_nullptr_t();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer release() throw() {
pointer __t = __ptr_.first();
__ptr_.first() = pointer();
return __t;
}
template <class _Pp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<
_CheckArrayPointerConversion<_Pp>::value
>::type
reset(_Pp __p) throw() {
pointer __tmp = __ptr_.first();
__ptr_.first() = __p;
if (__tmp)
__ptr_.second()(__tmp);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void reset(nullptr_t = std::__1::__get_nullptr_t()) throw() {
pointer __tmp = __ptr_.first();
__ptr_.first() = std::__1::__get_nullptr_t();
if (__tmp)
__ptr_.second()(__tmp);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(unique_ptr& __u) throw() {
__ptr_.swap(__u.__ptr_);
}
};
template <class _Tp, class _Dp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<
__is_swappable<_Dp>::value,
void
>::type
swap(unique_ptr<_Tp, _Dp>& __x, unique_ptr<_Tp, _Dp>& __y) throw() {__x.swap(__y);}
template <class _T1, class _D1, class _T2, class _D2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const unique_ptr<_T1, _D1>& __x, const unique_ptr<_T2, _D2>& __y) {return __x.get() == __y.get();}
template <class _T1, class _D1, class _T2, class _D2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const unique_ptr<_T1, _D1>& __x, const unique_ptr<_T2, _D2>& __y) {return !(__x == __y);}
template <class _T1, class _D1, class _T2, class _D2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator< (const unique_ptr<_T1, _D1>& __x, const unique_ptr<_T2, _D2>& __y)
{
typedef typename unique_ptr<_T1, _D1>::pointer _P1;
typedef typename unique_ptr<_T2, _D2>::pointer _P2;
typedef typename common_type<_P1, _P2>::type _Vp;
return less<_Vp>()(__x.get(), __y.get());
}
template <class _T1, class _D1, class _T2, class _D2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const unique_ptr<_T1, _D1>& __x, const unique_ptr<_T2, _D2>& __y) {return __y < __x;}
template <class _T1, class _D1, class _T2, class _D2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const unique_ptr<_T1, _D1>& __x, const unique_ptr<_T2, _D2>& __y) {return !(__y < __x);}
template <class _T1, class _D1, class _T2, class _D2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const unique_ptr<_T1, _D1>& __x, const unique_ptr<_T2, _D2>& __y) {return !(__x < __y);}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const unique_ptr<_T1, _D1>& __x, nullptr_t) throw()
{
return !__x;
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(nullptr_t, const unique_ptr<_T1, _D1>& __x) throw()
{
return !__x;
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const unique_ptr<_T1, _D1>& __x, nullptr_t) throw()
{
return static_cast<bool>(__x);
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(nullptr_t, const unique_ptr<_T1, _D1>& __x) throw()
{
return static_cast<bool>(__x);
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const unique_ptr<_T1, _D1>& __x, nullptr_t)
{
typedef typename unique_ptr<_T1, _D1>::pointer _P1;
return less<_P1>()(__x.get(), std::__1::__get_nullptr_t());
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(nullptr_t, const unique_ptr<_T1, _D1>& __x)
{
typedef typename unique_ptr<_T1, _D1>::pointer _P1;
return less<_P1>()(std::__1::__get_nullptr_t(), __x.get());
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const unique_ptr<_T1, _D1>& __x, nullptr_t)
{
return std::__1::__get_nullptr_t() < __x;
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(nullptr_t, const unique_ptr<_T1, _D1>& __x)
{
return __x < std::__1::__get_nullptr_t();
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const unique_ptr<_T1, _D1>& __x, nullptr_t)
{
return !(std::__1::__get_nullptr_t() < __x);
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(nullptr_t, const unique_ptr<_T1, _D1>& __x)
{
return !(__x < std::__1::__get_nullptr_t());
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const unique_ptr<_T1, _D1>& __x, nullptr_t)
{
return !(__x < std::__1::__get_nullptr_t());
}
template <class _T1, class _D1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(nullptr_t, const unique_ptr<_T1, _D1>& __x)
{
return !(std::__1::__get_nullptr_t() < __x);
}
template <class _Tp, class _Dp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unique_ptr<_Tp, _Dp>
move(unique_ptr<_Tp, _Dp>& __t)
{
return unique_ptr<_Tp, _Dp>(__rv<unique_ptr<_Tp, _Dp> >(__t));
}
# 3096 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Tp, class _Dp>
struct __attribute__ ((__type_visibility__("default"))) hash<unique_ptr<_Tp, _Dp> >
{
typedef unique_ptr<_Tp, _Dp> argument_type;
typedef size_t result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
result_type operator()(const argument_type& __ptr) const
{
typedef typename argument_type::pointer pointer;
return hash<pointer>()(__ptr.get());
}
};
struct __destruct_n
{
private:
size_t __size_;
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __process(_Tp* __p, false_type) throw()
{for (size_t __i = 0; __i < __size_; ++__i, ++__p) __p->~_Tp();}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __process(_Tp*, true_type) throw()
{}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __incr(false_type) throw()
{++__size_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __incr(true_type) throw()
{}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __set(size_t __s, false_type) throw()
{__size_ = __s;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __set(size_t, true_type) throw()
{}
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __destruct_n(size_t __s) throw()
: __size_(__s) {}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __incr(_Tp*) throw()
{__incr(integral_constant<bool, is_trivially_destructible<_Tp>::value>());}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __set(size_t __s, _Tp*) throw()
{__set(__s, integral_constant<bool, is_trivially_destructible<_Tp>::value>());}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__)) void operator()(_Tp* __p) throw()
{__process(__p, integral_constant<bool, is_trivially_destructible<_Tp>::value>());}
};
template <class _Alloc>
class __allocator_destructor
{
typedef allocator_traits<_Alloc> __alloc_traits;
public:
typedef typename __alloc_traits::pointer pointer;
typedef typename __alloc_traits::size_type size_type;
private:
_Alloc& __alloc_;
size_type __s_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __allocator_destructor(_Alloc& __a, size_type __s)
throw()
: __alloc_(__a), __s_(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator()(pointer __p) throw()
{__alloc_traits::deallocate(__alloc_, __p, __s_);}
};
template <class _InputIterator, class _ForwardIterator>
_ForwardIterator
uninitialized_copy(_InputIterator __f, _InputIterator __l, _ForwardIterator __r)
{
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
_ForwardIterator __s = __r;
try
{
for (; __f != __l; ++__f, (void) ++__r)
::new (static_cast<void*>(std::__1::addressof(*__r))) value_type(*__f);
}
catch (...)
{
for (; __s != __r; ++__s)
__s->~value_type();
throw;
}
return __r;
}
template <class _InputIterator, class _Size, class _ForwardIterator>
_ForwardIterator
uninitialized_copy_n(_InputIterator __f, _Size __n, _ForwardIterator __r)
{
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
_ForwardIterator __s = __r;
try
{
for (; __n > 0; ++__f, (void) ++__r, (void) --__n)
::new (static_cast<void*>(std::__1::addressof(*__r))) value_type(*__f);
}
catch (...)
{
for (; __s != __r; ++__s)
__s->~value_type();
throw;
}
return __r;
}
template <class _ForwardIterator, class _Tp>
void
uninitialized_fill(_ForwardIterator __f, _ForwardIterator __l, const _Tp& __x)
{
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
_ForwardIterator __s = __f;
try
{
for (; __f != __l; ++__f)
::new (static_cast<void*>(std::__1::addressof(*__f))) value_type(__x);
}
catch (...)
{
for (; __s != __f; ++__s)
__s->~value_type();
throw;
}
}
template <class _ForwardIterator, class _Size, class _Tp>
_ForwardIterator
uninitialized_fill_n(_ForwardIterator __f, _Size __n, const _Tp& __x)
{
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
_ForwardIterator __s = __f;
try
{
for (; __n > 0; ++__f, (void) --__n)
::new (static_cast<void*>(std::__1::addressof(*__f))) value_type(__x);
}
catch (...)
{
for (; __s != __f; ++__s)
__s->~value_type();
throw;
}
return __f;
}
# 3420 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) _Tp
__libcpp_atomic_refcount_increment(_Tp& __t) throw()
{
return __atomic_add_fetch(&__t, 1, 0);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) _Tp
__libcpp_atomic_refcount_decrement(_Tp& __t) throw()
{
return __atomic_add_fetch(&__t, -1, 4);
}
class __attribute__ ((__visibility__("default"))) bad_weak_ptr
: public std::exception
{
public:
virtual ~bad_weak_ptr() throw();
virtual const char* what() const throw();
};
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_bad_weak_ptr()
{
throw bad_weak_ptr();
}
template<class _Tp> class __attribute__ ((__type_visibility__("default"))) weak_ptr;
class __attribute__ ((__visibility__("default"))) __shared_count
{
__shared_count(const __shared_count&);
__shared_count& operator=(const __shared_count&);
protected:
long __shared_owners_;
virtual ~__shared_count();
private:
virtual void __on_zero_shared() throw() = 0;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __shared_count(long __refs = 0) throw()
: __shared_owners_(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __add_shared() throw() {
__libcpp_atomic_refcount_increment(__shared_owners_);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __release_shared() throw() {
if (__libcpp_atomic_refcount_decrement(__shared_owners_) == -1) {
__on_zero_shared();
return true;
}
return false;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
long use_count() const throw() {
return __libcpp_relaxed_load(&__shared_owners_) + 1;
}
};
class __attribute__ ((__visibility__("default"))) __shared_weak_count
: private __shared_count
{
long __shared_weak_owners_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __shared_weak_count(long __refs = 0) throw()
: __shared_count(__refs),
__shared_weak_owners_(__refs) {}
protected:
virtual ~__shared_weak_count();
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __add_shared() throw() {
__shared_count::__add_shared();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __add_weak() throw() {
__libcpp_atomic_refcount_increment(__shared_weak_owners_);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __release_shared() throw() {
if (__shared_count::__release_shared())
__release_weak();
}
void __release_weak() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
long use_count() const throw() {return __shared_count::use_count();}
__shared_weak_count* lock() throw();
virtual const void* __get_deleter(const type_info&) const throw();
private:
virtual void __on_zero_shared_weak() throw() = 0;
};
template <class _Tp, class _Dp, class _Alloc>
class __shared_ptr_pointer
: public __shared_weak_count
{
__compressed_pair<__compressed_pair<_Tp, _Dp>, _Alloc> __data_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
__shared_ptr_pointer(_Tp __p, _Dp __d, _Alloc __a)
: __data_(__compressed_pair<_Tp, _Dp>(__p, std::__1::move(__d)), std::__1::move(__a)) {}
virtual const void* __get_deleter(const type_info&) const throw();
private:
virtual void __on_zero_shared() throw();
virtual void __on_zero_shared_weak() throw();
};
template <class _Tp, class _Dp, class _Alloc>
const void*
__shared_ptr_pointer<_Tp, _Dp, _Alloc>::__get_deleter(const type_info& __t) const throw()
{
return __t == typeid(_Dp) ? std::__1::addressof(__data_.first().second()) : std::__1::__get_nullptr_t();
}
template <class _Tp, class _Dp, class _Alloc>
void
__shared_ptr_pointer<_Tp, _Dp, _Alloc>::__on_zero_shared() throw()
{
__data_.first().second()(__data_.first().first());
__data_.first().second().~_Dp();
}
template <class _Tp, class _Dp, class _Alloc>
void
__shared_ptr_pointer<_Tp, _Dp, _Alloc>::__on_zero_shared_weak() throw()
{
typedef typename __allocator_traits_rebind<_Alloc, __shared_ptr_pointer>::type _Al;
typedef allocator_traits<_Al> _ATraits;
typedef pointer_traits<typename _ATraits::pointer> _PTraits;
_Al __a(__data_.second());
__data_.second().~_Alloc();
__a.deallocate(_PTraits::pointer_to(*this), 1);
}
template <class _Tp, class _Alloc>
class __shared_ptr_emplace
: public __shared_weak_count
{
__compressed_pair<_Alloc, _Tp> __data_;
public:
# 3623 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
__shared_ptr_emplace(_Alloc __a)
: __data_(__a) {}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
__shared_ptr_emplace(_Alloc __a, _A0& __a0)
: __data_(__a, _Tp(__a0)) {}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
__shared_ptr_emplace(_Alloc __a, _A0& __a0, _A1& __a1)
: __data_(__a, _Tp(__a0, __a1)) {}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
__shared_ptr_emplace(_Alloc __a, _A0& __a0, _A1& __a1, _A2& __a2)
: __data_(__a, _Tp(__a0, __a1, __a2)) {}
private:
virtual void __on_zero_shared() throw();
virtual void __on_zero_shared_weak() throw();
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp* get() throw() {return &__data_.second();}
};
template <class _Tp, class _Alloc>
void
__shared_ptr_emplace<_Tp, _Alloc>::__on_zero_shared() throw()
{
__data_.second().~_Tp();
}
template <class _Tp, class _Alloc>
void
__shared_ptr_emplace<_Tp, _Alloc>::__on_zero_shared_weak() throw()
{
typedef typename __allocator_traits_rebind<_Alloc, __shared_ptr_emplace>::type _Al;
typedef allocator_traits<_Al> _ATraits;
typedef pointer_traits<typename _ATraits::pointer> _PTraits;
_Al __a(__data_.first());
__data_.first().~_Alloc();
__a.deallocate(_PTraits::pointer_to(*this), 1);
}
struct __shared_ptr_dummy_rebind_allocator_type;
template <>
class __attribute__ ((__type_visibility__("default"))) allocator<__shared_ptr_dummy_rebind_allocator_type>
{
public:
template <class _Other>
struct rebind
{
typedef allocator<_Other> other;
};
};
template<class _Tp> class __attribute__ ((__type_visibility__("default"))) enable_shared_from_this;
template<class _Tp>
class __attribute__ ((__type_visibility__("default"))) shared_ptr
{
public:
typedef _Tp element_type;
private:
element_type* __ptr_;
__shared_weak_count* __cntrl_;
struct __nat {int __for_bool_;};
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr(nullptr_t) throw();
template<class _Yp>
explicit shared_ptr(_Yp* __p,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type = __nat());
template<class _Yp, class _Dp>
shared_ptr(_Yp* __p, _Dp __d,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type = __nat());
template<class _Yp, class _Dp, class _Alloc>
shared_ptr(_Yp* __p, _Dp __d, _Alloc __a,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type = __nat());
template <class _Dp> shared_ptr(nullptr_t __p, _Dp __d);
template <class _Dp, class _Alloc> shared_ptr(nullptr_t __p, _Dp __d, _Alloc __a);
template<class _Yp> __attribute__ ((__visibility__("hidden"), __always_inline__)) shared_ptr(const shared_ptr<_Yp>& __r, element_type* __p) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr(const shared_ptr& __r) throw();
template<class _Yp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr(const shared_ptr<_Yp>& __r,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type = __nat())
throw();
template<class _Yp> explicit shared_ptr(const weak_ptr<_Yp>& __r,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type= __nat());
template<class _Yp>
shared_ptr(auto_ptr<_Yp> __r,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type = __nat());
# 3763 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Yp, class _Dp>
shared_ptr(unique_ptr<_Yp, _Dp>,
typename enable_if
<
!is_lvalue_reference<_Dp>::value &&
!is_array<_Yp>::value &&
is_convertible<typename unique_ptr<_Yp, _Dp>::pointer, element_type*>::value,
__nat
>::type = __nat());
template <class _Yp, class _Dp>
shared_ptr(unique_ptr<_Yp, _Dp>,
typename enable_if
<
is_lvalue_reference<_Dp>::value &&
!is_array<_Yp>::value &&
is_convertible<typename unique_ptr<_Yp, _Dp>::pointer, element_type*>::value,
__nat
>::type = __nat());
~shared_ptr();
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr& operator=(const shared_ptr& __r) throw();
template<class _Yp>
typename enable_if
<
is_convertible<_Yp*, element_type*>::value,
shared_ptr&
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator=(const shared_ptr<_Yp>& __r) throw();
# 3819 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Yp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
!is_array<_Yp>::value &&
is_convertible<_Yp*, element_type*>::value,
shared_ptr&
>::type
operator=(auto_ptr<_Yp> __r);
template <class _Yp, class _Dp>
typename enable_if
<
!is_array<_Yp>::value &&
is_convertible<typename unique_ptr<_Yp, _Dp>::pointer, element_type*>::value,
shared_ptr&
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator=(unique_ptr<_Yp, _Dp> __r);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(shared_ptr& __r) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void reset() throw();
template<class _Yp>
typename enable_if
<
is_convertible<_Yp*, element_type*>::value,
void
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
reset(_Yp* __p);
template<class _Yp, class _Dp>
typename enable_if
<
is_convertible<_Yp*, element_type*>::value,
void
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
reset(_Yp* __p, _Dp __d);
template<class _Yp, class _Dp, class _Alloc>
typename enable_if
<
is_convertible<_Yp*, element_type*>::value,
void
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
reset(_Yp* __p, _Dp __d, _Alloc __a);
__attribute__ ((__visibility__("hidden"), __always_inline__))
element_type* get() const throw() {return __ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename add_lvalue_reference<element_type>::type operator*() const throw()
{return *__ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
element_type* operator->() const throw() {return __ptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
long use_count() const throw() {return __cntrl_ ? __cntrl_->use_count() : 0;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool unique() const throw() {return use_count() == 1;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const throw() {return get() != 0;}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool owner_before(shared_ptr<_Up> const& __p) const throw()
{return __cntrl_ < __p.__cntrl_;}
template <class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool owner_before(weak_ptr<_Up> const& __p) const throw()
{return __cntrl_ < __p.__cntrl_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
__owner_equivalent(const shared_ptr& __p) const
{return __cntrl_ == __p.__cntrl_;}
template <class _Dp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Dp* __get_deleter() const throw()
{return static_cast<_Dp*>(__cntrl_
? const_cast<void *>(__cntrl_->__get_deleter(typeid(_Dp)))
: std::__1::__get_nullptr_t());}
# 3923 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
static shared_ptr<_Tp> make_shared();
template<class _A0>
static shared_ptr<_Tp> make_shared(_A0&);
template<class _A0, class _A1>
static shared_ptr<_Tp> make_shared(_A0&, _A1&);
template<class _A0, class _A1, class _A2>
static shared_ptr<_Tp> make_shared(_A0&, _A1&, _A2&);
template<class _Alloc>
static shared_ptr<_Tp>
allocate_shared(const _Alloc& __a);
template<class _Alloc, class _A0>
static shared_ptr<_Tp>
allocate_shared(const _Alloc& __a, _A0& __a0);
template<class _Alloc, class _A0, class _A1>
static shared_ptr<_Tp>
allocate_shared(const _Alloc& __a, _A0& __a0, _A1& __a1);
template<class _Alloc, class _A0, class _A1, class _A2>
static shared_ptr<_Tp>
allocate_shared(const _Alloc& __a, _A0& __a0, _A1& __a1, _A2& __a2);
private:
template <class _Yp, bool = is_function<_Yp>::value>
struct __shared_ptr_default_allocator
{
typedef allocator<_Yp> type;
};
template <class _Yp>
struct __shared_ptr_default_allocator<_Yp, true>
{
typedef allocator<__shared_ptr_dummy_rebind_allocator_type> type;
};
template <class _Yp, class _OrigPtr>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if<is_convertible<_OrigPtr*,
const enable_shared_from_this<_Yp>*
>::value,
void>::type
__enable_weak_this(const enable_shared_from_this<_Yp>* __e,
_OrigPtr* __ptr) throw()
{
typedef typename remove_cv<_Yp>::type _RawYp;
if (__e && __e->__weak_this_.expired())
{
__e->__weak_this_ = shared_ptr<_RawYp>(*this,
const_cast<_RawYp*>(static_cast<const _Yp*>(__ptr)));
}
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __enable_weak_this(...) throw() {}
template <class _Up> friend class __attribute__ ((__type_visibility__("default"))) shared_ptr;
template <class _Up> friend class __attribute__ ((__type_visibility__("default"))) weak_ptr;
};
template<class _Tp>
inline
shared_ptr<_Tp>::shared_ptr() throw()
: __ptr_(0),
__cntrl_(0)
{
}
template<class _Tp>
inline
shared_ptr<_Tp>::shared_ptr(nullptr_t) throw()
: __ptr_(0),
__cntrl_(0)
{
}
template<class _Tp>
template<class _Yp>
shared_ptr<_Tp>::shared_ptr(_Yp* __p,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type)
: __ptr_(__p)
{
unique_ptr<_Yp> __hold(__p);
typedef typename __shared_ptr_default_allocator<_Yp>::type _AllocT;
typedef __shared_ptr_pointer<_Yp*, default_delete<_Yp>, _AllocT > _CntrlBlk;
__cntrl_ = new _CntrlBlk(__p, default_delete<_Yp>(), _AllocT());
__hold.release();
__enable_weak_this(__p, __p);
}
template<class _Tp>
template<class _Yp, class _Dp>
shared_ptr<_Tp>::shared_ptr(_Yp* __p, _Dp __d,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type)
: __ptr_(__p)
{
try
{
typedef typename __shared_ptr_default_allocator<_Yp>::type _AllocT;
typedef __shared_ptr_pointer<_Yp*, _Dp, _AllocT > _CntrlBlk;
__cntrl_ = new _CntrlBlk(__p, __d, _AllocT());
__enable_weak_this(__p, __p);
}
catch (...)
{
__d(__p);
throw;
}
}
template<class _Tp>
template<class _Dp>
shared_ptr<_Tp>::shared_ptr(nullptr_t __p, _Dp __d)
: __ptr_(0)
{
try
{
typedef typename __shared_ptr_default_allocator<_Tp>::type _AllocT;
typedef __shared_ptr_pointer<nullptr_t, _Dp, _AllocT > _CntrlBlk;
__cntrl_ = new _CntrlBlk(__p, __d, _AllocT());
}
catch (...)
{
__d(__p);
throw;
}
}
template<class _Tp>
template<class _Yp, class _Dp, class _Alloc>
shared_ptr<_Tp>::shared_ptr(_Yp* __p, _Dp __d, _Alloc __a,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type)
: __ptr_(__p)
{
try
{
typedef __shared_ptr_pointer<_Yp*, _Dp, _Alloc> _CntrlBlk;
typedef typename __allocator_traits_rebind<_Alloc, _CntrlBlk>::type _A2;
typedef __allocator_destructor<_A2> _D2;
_A2 __a2(__a);
unique_ptr<_CntrlBlk, _D2> __hold2(__a2.allocate(1), _D2(__a2, 1));
::new(static_cast<void*>(std::__1::addressof(*__hold2.get())))
_CntrlBlk(__p, __d, __a);
__cntrl_ = std::__1::addressof(*__hold2.release());
__enable_weak_this(__p, __p);
}
catch (...)
{
__d(__p);
throw;
}
}
template<class _Tp>
template<class _Dp, class _Alloc>
shared_ptr<_Tp>::shared_ptr(nullptr_t __p, _Dp __d, _Alloc __a)
: __ptr_(0)
{
try
{
typedef __shared_ptr_pointer<nullptr_t, _Dp, _Alloc> _CntrlBlk;
typedef typename __allocator_traits_rebind<_Alloc, _CntrlBlk>::type _A2;
typedef __allocator_destructor<_A2> _D2;
_A2 __a2(__a);
unique_ptr<_CntrlBlk, _D2> __hold2(__a2.allocate(1), _D2(__a2, 1));
::new(static_cast<void*>(std::__1::addressof(*__hold2.get())))
_CntrlBlk(__p, __d, __a);
__cntrl_ = std::__1::addressof(*__hold2.release());
}
catch (...)
{
__d(__p);
throw;
}
}
template<class _Tp>
template<class _Yp>
inline
shared_ptr<_Tp>::shared_ptr(const shared_ptr<_Yp>& __r, element_type *__p) throw()
: __ptr_(__p),
__cntrl_(__r.__cntrl_)
{
if (__cntrl_)
__cntrl_->__add_shared();
}
template<class _Tp>
inline
shared_ptr<_Tp>::shared_ptr(const shared_ptr& __r) throw()
: __ptr_(__r.__ptr_),
__cntrl_(__r.__cntrl_)
{
if (__cntrl_)
__cntrl_->__add_shared();
}
template<class _Tp>
template<class _Yp>
inline
shared_ptr<_Tp>::shared_ptr(const shared_ptr<_Yp>& __r,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type)
throw()
: __ptr_(__r.__ptr_),
__cntrl_(__r.__cntrl_)
{
if (__cntrl_)
__cntrl_->__add_shared();
}
# 4185 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
template<class _Yp>
shared_ptr<_Tp>::shared_ptr(auto_ptr<_Yp> __r,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type)
: __ptr_(__r.get())
{
typedef __shared_ptr_pointer<_Yp*, default_delete<_Yp>, allocator<_Yp> > _CntrlBlk;
__cntrl_ = new _CntrlBlk(__r.get(), default_delete<_Yp>(), allocator<_Yp>());
__enable_weak_this(__r.get(), __r.get());
__r.release();
}
template<class _Tp>
template <class _Yp, class _Dp>
shared_ptr<_Tp>::shared_ptr(unique_ptr<_Yp, _Dp> __r,
typename enable_if
<
!is_lvalue_reference<_Dp>::value &&
!is_array<_Yp>::value &&
is_convertible<typename unique_ptr<_Yp, _Dp>::pointer, element_type*>::value,
__nat
>::type)
: __ptr_(__r.get())
{
{
typedef typename __shared_ptr_default_allocator<_Yp>::type _AllocT;
typedef __shared_ptr_pointer<_Yp*, _Dp, _AllocT > _CntrlBlk;
__cntrl_ = new _CntrlBlk(__r.get(), __r.get_deleter(), _AllocT());
__enable_weak_this(__r.get(), __r.get());
}
__r.release();
}
template<class _Tp>
template <class _Yp, class _Dp>
shared_ptr<_Tp>::shared_ptr(unique_ptr<_Yp, _Dp> __r,
typename enable_if
<
is_lvalue_reference<_Dp>::value &&
!is_array<_Yp>::value &&
is_convertible<typename unique_ptr<_Yp, _Dp>::pointer, element_type*>::value,
__nat
>::type)
: __ptr_(__r.get())
{
{
typedef typename __shared_ptr_default_allocator<_Yp>::type _AllocT;
typedef __shared_ptr_pointer<_Yp*,
reference_wrapper<typename remove_reference<_Dp>::type>,
_AllocT > _CntrlBlk;
__cntrl_ = new _CntrlBlk(__r.get(), ref(__r.get_deleter()), _AllocT());
__enable_weak_this(__r.get(), __r.get());
}
__r.release();
}
# 4307 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
shared_ptr<_Tp>
shared_ptr<_Tp>::make_shared()
{
_Static_assert((is_constructible<_Tp>::value), "Can't construct object in make_shared");
typedef __shared_ptr_emplace<_Tp, allocator<_Tp> > _CntrlBlk;
typedef allocator<_CntrlBlk> _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2;
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(__hold2.get()) _CntrlBlk(__alloc2);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = __hold2.release();
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _A0>
shared_ptr<_Tp>
shared_ptr<_Tp>::make_shared(_A0& __a0)
{
_Static_assert((is_constructible<_Tp, _A0>::value), "Can't construct object in make_shared");
typedef __shared_ptr_emplace<_Tp, allocator<_Tp> > _CntrlBlk;
typedef allocator<_CntrlBlk> _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2;
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(__hold2.get()) _CntrlBlk(__alloc2, __a0);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = __hold2.release();
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _A0, class _A1>
shared_ptr<_Tp>
shared_ptr<_Tp>::make_shared(_A0& __a0, _A1& __a1)
{
_Static_assert((is_constructible<_Tp, _A0, _A1>::value), "Can't construct object in make_shared");
typedef __shared_ptr_emplace<_Tp, allocator<_Tp> > _CntrlBlk;
typedef allocator<_CntrlBlk> _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2;
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(__hold2.get()) _CntrlBlk(__alloc2, __a0, __a1);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = __hold2.release();
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _A0, class _A1, class _A2>
shared_ptr<_Tp>
shared_ptr<_Tp>::make_shared(_A0& __a0, _A1& __a1, _A2& __a2)
{
_Static_assert((is_constructible<_Tp, _A0, _A1, _A2>::value), "Can't construct object in make_shared");
typedef __shared_ptr_emplace<_Tp, allocator<_Tp> > _CntrlBlk;
typedef allocator<_CntrlBlk> _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2;
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(__hold2.get()) _CntrlBlk(__alloc2, __a0, __a1, __a2);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = __hold2.release();
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _Alloc>
shared_ptr<_Tp>
shared_ptr<_Tp>::allocate_shared(const _Alloc& __a)
{
_Static_assert((is_constructible<_Tp>::value), "Can't construct object in allocate_shared");
typedef __shared_ptr_emplace<_Tp, _Alloc> _CntrlBlk;
typedef typename __allocator_traits_rebind<_Alloc, _CntrlBlk>::type _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2(__a);
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(static_cast<void*>(std::__1::addressof(*__hold2.get())))
_CntrlBlk(__a);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = std::__1::addressof(*__hold2.release());
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _Alloc, class _A0>
shared_ptr<_Tp>
shared_ptr<_Tp>::allocate_shared(const _Alloc& __a, _A0& __a0)
{
_Static_assert((is_constructible<_Tp, _A0>::value), "Can't construct object in allocate_shared");
typedef __shared_ptr_emplace<_Tp, _Alloc> _CntrlBlk;
typedef typename __allocator_traits_rebind<_Alloc, _CntrlBlk>::type _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2(__a);
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(static_cast<void*>(std::__1::addressof(*__hold2.get())))
_CntrlBlk(__a, __a0);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = std::__1::addressof(*__hold2.release());
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _Alloc, class _A0, class _A1>
shared_ptr<_Tp>
shared_ptr<_Tp>::allocate_shared(const _Alloc& __a, _A0& __a0, _A1& __a1)
{
_Static_assert((is_constructible<_Tp, _A0, _A1>::value), "Can't construct object in allocate_shared");
typedef __shared_ptr_emplace<_Tp, _Alloc> _CntrlBlk;
typedef typename __allocator_traits_rebind<_Alloc, _CntrlBlk>::type _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2(__a);
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(static_cast<void*>(std::__1::addressof(*__hold2.get())))
_CntrlBlk(__a, __a0, __a1);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = std::__1::addressof(*__hold2.release());
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
template<class _Alloc, class _A0, class _A1, class _A2>
shared_ptr<_Tp>
shared_ptr<_Tp>::allocate_shared(const _Alloc& __a, _A0& __a0, _A1& __a1, _A2& __a2)
{
_Static_assert((is_constructible<_Tp, _A0, _A1, _A2>::value), "Can't construct object in allocate_shared");
typedef __shared_ptr_emplace<_Tp, _Alloc> _CntrlBlk;
typedef typename __allocator_traits_rebind<_Alloc, _CntrlBlk>::type _Alloc2;
typedef __allocator_destructor<_Alloc2> _D2;
_Alloc2 __alloc2(__a);
unique_ptr<_CntrlBlk, _D2> __hold2(__alloc2.allocate(1), _D2(__alloc2, 1));
::new(static_cast<void*>(std::__1::addressof(*__hold2.get())))
_CntrlBlk(__a, __a0, __a1, __a2);
shared_ptr<_Tp> __r;
__r.__ptr_ = __hold2.get()->get();
__r.__cntrl_ = std::__1::addressof(*__hold2.release());
__r.__enable_weak_this(__r.__ptr_, __r.__ptr_);
return __r;
}
template<class _Tp>
shared_ptr<_Tp>::~shared_ptr()
{
if (__cntrl_)
__cntrl_->__release_shared();
}
template<class _Tp>
inline
shared_ptr<_Tp>&
shared_ptr<_Tp>::operator=(const shared_ptr& __r) throw()
{
shared_ptr(__r).swap(*this);
return *this;
}
template<class _Tp>
template<class _Yp>
inline
typename enable_if
<
is_convertible<_Yp*, typename shared_ptr<_Tp>::element_type*>::value,
shared_ptr<_Tp>&
>::type
shared_ptr<_Tp>::operator=(const shared_ptr<_Yp>& __r) throw()
{
shared_ptr(__r).swap(*this);
return *this;
}
# 4555 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
template<class _Yp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
!is_array<_Yp>::value &&
is_convertible<_Yp*, typename shared_ptr<_Tp>::element_type*>::value,
shared_ptr<_Tp>&
>::type
shared_ptr<_Tp>::operator=(auto_ptr<_Yp> __r)
{
shared_ptr(__r).swap(*this);
return *this;
}
template<class _Tp>
template <class _Yp, class _Dp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
!is_array<_Yp>::value &&
is_convertible<typename unique_ptr<_Yp, _Dp>::pointer,
typename shared_ptr<_Tp>::element_type*>::value,
shared_ptr<_Tp>&
>::type
shared_ptr<_Tp>::operator=(unique_ptr<_Yp, _Dp> __r)
{
shared_ptr(std::__1::move(__r)).swap(*this);
return *this;
}
template<class _Tp>
inline
void
shared_ptr<_Tp>::swap(shared_ptr& __r) throw()
{
std::__1::swap(__ptr_, __r.__ptr_);
std::__1::swap(__cntrl_, __r.__cntrl_);
}
template<class _Tp>
inline
void
shared_ptr<_Tp>::reset() throw()
{
shared_ptr().swap(*this);
}
template<class _Tp>
template<class _Yp>
inline
typename enable_if
<
is_convertible<_Yp*, typename shared_ptr<_Tp>::element_type*>::value,
void
>::type
shared_ptr<_Tp>::reset(_Yp* __p)
{
shared_ptr(__p).swap(*this);
}
template<class _Tp>
template<class _Yp, class _Dp>
inline
typename enable_if
<
is_convertible<_Yp*, typename shared_ptr<_Tp>::element_type*>::value,
void
>::type
shared_ptr<_Tp>::reset(_Yp* __p, _Dp __d)
{
shared_ptr(__p, __d).swap(*this);
}
template<class _Tp>
template<class _Yp, class _Dp, class _Alloc>
inline
typename enable_if
<
is_convertible<_Yp*, typename shared_ptr<_Tp>::element_type*>::value,
void
>::type
shared_ptr<_Tp>::reset(_Yp* __p, _Dp __d, _Alloc __a)
{
shared_ptr(__p, __d, __a).swap(*this);
}
# 4673 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
make_shared()
{
return shared_ptr<_Tp>::make_shared();
}
template<class _Tp, class _A0>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
make_shared(_A0& __a0)
{
return shared_ptr<_Tp>::make_shared(__a0);
}
template<class _Tp, class _A0, class _A1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
make_shared(_A0& __a0, _A1& __a1)
{
return shared_ptr<_Tp>::make_shared(__a0, __a1);
}
template<class _Tp, class _A0, class _A1, class _A2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
make_shared(_A0& __a0, _A1& __a1, _A2& __a2)
{
return shared_ptr<_Tp>::make_shared(__a0, __a1, __a2);
}
template<class _Tp, class _Alloc>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
allocate_shared(const _Alloc& __a)
{
return shared_ptr<_Tp>::allocate_shared(__a);
}
template<class _Tp, class _Alloc, class _A0>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
allocate_shared(const _Alloc& __a, _A0& __a0)
{
return shared_ptr<_Tp>::allocate_shared(__a, __a0);
}
template<class _Tp, class _Alloc, class _A0, class _A1>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
allocate_shared(const _Alloc& __a, _A0& __a0, _A1& __a1)
{
return shared_ptr<_Tp>::allocate_shared(__a, __a0, __a1);
}
template<class _Tp, class _Alloc, class _A0, class _A1, class _A2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp>
allocate_shared(const _Alloc& __a, _A0& __a0, _A1& __a1, _A2& __a2)
{
return shared_ptr<_Tp>::allocate_shared(__a, __a0, __a1, __a2);
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const shared_ptr<_Tp>& __x, const shared_ptr<_Up>& __y) throw()
{
return __x.get() == __y.get();
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const shared_ptr<_Tp>& __x, const shared_ptr<_Up>& __y) throw()
{
return !(__x == __y);
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const shared_ptr<_Tp>& __x, const shared_ptr<_Up>& __y) throw()
{
typedef typename common_type<_Tp*, _Up*>::type _Vp;
return less<_Vp>()(__x.get(), __y.get());
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const shared_ptr<_Tp>& __x, const shared_ptr<_Up>& __y) throw()
{
return __y < __x;
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const shared_ptr<_Tp>& __x, const shared_ptr<_Up>& __y) throw()
{
return !(__y < __x);
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const shared_ptr<_Tp>& __x, const shared_ptr<_Up>& __y) throw()
{
return !(__x < __y);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const shared_ptr<_Tp>& __x, nullptr_t) throw()
{
return !__x;
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(nullptr_t, const shared_ptr<_Tp>& __x) throw()
{
return !__x;
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const shared_ptr<_Tp>& __x, nullptr_t) throw()
{
return static_cast<bool>(__x);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(nullptr_t, const shared_ptr<_Tp>& __x) throw()
{
return static_cast<bool>(__x);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const shared_ptr<_Tp>& __x, nullptr_t) throw()
{
return less<_Tp*>()(__x.get(), std::__1::__get_nullptr_t());
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(nullptr_t, const shared_ptr<_Tp>& __x) throw()
{
return less<_Tp*>()(std::__1::__get_nullptr_t(), __x.get());
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const shared_ptr<_Tp>& __x, nullptr_t) throw()
{
return std::__1::__get_nullptr_t() < __x;
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(nullptr_t, const shared_ptr<_Tp>& __x) throw()
{
return __x < std::__1::__get_nullptr_t();
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const shared_ptr<_Tp>& __x, nullptr_t) throw()
{
return !(std::__1::__get_nullptr_t() < __x);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(nullptr_t, const shared_ptr<_Tp>& __x) throw()
{
return !(__x < std::__1::__get_nullptr_t());
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const shared_ptr<_Tp>& __x, nullptr_t) throw()
{
return !(__x < std::__1::__get_nullptr_t());
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(nullptr_t, const shared_ptr<_Tp>& __x) throw()
{
return !(std::__1::__get_nullptr_t() < __x);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(shared_ptr<_Tp>& __x, shared_ptr<_Tp>& __y) throw()
{
__x.swap(__y);
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
!is_array<_Tp>::value && !is_array<_Up>::value,
shared_ptr<_Tp>
>::type
static_pointer_cast(const shared_ptr<_Up>& __r) throw()
{
return shared_ptr<_Tp>(__r, static_cast<_Tp*>(__r.get()));
}
template<class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
!is_array<_Tp>::value && !is_array<_Up>::value,
shared_ptr<_Tp>
>::type
dynamic_pointer_cast(const shared_ptr<_Up>& __r) throw()
{
_Tp* __p = dynamic_cast<_Tp*>(__r.get());
return __p ? shared_ptr<_Tp>(__r, __p) : shared_ptr<_Tp>();
}
template<class _Tp, class _Up>
typename enable_if
<
is_array<_Tp>::value == is_array<_Up>::value,
shared_ptr<_Tp>
>::type
const_pointer_cast(const shared_ptr<_Up>& __r) throw()
{
typedef typename remove_extent<_Tp>::type _RTp;
return shared_ptr<_Tp>(__r, const_cast<_RTp*>(__r.get()));
}
template<class _Dp, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Dp*
get_deleter(const shared_ptr<_Tp>& __p) throw()
{
return __p.template __get_deleter<_Dp>();
}
template<class _Tp>
class __attribute__ ((__type_visibility__("default"))) weak_ptr
{
public:
typedef _Tp element_type;
private:
element_type* __ptr_;
__shared_weak_count* __cntrl_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
weak_ptr() throw();
template<class _Yp> __attribute__ ((__visibility__("hidden"), __always_inline__)) weak_ptr(shared_ptr<_Yp> const& __r,
typename enable_if<is_convertible<_Yp*, _Tp*>::value, __nat*>::type = 0)
throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
weak_ptr(weak_ptr const& __r) throw();
template<class _Yp> __attribute__ ((__visibility__("hidden"), __always_inline__)) weak_ptr(weak_ptr<_Yp> const& __r,
typename enable_if<is_convertible<_Yp*, _Tp*>::value, __nat*>::type = 0)
throw();
# 4969 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
~weak_ptr();
__attribute__ ((__visibility__("hidden"), __always_inline__))
weak_ptr& operator=(weak_ptr const& __r) throw();
template<class _Yp>
typename enable_if
<
is_convertible<_Yp*, element_type*>::value,
weak_ptr&
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator=(weak_ptr<_Yp> const& __r) throw();
# 4997 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Yp>
typename enable_if
<
is_convertible<_Yp*, element_type*>::value,
weak_ptr&
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator=(shared_ptr<_Yp> const& __r) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(weak_ptr& __r) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void reset() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
long use_count() const throw()
{return __cntrl_ ? __cntrl_->use_count() : 0;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool expired() const throw()
{return __cntrl_ == 0 || __cntrl_->use_count() == 0;}
shared_ptr<_Tp> lock() const throw();
template<class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool owner_before(const shared_ptr<_Up>& __r) const throw()
{return __cntrl_ < __r.__cntrl_;}
template<class _Up>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool owner_before(const weak_ptr<_Up>& __r) const throw()
{return __cntrl_ < __r.__cntrl_;}
template <class _Up> friend class __attribute__ ((__type_visibility__("default"))) weak_ptr;
template <class _Up> friend class __attribute__ ((__type_visibility__("default"))) shared_ptr;
};
template<class _Tp>
inline
weak_ptr<_Tp>::weak_ptr() throw()
: __ptr_(0),
__cntrl_(0)
{
}
template<class _Tp>
inline
weak_ptr<_Tp>::weak_ptr(weak_ptr const& __r) throw()
: __ptr_(__r.__ptr_),
__cntrl_(__r.__cntrl_)
{
if (__cntrl_)
__cntrl_->__add_weak();
}
template<class _Tp>
template<class _Yp>
inline
weak_ptr<_Tp>::weak_ptr(shared_ptr<_Yp> const& __r,
typename enable_if<is_convertible<_Yp*, _Tp*>::value, __nat*>::type)
throw()
: __ptr_(__r.__ptr_),
__cntrl_(__r.__cntrl_)
{
if (__cntrl_)
__cntrl_->__add_weak();
}
template<class _Tp>
template<class _Yp>
inline
weak_ptr<_Tp>::weak_ptr(weak_ptr<_Yp> const& __r,
typename enable_if<is_convertible<_Yp*, _Tp*>::value, __nat*>::type)
throw()
: __ptr_(__r.__ptr_),
__cntrl_(__r.__cntrl_)
{
if (__cntrl_)
__cntrl_->__add_weak();
}
# 5103 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
weak_ptr<_Tp>::~weak_ptr()
{
if (__cntrl_)
__cntrl_->__release_weak();
}
template<class _Tp>
inline
weak_ptr<_Tp>&
weak_ptr<_Tp>::operator=(weak_ptr const& __r) throw()
{
weak_ptr(__r).swap(*this);
return *this;
}
template<class _Tp>
template<class _Yp>
inline
typename enable_if
<
is_convertible<_Yp*, _Tp*>::value,
weak_ptr<_Tp>&
>::type
weak_ptr<_Tp>::operator=(weak_ptr<_Yp> const& __r) throw()
{
weak_ptr(__r).swap(*this);
return *this;
}
# 5160 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
template<class _Yp>
inline
typename enable_if
<
is_convertible<_Yp*, _Tp*>::value,
weak_ptr<_Tp>&
>::type
weak_ptr<_Tp>::operator=(shared_ptr<_Yp> const& __r) throw()
{
weak_ptr(__r).swap(*this);
return *this;
}
template<class _Tp>
inline
void
weak_ptr<_Tp>::swap(weak_ptr& __r) throw()
{
std::__1::swap(__ptr_, __r.__ptr_);
std::__1::swap(__cntrl_, __r.__cntrl_);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(weak_ptr<_Tp>& __x, weak_ptr<_Tp>& __y) throw()
{
__x.swap(__y);
}
template<class _Tp>
inline
void
weak_ptr<_Tp>::reset() throw()
{
weak_ptr().swap(*this);
}
template<class _Tp>
template<class _Yp>
shared_ptr<_Tp>::shared_ptr(const weak_ptr<_Yp>& __r,
typename enable_if<is_convertible<_Yp*, element_type*>::value, __nat>::type)
: __ptr_(__r.__ptr_),
__cntrl_(__r.__cntrl_ ? __r.__cntrl_->lock() : __r.__cntrl_)
{
if (__cntrl_ == 0)
__throw_bad_weak_ptr();
}
template<class _Tp>
shared_ptr<_Tp>
weak_ptr<_Tp>::lock() const throw()
{
shared_ptr<_Tp> __r;
__r.__cntrl_ = __cntrl_ ? __cntrl_->lock() : __cntrl_;
if (__r.__cntrl_)
__r.__ptr_ = __ptr_;
return __r;
}
template <class _Tp> struct owner_less;
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) owner_less<shared_ptr<_Tp> >
: binary_function<shared_ptr<_Tp>, shared_ptr<_Tp>, bool>
{
typedef bool result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(shared_ptr<_Tp> const& __x, shared_ptr<_Tp> const& __y) const throw()
{return __x.owner_before(__y);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(shared_ptr<_Tp> const& __x, weak_ptr<_Tp> const& __y) const throw()
{return __x.owner_before(__y);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()( weak_ptr<_Tp> const& __x, shared_ptr<_Tp> const& __y) const throw()
{return __x.owner_before(__y);}
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) owner_less<weak_ptr<_Tp> >
: binary_function<weak_ptr<_Tp>, weak_ptr<_Tp>, bool>
{
typedef bool result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()( weak_ptr<_Tp> const& __x, weak_ptr<_Tp> const& __y) const throw()
{return __x.owner_before(__y);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(shared_ptr<_Tp> const& __x, weak_ptr<_Tp> const& __y) const throw()
{return __x.owner_before(__y);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()( weak_ptr<_Tp> const& __x, shared_ptr<_Tp> const& __y) const throw()
{return __x.owner_before(__y);}
};
# 5283 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template<class _Tp>
class __attribute__ ((__type_visibility__("default"))) enable_shared_from_this
{
mutable weak_ptr<_Tp> __weak_this_;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
enable_shared_from_this() throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
enable_shared_from_this(enable_shared_from_this const&) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
enable_shared_from_this& operator=(enable_shared_from_this const&) throw()
{return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
~enable_shared_from_this() {}
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp> shared_from_this()
{return shared_ptr<_Tp>(__weak_this_);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
shared_ptr<_Tp const> shared_from_this() const
{return shared_ptr<const _Tp>(__weak_this_);}
# 5315 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
template <class _Up> friend class shared_ptr;
};
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) hash<shared_ptr<_Tp> >
{
typedef shared_ptr<_Tp> argument_type;
typedef size_t result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
result_type operator()(const argument_type& __ptr) const throw()
{
return hash<_Tp*>()(__ptr.get());
}
};
template<class _CharT, class _Traits, class _Yp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, shared_ptr<_Yp> const& __p);
class __attribute__ ((__visibility__("default"))) __sp_mut
{
void* __lx;
public:
void lock() throw();
void unlock() throw();
private:
__sp_mut(void*) throw();
__sp_mut(const __sp_mut&);
__sp_mut& operator=(const __sp_mut&);
friend __attribute__ ((__visibility__("default"))) __sp_mut& __get_sp_mut(const void*);
};
__attribute__ ((__visibility__("default"))) __attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
__sp_mut& __get_sp_mut(const void*);
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
atomic_is_lock_free(const shared_ptr<_Tp>*)
{
return false;
}
template <class _Tp>
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
shared_ptr<_Tp>
atomic_load(const shared_ptr<_Tp>* __p)
{
__sp_mut& __m = __get_sp_mut(__p);
__m.lock();
shared_ptr<_Tp> __q = *__p;
__m.unlock();
return __q;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
shared_ptr<_Tp>
atomic_load_explicit(const shared_ptr<_Tp>* __p, memory_order)
{
return atomic_load(__p);
}
template <class _Tp>
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
void
atomic_store(shared_ptr<_Tp>* __p, shared_ptr<_Tp> __r)
{
__sp_mut& __m = __get_sp_mut(__p);
__m.lock();
__p->swap(__r);
__m.unlock();
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
void
atomic_store_explicit(shared_ptr<_Tp>* __p, shared_ptr<_Tp> __r, memory_order)
{
atomic_store(__p, __r);
}
template <class _Tp>
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
shared_ptr<_Tp>
atomic_exchange(shared_ptr<_Tp>* __p, shared_ptr<_Tp> __r)
{
__sp_mut& __m = __get_sp_mut(__p);
__m.lock();
__p->swap(__r);
__m.unlock();
return __r;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
shared_ptr<_Tp>
atomic_exchange_explicit(shared_ptr<_Tp>* __p, shared_ptr<_Tp> __r, memory_order)
{
return atomic_exchange(__p, __r);
}
template <class _Tp>
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
bool
atomic_compare_exchange_strong(shared_ptr<_Tp>* __p, shared_ptr<_Tp>* __v, shared_ptr<_Tp> __w)
{
shared_ptr<_Tp> __temp;
__sp_mut& __m = __get_sp_mut(__p);
__m.lock();
if (__p->__owner_equivalent(*__v))
{
std::__1::swap(__temp, *__p);
*__p = __w;
__m.unlock();
return true;
}
std::__1::swap(__temp, *__v);
*__v = *__p;
__m.unlock();
return false;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
bool
atomic_compare_exchange_weak(shared_ptr<_Tp>* __p, shared_ptr<_Tp>* __v, shared_ptr<_Tp> __w)
{
return atomic_compare_exchange_strong(__p, __v, __w);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
bool
atomic_compare_exchange_strong_explicit(shared_ptr<_Tp>* __p, shared_ptr<_Tp>* __v,
shared_ptr<_Tp> __w, memory_order, memory_order)
{
return atomic_compare_exchange_strong(__p, __v, __w);
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
bool
atomic_compare_exchange_weak_explicit(shared_ptr<_Tp>* __p, shared_ptr<_Tp>* __v,
shared_ptr<_Tp> __w, memory_order, memory_order)
{
return atomic_compare_exchange_weak(__p, __v, __w);
}
# 5489 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
struct __attribute__ ((__visibility__("default"))) pointer_safety
{
enum __lx
{
relaxed,
preferred,
strict
};
__lx __v_;
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer_safety() : __v_() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer_safety(__lx __v) : __v_(__v) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator int() const {return __v_;}
};
# 5516 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pointer_safety get_pointer_safety() throw() {
return pointer_safety::relaxed;
}
__attribute__ ((__visibility__("default"))) void declare_reachable(void* __p);
__attribute__ ((__visibility__("default"))) void declare_no_pointers(char* __p, size_t __n);
__attribute__ ((__visibility__("default"))) void undeclare_no_pointers(char* __p, size_t __n);
__attribute__ ((__visibility__("default"))) void* __undeclare_reachable(void* __p);
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp*
undeclare_reachable(_Tp* __p)
{
return static_cast<_Tp*>(__undeclare_reachable(__p));
}
__attribute__ ((__visibility__("default"))) void* align(size_t __align, size_t __sz, void*& __ptr, size_t& __space);
template <typename _Alloc>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __swap_allocator(_Alloc & __a1, _Alloc & __a2)
{
__swap_allocator(__a1, __a2,
integral_constant<bool, std::__1::allocator_traits<_Alloc>::propagate_on_container_swap::value>());
}
template <typename _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __swap_allocator(_Alloc & __a1, _Alloc & __a2, true_type)
{
using std::__1::swap;
swap(__a1, __a2);
}
template <typename _Alloc>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __swap_allocator(_Alloc &, _Alloc &, false_type) throw() {}
template <typename _Alloc, typename _Traits=allocator_traits<_Alloc> >
struct __noexcept_move_assign_container : public integral_constant<bool,
_Traits::propagate_on_container_move_assignment::value
&& is_nothrow_move_assignable<_Alloc>::value
> {};
# 5600 "/Library/Developer/CommandLineTools/usr/include/c++/v1/memory" 3
} }
# 644 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 2 3
# 658 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 662 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 2 3
namespace std {inline namespace __1 {
template <class _T1, class _T2 = _T1>
struct __equal_to
{
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator()(const _T1& __x, const _T2& __y) const {return __x == __y;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator()(const _T2& __x, const _T1& __y) const {return __x == __y;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator()(const _T2& __x, const _T2& __y) const {return __x == __y;}
};
template <class _T1>
struct __equal_to<_T1, _T1>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;}
};
template <class _T1>
struct __equal_to<const _T1, _T1>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;}
};
template <class _T1>
struct __equal_to<_T1, const _T1>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;}
};
template <class _T1, class _T2 = _T1>
struct __less
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T2& __y) const {return __x < __y;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T2& __x, const _T1& __y) const {return __x < __y;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T2& __x, const _T2& __y) const {return __x < __y;}
};
template <class _T1>
struct __less<_T1, _T1>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;}
};
template <class _T1>
struct __less<const _T1, _T1>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;}
};
template <class _T1>
struct __less<_T1, const _T1>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;}
};
template <class _Predicate>
class __invert
{
private:
_Predicate __p_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __invert() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __invert(_Predicate __p) : __p_(__p) {}
template <class _T1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x) {return !__p_(__x);}
template <class _T1, class _T2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _T1& __x, const _T2& __y) {return __p_(__y, __x);}
};
# 790 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned __ctz(unsigned __x) {
return static_cast<unsigned>(__builtin_ctz(__x));
# 804 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long __ctz(unsigned long __x) {
return static_cast<unsigned long>(__builtin_ctzl(__x));
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long __ctz(unsigned long long __x) {
return static_cast<unsigned long long>(__builtin_ctzll(__x));
# 839 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned __clz(unsigned __x) {
return static_cast<unsigned>(__builtin_clz(__x));
# 856 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long __clz(unsigned long __x) {
return static_cast<unsigned long>(__builtin_clzl (__x));
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long __clz(unsigned long long __x) {
return static_cast<unsigned long long>(__builtin_clzll(__x));
# 889 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) int __pop_count(unsigned __x) {
return __builtin_popcount (__x);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) int __pop_count(unsigned long __x) {
return __builtin_popcountl (__x);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__)) int __pop_count(unsigned long long __x) {
return __builtin_popcountll(__x);
}
template <class _InputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
all_of(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
for (; __first != __last; ++__first)
if (!__pred(*__first))
return false;
return true;
}
template <class _InputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
any_of(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
for (; __first != __last; ++__first)
if (__pred(*__first))
return true;
return false;
}
template <class _InputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
none_of(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
for (; __first != __last; ++__first)
if (__pred(*__first))
return false;
return true;
}
template <class _InputIterator, class _Function>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Function
for_each(_InputIterator __first, _InputIterator __last, _Function __f)
{
for (; __first != __last; ++__first)
__f(*__first);
return __f;
}
# 991 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <class _InputIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_InputIterator
find(_InputIterator __first, _InputIterator __last, const _Tp& __value_)
{
for (; __first != __last; ++__first)
if (*__first == __value_)
break;
return __first;
}
template <class _InputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_InputIterator
find_if(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
for (; __first != __last; ++__first)
if (__pred(*__first))
break;
return __first;
}
template<class _InputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_InputIterator
find_if_not(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
for (; __first != __last; ++__first)
if (!__pred(*__first))
break;
return __first;
}
template <class _BinaryPredicate, class _ForwardIterator1, class _ForwardIterator2>
_ForwardIterator1
__find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred,
forward_iterator_tag, forward_iterator_tag)
{
_ForwardIterator1 __r = __last1;
if (__first2 == __last2)
return __r;
while (true)
{
while (true)
{
if (__first1 == __last1)
return __r;
if (__pred(*__first1, *__first2))
break;
++__first1;
}
_ForwardIterator1 __m1 = __first1;
_ForwardIterator2 __m2 = __first2;
while (true)
{
if (++__m2 == __last2)
{
__r = __first1;
++__first1;
break;
}
if (++__m1 == __last1)
return __r;
if (!__pred(*__m1, *__m2))
{
++__first1;
break;
}
}
}
}
template <class _BinaryPredicate, class _BidirectionalIterator1, class _BidirectionalIterator2>
_BidirectionalIterator1
__find_end(_BidirectionalIterator1 __first1, _BidirectionalIterator1 __last1,
_BidirectionalIterator2 __first2, _BidirectionalIterator2 __last2, _BinaryPredicate __pred,
bidirectional_iterator_tag, bidirectional_iterator_tag)
{
if (__first2 == __last2)
return __last1;
_BidirectionalIterator1 __l1 = __last1;
_BidirectionalIterator2 __l2 = __last2;
--__l2;
while (true)
{
while (true)
{
if (__first1 == __l1)
return __last1;
if (__pred(*--__l1, *__l2))
break;
}
_BidirectionalIterator1 __m1 = __l1;
_BidirectionalIterator2 __m2 = __l2;
while (true)
{
if (__m2 == __first2)
return __m1;
if (__m1 == __first1)
return __last1;
if (!__pred(*--__m1, *--__m2))
{
break;
}
}
}
}
template <class _BinaryPredicate, class _RandomAccessIterator1, class _RandomAccessIterator2>
_RandomAccessIterator1
__find_end(_RandomAccessIterator1 __first1, _RandomAccessIterator1 __last1,
_RandomAccessIterator2 __first2, _RandomAccessIterator2 __last2, _BinaryPredicate __pred,
random_access_iterator_tag, random_access_iterator_tag)
{
typename iterator_traits<_RandomAccessIterator2>::difference_type __len2 = __last2 - __first2;
if (__len2 == 0)
return __last1;
typename iterator_traits<_RandomAccessIterator1>::difference_type __len1 = __last1 - __first1;
if (__len1 < __len2)
return __last1;
const _RandomAccessIterator1 __s = __first1 + (__len2 - 1);
_RandomAccessIterator1 __l1 = __last1;
_RandomAccessIterator2 __l2 = __last2;
--__l2;
while (true)
{
while (true)
{
if (__s == __l1)
return __last1;
if (__pred(*--__l1, *__l2))
break;
}
_RandomAccessIterator1 __m1 = __l1;
_RandomAccessIterator2 __m2 = __l2;
while (true)
{
if (__m2 == __first2)
return __m1;
if (!__pred(*--__m1, *--__m2))
{
break;
}
}
}
}
template <class _ForwardIterator1, class _ForwardIterator2, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator1
find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred)
{
return std::__1::__find_end<typename add_lvalue_reference<_BinaryPredicate>::type>
(__first1, __last1, __first2, __last2, __pred,
typename iterator_traits<_ForwardIterator1>::iterator_category(),
typename iterator_traits<_ForwardIterator2>::iterator_category());
}
template <class _ForwardIterator1, class _ForwardIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator1
find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2)
{
typedef typename iterator_traits<_ForwardIterator1>::value_type __v1;
typedef typename iterator_traits<_ForwardIterator2>::value_type __v2;
return std::__1::find_end(__first1, __last1, __first2, __last2, __equal_to<__v1, __v2>());
}
template <class _ForwardIterator1, class _ForwardIterator2, class _BinaryPredicate>
_ForwardIterator1
__find_first_of_ce(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred)
{
for (; __first1 != __last1; ++__first1)
for (_ForwardIterator2 __j = __first2; __j != __last2; ++__j)
if (__pred(*__first1, *__j))
return __first1;
return __last1;
}
template <class _ForwardIterator1, class _ForwardIterator2, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator1
find_first_of(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred)
{
return std::__1::__find_first_of_ce(__first1, __last1, __first2, __last2, __pred);
}
template <class _ForwardIterator1, class _ForwardIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator1
find_first_of(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2)
{
typedef typename iterator_traits<_ForwardIterator1>::value_type __v1;
typedef typename iterator_traits<_ForwardIterator2>::value_type __v2;
return std::__1::__find_first_of_ce(__first1, __last1, __first2, __last2, __equal_to<__v1, __v2>());
}
template <class _ForwardIterator, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
adjacent_find(_ForwardIterator __first, _ForwardIterator __last, _BinaryPredicate __pred)
{
if (__first != __last)
{
_ForwardIterator __i = __first;
while (++__i != __last)
{
if (__pred(*__first, *__i))
return __first;
__first = __i;
}
}
return __last;
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
adjacent_find(_ForwardIterator __first, _ForwardIterator __last)
{
typedef typename iterator_traits<_ForwardIterator>::value_type __v;
return std::__1::adjacent_find(__first, __last, __equal_to<__v>());
}
template <class _InputIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename iterator_traits<_InputIterator>::difference_type
count(_InputIterator __first, _InputIterator __last, const _Tp& __value_)
{
typename iterator_traits<_InputIterator>::difference_type __r(0);
for (; __first != __last; ++__first)
if (*__first == __value_)
++__r;
return __r;
}
template <class _InputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename iterator_traits<_InputIterator>::difference_type
count_if(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
typename iterator_traits<_InputIterator>::difference_type __r(0);
for (; __first != __last; ++__first)
if (__pred(*__first))
++__r;
return __r;
}
template <class _InputIterator1, class _InputIterator2, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<_InputIterator1, _InputIterator2>
mismatch(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _BinaryPredicate __pred)
{
for (; __first1 != __last1; ++__first1, (void) ++__first2)
if (!__pred(*__first1, *__first2))
break;
return pair<_InputIterator1, _InputIterator2>(__first1, __first2);
}
template <class _InputIterator1, class _InputIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<_InputIterator1, _InputIterator2>
mismatch(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2)
{
typedef typename iterator_traits<_InputIterator1>::value_type __v1;
typedef typename iterator_traits<_InputIterator2>::value_type __v2;
return std::__1::mismatch(__first1, __last1, __first2, __equal_to<__v1, __v2>());
}
# 1319 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <class _InputIterator1, class _InputIterator2, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
equal(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _BinaryPredicate __pred)
{
for (; __first1 != __last1; ++__first1, (void) ++__first2)
if (!__pred(*__first1, *__first2))
return false;
return true;
}
template <class _InputIterator1, class _InputIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
equal(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2)
{
typedef typename iterator_traits<_InputIterator1>::value_type __v1;
typedef typename iterator_traits<_InputIterator2>::value_type __v2;
return std::__1::equal(__first1, __last1, __first2, __equal_to<__v1, __v2>());
}
# 1396 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template<class _ForwardIterator1, class _ForwardIterator2, class _BinaryPredicate>
bool
is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _BinaryPredicate __pred)
{
for (; __first1 != __last1; ++__first1, (void) ++__first2)
if (!__pred(*__first1, *__first2))
goto __not_done;
return true;
__not_done:
typedef typename iterator_traits<_ForwardIterator1>::difference_type _D1;
_D1 __l1 = std::__1::distance(__first1, __last1);
if (__l1 == _D1(1))
return false;
_ForwardIterator2 __last2 = std::__1::next(__first2, __l1);
for (_ForwardIterator1 __i = __first1; __i != __last1; ++__i)
{
for (_ForwardIterator1 __j = __first1; __j != __i; ++__j)
if (__pred(*__j, *__i))
goto __next_iter;
{
_D1 __c2 = 0;
for (_ForwardIterator2 __j = __first2; __j != __last2; ++__j)
if (__pred(*__i, *__j))
++__c2;
if (__c2 == 0)
return false;
_D1 __c1 = 1;
for (_ForwardIterator1 __j = std::__1::next(__i); __j != __last1; ++__j)
if (__pred(*__i, *__j))
++__c1;
if (__c1 != __c2)
return false;
}
__next_iter:;
}
return true;
}
template<class _ForwardIterator1, class _ForwardIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2)
{
typedef typename iterator_traits<_ForwardIterator1>::value_type __v1;
typedef typename iterator_traits<_ForwardIterator2>::value_type __v2;
return std::__1::is_permutation(__first1, __last1, __first2, __equal_to<__v1, __v2>());
}
# 1549 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <class _BinaryPredicate, class _ForwardIterator1, class _ForwardIterator2>
pair<_ForwardIterator1, _ForwardIterator1>
__search(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred,
forward_iterator_tag, forward_iterator_tag)
{
if (__first2 == __last2)
return make_pair(__first1, __first1);
while (true)
{
while (true)
{
if (__first1 == __last1)
return make_pair(__last1, __last1);
if (__pred(*__first1, *__first2))
break;
++__first1;
}
_ForwardIterator1 __m1 = __first1;
_ForwardIterator2 __m2 = __first2;
while (true)
{
if (++__m2 == __last2)
return make_pair(__first1, __m1);
if (++__m1 == __last1)
return make_pair(__last1, __last1);
if (!__pred(*__m1, *__m2))
{
++__first1;
break;
}
}
}
}
template <class _BinaryPredicate, class _RandomAccessIterator1, class _RandomAccessIterator2>
pair<_RandomAccessIterator1, _RandomAccessIterator1>
__search(_RandomAccessIterator1 __first1, _RandomAccessIterator1 __last1,
_RandomAccessIterator2 __first2, _RandomAccessIterator2 __last2, _BinaryPredicate __pred,
random_access_iterator_tag, random_access_iterator_tag)
{
typedef typename iterator_traits<_RandomAccessIterator1>::difference_type _D1;
typedef typename iterator_traits<_RandomAccessIterator2>::difference_type _D2;
const _D2 __len2 = __last2 - __first2;
if (__len2 == 0)
return make_pair(__first1, __first1);
const _D1 __len1 = __last1 - __first1;
if (__len1 < __len2)
return make_pair(__last1, __last1);
const _RandomAccessIterator1 __s = __last1 - (__len2 - 1);
while (true)
{
while (true)
{
if (__first1 == __s)
return make_pair(__last1, __last1);
if (__pred(*__first1, *__first2))
break;
++__first1;
}
_RandomAccessIterator1 __m1 = __first1;
_RandomAccessIterator2 __m2 = __first2;
while (true)
{
if (++__m2 == __last2)
return make_pair(__first1, __first1 + __len2);
++__m1;
if (!__pred(*__m1, *__m2))
{
++__first1;
break;
}
}
}
}
template <class _ForwardIterator1, class _ForwardIterator2, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator1
search(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred)
{
return std::__1::__search<typename add_lvalue_reference<_BinaryPredicate>::type>
(__first1, __last1, __first2, __last2, __pred,
typename iterator_traits<_ForwardIterator1>::iterator_category(),
typename iterator_traits<_ForwardIterator2>::iterator_category())
.first;
}
template <class _ForwardIterator1, class _ForwardIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator1
search(_ForwardIterator1 __first1, _ForwardIterator1 __last1,
_ForwardIterator2 __first2, _ForwardIterator2 __last2)
{
typedef typename iterator_traits<_ForwardIterator1>::value_type __v1;
typedef typename iterator_traits<_ForwardIterator2>::value_type __v2;
return std::__1::search(__first1, __last1, __first2, __last2, __equal_to<__v1, __v2>());
}
template <class _BinaryPredicate, class _ForwardIterator, class _Size, class _Tp>
_ForwardIterator
__search_n(_ForwardIterator __first, _ForwardIterator __last,
_Size __count, const _Tp& __value_, _BinaryPredicate __pred, forward_iterator_tag)
{
if (__count <= 0)
return __first;
while (true)
{
while (true)
{
if (__first == __last)
return __last;
if (__pred(*__first, __value_))
break;
++__first;
}
_ForwardIterator __m = __first;
_Size __c(0);
while (true)
{
if (++__c == __count)
return __first;
if (++__m == __last)
return __last;
if (!__pred(*__m, __value_))
{
__first = __m;
++__first;
break;
}
}
}
}
template <class _BinaryPredicate, class _RandomAccessIterator, class _Size, class _Tp>
_RandomAccessIterator
__search_n(_RandomAccessIterator __first, _RandomAccessIterator __last,
_Size __count, const _Tp& __value_, _BinaryPredicate __pred, random_access_iterator_tag)
{
if (__count <= 0)
return __first;
_Size __len = static_cast<_Size>(__last - __first);
if (__len < __count)
return __last;
const _RandomAccessIterator __s = __last - (__count - 1);
while (true)
{
while (true)
{
if (__first >= __s)
return __last;
if (__pred(*__first, __value_))
break;
++__first;
}
_RandomAccessIterator __m = __first;
_Size __c(0);
while (true)
{
if (++__c == __count)
return __first;
++__m;
if (!__pred(*__m, __value_))
{
__first = __m;
++__first;
break;
}
}
}
}
template <class _ForwardIterator, class _Size, class _Tp, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
search_n(_ForwardIterator __first, _ForwardIterator __last,
_Size __count, const _Tp& __value_, _BinaryPredicate __pred)
{
return std::__1::__search_n<typename add_lvalue_reference<_BinaryPredicate>::type>
(__first, __last, __convert_to_integral(__count), __value_, __pred,
typename iterator_traits<_ForwardIterator>::iterator_category());
}
template <class _ForwardIterator, class _Size, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
search_n(_ForwardIterator __first, _ForwardIterator __last, _Size __count, const _Tp& __value_)
{
typedef typename iterator_traits<_ForwardIterator>::value_type __v;
return std::__1::search_n(__first, __last, __convert_to_integral(__count),
__value_, __equal_to<__v, _Tp>());
}
template <class _Iter>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Iter
__unwrap_iter(_Iter __i)
{
return __i;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
_Tp*
>::type
__unwrap_iter(move_iterator<_Tp*> __i)
{
return __i.base();
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_trivially_copy_assignable<_Tp>::value,
_Tp*
>::type
__unwrap_iter(__wrap_iter<_Tp*> __i)
{
return __i.base();
}
# 1806 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <class _InputIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
__copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
{
for (; __first != __last; ++__first, (void) ++__result)
*__result = *__first;
return __result;
}
template <class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_same<typename remove_const<_Tp>::type, _Up>::value &&
is_trivially_copy_assignable<_Up>::value,
_Up*
>::type
__copy(_Tp* __first, _Tp* __last, _Up* __result)
{
const size_t __n = static_cast<size_t>(__last - __first);
if (__n > 0)
std::__1::memmove(__result, __first, __n * sizeof(_Up));
return __result + __n;
}
template <class _InputIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
{
return std::__1::__copy(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result));
}
template <class _BidirectionalIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
__copy_backward(_BidirectionalIterator __first, _BidirectionalIterator __last, _OutputIterator __result)
{
while (__first != __last)
*--__result = *--__last;
return __result;
}
template <class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_same<typename remove_const<_Tp>::type, _Up>::value &&
is_trivially_copy_assignable<_Up>::value,
_Up*
>::type
__copy_backward(_Tp* __first, _Tp* __last, _Up* __result)
{
const size_t __n = static_cast<size_t>(__last - __first);
if (__n > 0)
{
__result -= __n;
std::__1::memmove(__result, __first, __n * sizeof(_Up));
}
return __result;
}
template <class _BidirectionalIterator1, class _BidirectionalIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_BidirectionalIterator2
copy_backward(_BidirectionalIterator1 __first, _BidirectionalIterator1 __last,
_BidirectionalIterator2 __result)
{
return std::__1::__copy_backward(__unwrap_iter(__first),
__unwrap_iter(__last),
__unwrap_iter(__result));
}
template<class _InputIterator, class _OutputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
copy_if(_InputIterator __first, _InputIterator __last,
_OutputIterator __result, _Predicate __pred)
{
for (; __first != __last; ++__first)
{
if (__pred(*__first))
{
*__result = *__first;
++__result;
}
}
return __result;
}
template<class _InputIterator, class _Size, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__is_input_iterator<_InputIterator>::value &&
!__is_random_access_iterator<_InputIterator>::value,
_OutputIterator
>::type
copy_n(_InputIterator __first, _Size __orig_n, _OutputIterator __result)
{
typedef __decltype(__convert_to_integral(__orig_n)) _IntegralSize;
_IntegralSize __n = __orig_n;
if (__n > 0)
{
*__result = *__first;
++__result;
for (--__n; __n > 0; --__n)
{
++__first;
*__result = *__first;
++__result;
}
}
return __result;
}
template<class _InputIterator, class _Size, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__is_random_access_iterator<_InputIterator>::value,
_OutputIterator
>::type
copy_n(_InputIterator __first, _Size __orig_n, _OutputIterator __result)
{
typedef __decltype(__convert_to_integral(__orig_n)) _IntegralSize;
_IntegralSize __n = __orig_n;
return std::__1::copy(__first, __first + __n, __result);
}
template <class _InputIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
__move(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
{
for (; __first != __last; ++__first, (void) ++__result)
*__result = std::__1::move(*__first);
return __result;
}
template <class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_same<typename remove_const<_Tp>::type, _Up>::value &&
is_trivially_copy_assignable<_Up>::value,
_Up*
>::type
__move(_Tp* __first, _Tp* __last, _Up* __result)
{
const size_t __n = static_cast<size_t>(__last - __first);
if (__n > 0)
std::__1::memmove(__result, __first, __n * sizeof(_Up));
return __result + __n;
}
template <class _InputIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
move(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
{
return std::__1::__move(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result));
}
template <class _InputIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
__move_backward(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
{
while (__first != __last)
*--__result = std::__1::move(*--__last);
return __result;
}
template <class _Tp, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_same<typename remove_const<_Tp>::type, _Up>::value &&
is_trivially_copy_assignable<_Up>::value,
_Up*
>::type
__move_backward(_Tp* __first, _Tp* __last, _Up* __result)
{
const size_t __n = static_cast<size_t>(__last - __first);
if (__n > 0)
{
__result -= __n;
std::__1::memmove(__result, __first, __n * sizeof(_Up));
}
return __result;
}
template <class _BidirectionalIterator1, class _BidirectionalIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_BidirectionalIterator2
move_backward(_BidirectionalIterator1 __first, _BidirectionalIterator1 __last,
_BidirectionalIterator2 __result)
{
return std::__1::__move_backward(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result));
}
template <class _InputIterator, class _OutputIterator, class _UnaryOperation>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
transform(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _UnaryOperation __op)
{
for (; __first != __last; ++__first, (void) ++__result)
*__result = __op(*__first);
return __result;
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator, class _BinaryOperation>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
transform(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2,
_OutputIterator __result, _BinaryOperation __binary_op)
{
for (; __first1 != __last1; ++__first1, (void) ++__first2, ++__result)
*__result = __binary_op(*__first1, *__first2);
return __result;
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
replace(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __old_value, const _Tp& __new_value)
{
for (; __first != __last; ++__first)
if (*__first == __old_value)
*__first = __new_value;
}
template <class _ForwardIterator, class _Predicate, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
replace_if(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred, const _Tp& __new_value)
{
for (; __first != __last; ++__first)
if (__pred(*__first))
*__first = __new_value;
}
template <class _InputIterator, class _OutputIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
replace_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result,
const _Tp& __old_value, const _Tp& __new_value)
{
for (; __first != __last; ++__first, (void) ++__result)
if (*__first == __old_value)
*__result = __new_value;
else
*__result = *__first;
return __result;
}
template <class _InputIterator, class _OutputIterator, class _Predicate, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
replace_copy_if(_InputIterator __first, _InputIterator __last, _OutputIterator __result,
_Predicate __pred, const _Tp& __new_value)
{
for (; __first != __last; ++__first, (void) ++__result)
if (__pred(*__first))
*__result = __new_value;
else
*__result = *__first;
return __result;
}
template <class _OutputIterator, class _Size, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
__fill_n(_OutputIterator __first, _Size __n, const _Tp& __value_)
{
for (; __n > 0; ++__first, (void) --__n)
*__first = __value_;
return __first;
}
template <class _Tp, class _Size, class _Up>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_integral<_Tp>::value && sizeof(_Tp) == 1 &&
!is_same<_Tp, bool>::value &&
is_integral<_Up>::value && sizeof(_Up) == 1,
_Tp*
>::type
__fill_n(_Tp* __first, _Size __n,_Up __value_)
{
if (__n > 0)
std::__1::memset(__first, (unsigned char)__value_, (size_t)(__n));
return __first + __n;
}
template <class _OutputIterator, class _Size, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
fill_n(_OutputIterator __first, _Size __n, const _Tp& __value_)
{
return std::__1::__fill_n(__first, __convert_to_integral(__n), __value_);
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
__fill(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, forward_iterator_tag)
{
for (; __first != __last; ++__first)
*__first = __value_;
}
template <class _RandomAccessIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
__fill(_RandomAccessIterator __first, _RandomAccessIterator __last, const _Tp& __value_, random_access_iterator_tag)
{
std::__1::fill_n(__first, __last - __first, __value_);
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
fill(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_)
{
std::__1::__fill(__first, __last, __value_, typename iterator_traits<_ForwardIterator>::iterator_category());
}
template <class _ForwardIterator, class _Generator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
generate(_ForwardIterator __first, _ForwardIterator __last, _Generator __gen)
{
for (; __first != __last; ++__first)
*__first = __gen();
}
template <class _OutputIterator, class _Size, class _Generator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
generate_n(_OutputIterator __first, _Size __orig_n, _Generator __gen)
{
typedef __decltype(__convert_to_integral(__orig_n)) _IntegralSize;
_IntegralSize __n = __orig_n;
for (; __n > 0; ++__first, (void) --__n)
*__first = __gen();
return __first;
}
template <class _ForwardIterator, class _Tp>
_ForwardIterator
remove(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_)
{
__first = std::__1::find(__first, __last, __value_);
if (__first != __last)
{
_ForwardIterator __i = __first;
while (++__i != __last)
{
if (!(*__i == __value_))
{
*__first = std::__1::move(*__i);
++__first;
}
}
}
return __first;
}
template <class _ForwardIterator, class _Predicate>
_ForwardIterator
remove_if(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred)
{
__first = std::__1::find_if<_ForwardIterator, typename add_lvalue_reference<_Predicate>::type>
(__first, __last, __pred);
if (__first != __last)
{
_ForwardIterator __i = __first;
while (++__i != __last)
{
if (!__pred(*__i))
{
*__first = std::__1::move(*__i);
++__first;
}
}
}
return __first;
}
template <class _InputIterator, class _OutputIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
remove_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, const _Tp& __value_)
{
for (; __first != __last; ++__first)
{
if (!(*__first == __value_))
{
*__result = *__first;
++__result;
}
}
return __result;
}
template <class _InputIterator, class _OutputIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
remove_copy_if(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _Predicate __pred)
{
for (; __first != __last; ++__first)
{
if (!__pred(*__first))
{
*__result = *__first;
++__result;
}
}
return __result;
}
template <class _ForwardIterator, class _BinaryPredicate>
_ForwardIterator
unique(_ForwardIterator __first, _ForwardIterator __last, _BinaryPredicate __pred)
{
__first = std::__1::adjacent_find<_ForwardIterator, typename add_lvalue_reference<_BinaryPredicate>::type>
(__first, __last, __pred);
if (__first != __last)
{
_ForwardIterator __i = __first;
for (++__i; ++__i != __last;)
if (!__pred(*__first, *__i))
*++__first = std::__1::move(*__i);
++__first;
}
return __first;
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
unique(_ForwardIterator __first, _ForwardIterator __last)
{
typedef typename iterator_traits<_ForwardIterator>::value_type __v;
return std::__1::unique(__first, __last, __equal_to<__v>());
}
template <class _BinaryPredicate, class _InputIterator, class _OutputIterator>
_OutputIterator
__unique_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _BinaryPredicate __pred,
input_iterator_tag, output_iterator_tag)
{
if (__first != __last)
{
typename iterator_traits<_InputIterator>::value_type __t(*__first);
*__result = __t;
++__result;
while (++__first != __last)
{
if (!__pred(__t, *__first))
{
__t = *__first;
*__result = __t;
++__result;
}
}
}
return __result;
}
template <class _BinaryPredicate, class _ForwardIterator, class _OutputIterator>
_OutputIterator
__unique_copy(_ForwardIterator __first, _ForwardIterator __last, _OutputIterator __result, _BinaryPredicate __pred,
forward_iterator_tag, output_iterator_tag)
{
if (__first != __last)
{
_ForwardIterator __i = __first;
*__result = *__i;
++__result;
while (++__first != __last)
{
if (!__pred(*__i, *__first))
{
*__result = *__first;
++__result;
__i = __first;
}
}
}
return __result;
}
template <class _BinaryPredicate, class _InputIterator, class _ForwardIterator>
_ForwardIterator
__unique_copy(_InputIterator __first, _InputIterator __last, _ForwardIterator __result, _BinaryPredicate __pred,
input_iterator_tag, forward_iterator_tag)
{
if (__first != __last)
{
*__result = *__first;
while (++__first != __last)
if (!__pred(*__result, *__first))
*++__result = *__first;
++__result;
}
return __result;
}
template <class _InputIterator, class _OutputIterator, class _BinaryPredicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
unique_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _BinaryPredicate __pred)
{
return std::__1::__unique_copy<typename add_lvalue_reference<_BinaryPredicate>::type>
(__first, __last, __result, __pred,
typename iterator_traits<_InputIterator>::iterator_category(),
typename iterator_traits<_OutputIterator>::iterator_category());
}
template <class _InputIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
unique_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
{
typedef typename iterator_traits<_InputIterator>::value_type __v;
return std::__1::unique_copy(__first, __last, __result, __equal_to<__v>());
}
template <class _BidirectionalIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
__reverse(_BidirectionalIterator __first, _BidirectionalIterator __last, bidirectional_iterator_tag)
{
while (__first != __last)
{
if (__first == --__last)
break;
std::__1::iter_swap(__first, __last);
++__first;
}
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
__reverse(_RandomAccessIterator __first, _RandomAccessIterator __last, random_access_iterator_tag)
{
if (__first != __last)
for (; __first < --__last; ++__first)
std::__1::iter_swap(__first, __last);
}
template <class _BidirectionalIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
reverse(_BidirectionalIterator __first, _BidirectionalIterator __last)
{
std::__1::__reverse(__first, __last, typename iterator_traits<_BidirectionalIterator>::iterator_category());
}
template <class _BidirectionalIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
reverse_copy(_BidirectionalIterator __first, _BidirectionalIterator __last, _OutputIterator __result)
{
for (; __first != __last; ++__result)
*__result = *--__last;
return __result;
}
template <class _ForwardIterator>
_ForwardIterator
__rotate_left(_ForwardIterator __first, _ForwardIterator __last)
{
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
value_type __tmp = std::__1::move(*__first);
_ForwardIterator __lm1 = std::__1::move(std::__1::next(__first), __last, __first);
*__lm1 = std::__1::move(__tmp);
return __lm1;
}
template <class _BidirectionalIterator>
_BidirectionalIterator
__rotate_right(_BidirectionalIterator __first, _BidirectionalIterator __last)
{
typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type;
_BidirectionalIterator __lm1 = std::__1::prev(__last);
value_type __tmp = std::__1::move(*__lm1);
_BidirectionalIterator __fp1 = std::__1::move_backward(__first, __lm1, __last);
*__first = std::__1::move(__tmp);
return __fp1;
}
template <class _ForwardIterator>
_ForwardIterator
__rotate_forward(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last)
{
_ForwardIterator __i = __middle;
while (true)
{
swap(*__first, *__i);
++__first;
if (++__i == __last)
break;
if (__first == __middle)
__middle = __i;
}
_ForwardIterator __r = __first;
if (__first != __middle)
{
__i = __middle;
while (true)
{
swap(*__first, *__i);
++__first;
if (++__i == __last)
{
if (__first == __middle)
break;
__i = __middle;
}
else if (__first == __middle)
__middle = __i;
}
}
return __r;
}
template<typename _Integral>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_Integral
__algo_gcd(_Integral __x, _Integral __y)
{
do
{
_Integral __t = __x % __y;
__x = __y;
__y = __t;
} while (__y);
return __x;
}
template<typename _RandomAccessIterator>
_RandomAccessIterator
__rotate_gcd(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
const difference_type __m1 = __middle - __first;
const difference_type __m2 = __last - __middle;
if (__m1 == __m2)
{
std::__1::swap_ranges(__first, __middle, __middle);
return __middle;
}
const difference_type __g = std::__1::__algo_gcd(__m1, __m2);
for (_RandomAccessIterator __p = __first + __g; __p != __first;)
{
value_type __t(std::__1::move(*--__p));
_RandomAccessIterator __p1 = __p;
_RandomAccessIterator __p2 = __p1 + __m1;
do
{
*__p1 = std::__1::move(*__p2);
__p1 = __p2;
const difference_type __d = __last - __p2;
if (__m1 < __d)
__p2 += __m1;
else
__p2 = __first + (__m1 - __d);
} while (__p2 != __p);
*__p1 = std::__1::move(__t);
}
return __first + __m2;
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
__rotate(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last,
std::__1::forward_iterator_tag)
{
typedef typename std::__1::iterator_traits<_ForwardIterator>::value_type value_type;
if (std::__1::is_trivially_move_assignable<value_type>::value)
{
if (std::__1::next(__first) == __middle)
return std::__1::__rotate_left(__first, __last);
}
return std::__1::__rotate_forward(__first, __middle, __last);
}
template <class _BidirectionalIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_BidirectionalIterator
__rotate(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last,
std::__1::bidirectional_iterator_tag)
{
typedef typename std::__1::iterator_traits<_BidirectionalIterator>::value_type value_type;
if (std::__1::is_trivially_move_assignable<value_type>::value)
{
if (std::__1::next(__first) == __middle)
return std::__1::__rotate_left(__first, __last);
if (std::__1::next(__middle) == __last)
return std::__1::__rotate_right(__first, __last);
}
return std::__1::__rotate_forward(__first, __middle, __last);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_RandomAccessIterator
__rotate(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last,
std::__1::random_access_iterator_tag)
{
typedef typename std::__1::iterator_traits<_RandomAccessIterator>::value_type value_type;
if (std::__1::is_trivially_move_assignable<value_type>::value)
{
if (std::__1::next(__first) == __middle)
return std::__1::__rotate_left(__first, __last);
if (std::__1::next(__middle) == __last)
return std::__1::__rotate_right(__first, __last);
return std::__1::__rotate_gcd(__first, __middle, __last);
}
return std::__1::__rotate_forward(__first, __middle, __last);
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
rotate(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last)
{
if (__first == __middle)
return __last;
if (__middle == __last)
return __first;
return std::__1::__rotate(__first, __middle, __last,
typename std::__1::iterator_traits<_ForwardIterator>::iterator_category());
}
template <class _ForwardIterator, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
rotate_copy(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last, _OutputIterator __result)
{
return std::__1::copy(__first, __middle, std::__1::copy(__middle, __last, __result));
}
template <class _ForwardIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
min_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)
{
if (__first != __last)
{
_ForwardIterator __i = __first;
while (++__i != __last)
if (__comp(*__i, *__first))
__first = __i;
}
return __first;
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
min_element(_ForwardIterator __first, _ForwardIterator __last)
{
return std::__1::min_element(__first, __last,
__less<typename iterator_traits<_ForwardIterator>::value_type>());
}
template <class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const _Tp&
min(const _Tp& __a, const _Tp& __b, _Compare __comp)
{
return __comp(__b, __a) ? __b : __a;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const _Tp&
min(const _Tp& __a, const _Tp& __b)
{
return std::__1::min(__a, __b, __less<_Tp>());
}
# 2679 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <class _ForwardIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
max_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)
{
if (__first != __last)
{
_ForwardIterator __i = __first;
while (++__i != __last)
if (__comp(*__first, *__i))
__first = __i;
}
return __first;
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
max_element(_ForwardIterator __first, _ForwardIterator __last)
{
return std::__1::max_element(__first, __last,
__less<typename iterator_traits<_ForwardIterator>::value_type>());
}
template <class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const _Tp&
max(const _Tp& __a, const _Tp& __b, _Compare __comp)
{
return __comp(__a, __b) ? __b : __a;
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const _Tp&
max(const _Tp& __a, const _Tp& __b)
{
return std::__1::max(__a, __b, __less<_Tp>());
}
# 2765 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <class _ForwardIterator, class _Compare>
std::pair<_ForwardIterator, _ForwardIterator>
minmax_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)
{
std::pair<_ForwardIterator, _ForwardIterator> __result(__first, __first);
if (__first != __last)
{
if (++__first != __last)
{
if (__comp(*__first, *__result.first))
__result.first = __first;
else
__result.second = __first;
while (++__first != __last)
{
_ForwardIterator __i = __first;
if (++__first == __last)
{
if (__comp(*__i, *__result.first))
__result.first = __i;
else if (!__comp(*__i, *__result.second))
__result.second = __i;
break;
}
else
{
if (__comp(*__first, *__i))
{
if (__comp(*__first, *__result.first))
__result.first = __first;
if (!__comp(*__i, *__result.second))
__result.second = __i;
}
else
{
if (__comp(*__i, *__result.first))
__result.first = __i;
if (!__comp(*__first, *__result.second))
__result.second = __first;
}
}
}
}
}
return __result;
}
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
std::pair<_ForwardIterator, _ForwardIterator>
minmax_element(_ForwardIterator __first, _ForwardIterator __last)
{
return std::__1::minmax_element(__first, __last,
__less<typename iterator_traits<_ForwardIterator>::value_type>());
}
template<class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<const _Tp&, const _Tp&>
minmax(const _Tp& __a, const _Tp& __b, _Compare __comp)
{
return __comp(__b, __a) ? pair<const _Tp&, const _Tp&>(__b, __a) :
pair<const _Tp&, const _Tp&>(__a, __b);
}
template<class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<const _Tp&, const _Tp&>
minmax(const _Tp& __a, const _Tp& __b)
{
return std::__1::minmax(__a, __b, __less<_Tp>());
}
# 2894 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template <unsigned long long _Xp, size_t _Rp>
struct __log2_imp
{
static const size_t value = _Xp & ((unsigned long long)(1) << _Rp) ? _Rp
: __log2_imp<_Xp, _Rp - 1>::value;
};
template <unsigned long long _Xp>
struct __log2_imp<_Xp, 0>
{
static const size_t value = 0;
};
template <size_t _Rp>
struct __log2_imp<0, _Rp>
{
static const size_t value = _Rp + 1;
};
template <class _UIntType, _UIntType _Xp>
struct __log2
{
static const size_t value = __log2_imp<_Xp,
sizeof(_UIntType) * 8 - 1>::value;
};
template<class _Engine, class _UIntType>
class __independent_bits_engine
{
public:
typedef _UIntType result_type;
private:
typedef typename _Engine::result_type _Engine_result_type;
typedef typename conditional
<
sizeof(_Engine_result_type) <= sizeof(result_type),
result_type,
_Engine_result_type
>::type _Working_result_type;
_Engine& __e_;
size_t __w_;
size_t __w0_;
size_t __n_;
size_t __n0_;
_Working_result_type __y0_;
_Working_result_type __y1_;
_Engine_result_type __mask0_;
_Engine_result_type __mask1_;
static const _Working_result_type _Rp = _Engine::_Max - _Engine::_Min
+ _Working_result_type(1);
static const size_t __m = __log2<_Working_result_type, _Rp>::value;
static const size_t _WDt = numeric_limits<_Working_result_type>::digits;
static const size_t _EDt = numeric_limits<_Engine_result_type>::digits;
public:
__independent_bits_engine(_Engine& __e, size_t __w);
result_type operator()() {return __eval(integral_constant<bool, _Rp != 0>());}
private:
result_type __eval(false_type);
result_type __eval(true_type);
};
template<class _Engine, class _UIntType>
__independent_bits_engine<_Engine, _UIntType>
::__independent_bits_engine(_Engine& __e, size_t __w)
: __e_(__e),
__w_(__w)
{
__n_ = __w_ / __m + (__w_ % __m != 0);
__w0_ = __w_ / __n_;
if (_Rp == 0)
__y0_ = _Rp;
else if (__w0_ < _WDt)
__y0_ = (_Rp >> __w0_) << __w0_;
else
__y0_ = 0;
if (_Rp - __y0_ > __y0_ / __n_)
{
++__n_;
__w0_ = __w_ / __n_;
if (__w0_ < _WDt)
__y0_ = (_Rp >> __w0_) << __w0_;
else
__y0_ = 0;
}
__n0_ = __n_ - __w_ % __n_;
if (__w0_ < _WDt - 1)
__y1_ = (_Rp >> (__w0_ + 1)) << (__w0_ + 1);
else
__y1_ = 0;
__mask0_ = __w0_ > 0 ? _Engine_result_type(~0) >> (_EDt - __w0_) :
_Engine_result_type(0);
__mask1_ = __w0_ < _EDt - 1 ?
_Engine_result_type(~0) >> (_EDt - (__w0_ + 1)) :
_Engine_result_type(~0);
}
template<class _Engine, class _UIntType>
inline
_UIntType
__independent_bits_engine<_Engine, _UIntType>::__eval(false_type)
{
return static_cast<result_type>(__e_() & __mask0_);
}
template<class _Engine, class _UIntType>
_UIntType
__independent_bits_engine<_Engine, _UIntType>::__eval(true_type)
{
const size_t _WRt = numeric_limits<result_type>::digits;
result_type _Sp = 0;
for (size_t __k = 0; __k < __n0_; ++__k)
{
_Engine_result_type __u;
do
{
__u = __e_() - _Engine::min();
} while (__u >= __y0_);
if (__w0_ < _WRt)
_Sp <<= __w0_;
else
_Sp = 0;
_Sp += __u & __mask0_;
}
for (size_t __k = __n0_; __k < __n_; ++__k)
{
_Engine_result_type __u;
do
{
__u = __e_() - _Engine::min();
} while (__u >= __y1_);
if (__w0_ < _WRt - 1)
_Sp <<= __w0_ + 1;
else
_Sp = 0;
_Sp += __u & __mask1_;
}
return _Sp;
}
template<class _IntType = int>
class uniform_int_distribution
{
public:
typedef _IntType result_type;
class param_type
{
result_type __a_;
result_type __b_;
public:
typedef uniform_int_distribution distribution_type;
explicit param_type(result_type __a = 0,
result_type __b = numeric_limits<result_type>::max())
: __a_(__a), __b_(__b) {}
result_type a() const {return __a_;}
result_type b() const {return __b_;}
friend bool operator==(const param_type& __x, const param_type& __y)
{return __x.__a_ == __y.__a_ && __x.__b_ == __y.__b_;}
friend bool operator!=(const param_type& __x, const param_type& __y)
{return !(__x == __y);}
};
private:
param_type __p_;
public:
explicit uniform_int_distribution(result_type __a = 0,
result_type __b = numeric_limits<result_type>::max())
: __p_(param_type(__a, __b)) {}
explicit uniform_int_distribution(const param_type& __p) : __p_(__p) {}
void reset() {}
template<class _URNG> result_type operator()(_URNG& __g)
{return (*this)(__g, __p_);}
template<class _URNG> result_type operator()(_URNG& __g, const param_type& __p);
result_type a() const {return __p_.a();}
result_type b() const {return __p_.b();}
param_type param() const {return __p_;}
void param(const param_type& __p) {__p_ = __p;}
result_type min() const {return a();}
result_type max() const {return b();}
friend bool operator==(const uniform_int_distribution& __x,
const uniform_int_distribution& __y)
{return __x.__p_ == __y.__p_;}
friend bool operator!=(const uniform_int_distribution& __x,
const uniform_int_distribution& __y)
{return !(__x == __y);}
};
template<class _IntType>
template<class _URNG>
typename uniform_int_distribution<_IntType>::result_type
uniform_int_distribution<_IntType>::operator()(_URNG& __g, const param_type& __p)
{
typedef typename conditional<sizeof(result_type) <= sizeof(uint32_t),
uint32_t, uint64_t>::type _UIntType;
const _UIntType _Rp = __p.b() - __p.a() + _UIntType(1);
if (_Rp == 1)
return __p.a();
const size_t _Dt = numeric_limits<_UIntType>::digits;
typedef __independent_bits_engine<_URNG, _UIntType> _Eng;
if (_Rp == 0)
return static_cast<result_type>(_Eng(__g, _Dt)());
size_t __w = _Dt - __clz(_Rp) - 1;
if ((_Rp & (std::numeric_limits<_UIntType>::max() >> (_Dt - __w))) != 0)
++__w;
_Eng __e(__g, __w);
_UIntType __u;
do
{
__u = __e();
} while (__u >= _Rp);
return static_cast<result_type>(__u + __p.a());
}
class __attribute__ ((__visibility__("default"))) __rs_default;
__attribute__ ((__visibility__("default"))) __rs_default __rs_get();
class __attribute__ ((__visibility__("default"))) __rs_default
{
static unsigned __c_;
__rs_default();
public:
typedef uint_fast32_t result_type;
static const result_type _Min = 0;
static const result_type _Max = 0xFFFFFFFF;
__rs_default(const __rs_default&);
~__rs_default();
result_type operator()();
static result_type min() {return _Min;}
static result_type max() {return _Max;}
friend __attribute__ ((__visibility__("default"))) __rs_default __rs_get();
};
__attribute__ ((__visibility__("default"))) __rs_default __rs_get();
template <class _RandomAccessIterator>
void
random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
typedef uniform_int_distribution<ptrdiff_t> _Dp;
typedef typename _Dp::param_type _Pp;
difference_type __d = __last - __first;
if (__d > 1)
{
_Dp __uid;
__rs_default __g = __rs_get();
for (--__last, --__d; __first < __last; ++__first, --__d)
{
difference_type __i = __uid(__g, _Pp(0, __d));
if (__i != difference_type(0))
swap(*__first, *(__first + __i));
}
}
}
template <class _RandomAccessIterator, class _RandomNumberGenerator>
void
random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last,
_RandomNumberGenerator& __rand)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
difference_type __d = __last - __first;
if (__d > 1)
{
for (--__last; __first < __last; ++__first, --__d)
{
difference_type __i = __rand(__d);
swap(*__first, *(__first + __i));
}
}
}
template <class _PopulationIterator, class _SampleIterator, class _Distance,
class _UniformRandomNumberGenerator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_SampleIterator __sample(_PopulationIterator __first,
_PopulationIterator __last, _SampleIterator __output_iter,
_Distance __n,
_UniformRandomNumberGenerator & __g,
input_iterator_tag) {
_Distance __k = 0;
for (; __first != __last && __k < __n; ++__first, (void)++__k)
__output_iter[__k] = *__first;
_Distance __sz = __k;
for (; __first != __last; ++__first, (void)++__k) {
_Distance __r = std::__1::uniform_int_distribution<_Distance>(0, __k)(__g);
if (__r < __sz)
__output_iter[__r] = *__first;
}
return __output_iter + std::__1::min(__n, __k);
}
template <class _PopulationIterator, class _SampleIterator, class _Distance,
class _UniformRandomNumberGenerator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_SampleIterator __sample(_PopulationIterator __first,
_PopulationIterator __last, _SampleIterator __output_iter,
_Distance __n,
_UniformRandomNumberGenerator& __g,
forward_iterator_tag) {
_Distance __unsampled_sz = std::__1::distance(__first, __last);
for (__n = std::__1::min(__n, __unsampled_sz); __n != 0; ++__first) {
_Distance __r =
std::__1::uniform_int_distribution<_Distance>(0, --__unsampled_sz)(__g);
if (__r < __n) {
*__output_iter++ = *__first;
--__n;
}
}
return __output_iter;
}
template <class _PopulationIterator, class _SampleIterator, class _Distance,
class _UniformRandomNumberGenerator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_SampleIterator __sample(_PopulationIterator __first,
_PopulationIterator __last, _SampleIterator __output_iter,
_Distance __n, _UniformRandomNumberGenerator& __g) {
typedef typename iterator_traits<_PopulationIterator>::iterator_category
_PopCategory;
typedef typename iterator_traits<_PopulationIterator>::difference_type
_Difference;
_Static_assert(__is_forward_iterator<_PopulationIterator>::value || __is_random_access_iterator<_SampleIterator>::value, "SampleIterator must meet the requirements of RandomAccessIterator");
typedef typename common_type<_Distance, _Difference>::type _CommonType;
((void)0);
return std::__1::__sample(
__first, __last, __output_iter, _CommonType(__n),
__g, _PopCategory());
}
# 3281 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
template<class _RandomAccessIterator, class _UniformRandomNumberGenerator>
void shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last,
_UniformRandomNumberGenerator& __g)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
typedef uniform_int_distribution<ptrdiff_t> _Dp;
typedef typename _Dp::param_type _Pp;
difference_type __d = __last - __first;
if (__d > 1)
{
_Dp __uid;
for (--__last, --__d; __first < __last; ++__first, --__d)
{
difference_type __i = __uid(__g, _Pp(0, __d));
if (__i != difference_type(0))
swap(*__first, *(__first + __i));
}
}
}
template <class _InputIterator, class _Predicate>
bool
is_partitioned(_InputIterator __first, _InputIterator __last, _Predicate __pred)
{
for (; __first != __last; ++__first)
if (!__pred(*__first))
break;
if ( __first == __last )
return true;
++__first;
for (; __first != __last; ++__first)
if (__pred(*__first))
return false;
return true;
}
template <class _Predicate, class _ForwardIterator>
_ForwardIterator
__partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred, forward_iterator_tag)
{
while (true)
{
if (__first == __last)
return __first;
if (!__pred(*__first))
break;
++__first;
}
for (_ForwardIterator __p = __first; ++__p != __last;)
{
if (__pred(*__p))
{
swap(*__first, *__p);
++__first;
}
}
return __first;
}
template <class _Predicate, class _BidirectionalIterator>
_BidirectionalIterator
__partition(_BidirectionalIterator __first, _BidirectionalIterator __last, _Predicate __pred,
bidirectional_iterator_tag)
{
while (true)
{
while (true)
{
if (__first == __last)
return __first;
if (!__pred(*__first))
break;
++__first;
}
do
{
if (__first == --__last)
return __first;
} while (!__pred(*__last));
swap(*__first, *__last);
++__first;
}
}
template <class _ForwardIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred)
{
return std::__1::__partition<typename add_lvalue_reference<_Predicate>::type>
(__first, __last, __pred, typename iterator_traits<_ForwardIterator>::iterator_category());
}
template <class _InputIterator, class _OutputIterator1,
class _OutputIterator2, class _Predicate>
pair<_OutputIterator1, _OutputIterator2>
partition_copy(_InputIterator __first, _InputIterator __last,
_OutputIterator1 __out_true, _OutputIterator2 __out_false,
_Predicate __pred)
{
for (; __first != __last; ++__first)
{
if (__pred(*__first))
{
*__out_true = *__first;
++__out_true;
}
else
{
*__out_false = *__first;
++__out_false;
}
}
return pair<_OutputIterator1, _OutputIterator2>(__out_true, __out_false);
}
template<class _ForwardIterator, class _Predicate>
_ForwardIterator
partition_point(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred)
{
typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type;
difference_type __len = std::__1::distance(__first, __last);
while (__len != 0)
{
difference_type __l2 = __len / 2;
_ForwardIterator __m = __first;
std::__1::advance(__m, __l2);
if (__pred(*__m))
{
__first = ++__m;
__len -= __l2 + 1;
}
else
__len = __l2;
}
return __first;
}
template <class _Predicate, class _ForwardIterator, class _Distance, class _Pair>
_ForwardIterator
__stable_partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred,
_Distance __len, _Pair __p, forward_iterator_tag __fit)
{
if (__len == 1)
return __first;
if (__len == 2)
{
_ForwardIterator __m = __first;
if (__pred(*++__m))
{
swap(*__first, *__m);
return __m;
}
return __first;
}
if (__len <= __p.second)
{
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h(__p.first, __d);
value_type* __t = __p.first;
::new(__t) value_type(std::__1::move(*__first));
__d.__incr((value_type*)0);
++__t;
_ForwardIterator __i = __first;
while (++__i != __last)
{
if (__pred(*__i))
{
*__first = std::__1::move(*__i);
++__first;
}
else
{
::new(__t) value_type(std::__1::move(*__i));
__d.__incr((value_type*)0);
++__t;
}
}
__i = __first;
for (value_type* __t2 = __p.first; __t2 < __t; ++__t2, ++__i)
*__i = std::__1::move(*__t2);
return __first;
}
_ForwardIterator __m = __first;
_Distance __len2 = __len / 2;
std::__1::advance(__m, __len2);
typedef typename add_lvalue_reference<_Predicate>::type _PredRef;
_ForwardIterator __first_false = __stable_partition<_PredRef>(__first, __m, __pred, __len2, __p, __fit);
_ForwardIterator __m1 = __m;
_ForwardIterator __second_false = __last;
_Distance __len_half = __len - __len2;
while (__pred(*__m1))
{
if (++__m1 == __last)
goto __second_half_done;
--__len_half;
}
__second_false = __stable_partition<_PredRef>(__m1, __last, __pred, __len_half, __p, __fit);
__second_half_done:
return std::__1::rotate(__first_false, __m, __second_false);
}
struct __return_temporary_buffer
{
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__)) void operator()(_Tp* __p) const {std::__1::return_temporary_buffer(__p);}
};
template <class _Predicate, class _ForwardIterator>
_ForwardIterator
__stable_partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred,
forward_iterator_tag)
{
const unsigned __alloc_limit = 3;
while (true)
{
if (__first == __last)
return __first;
if (!__pred(*__first))
break;
++__first;
}
typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type;
typedef typename iterator_traits<_ForwardIterator>::value_type value_type;
difference_type __len = std::__1::distance(__first, __last);
pair<value_type*, ptrdiff_t> __p(0, 0);
unique_ptr<value_type, __return_temporary_buffer> __h;
if (__len >= __alloc_limit)
{
__p = std::__1::get_temporary_buffer<value_type>(__len);
__h.reset(__p.first);
}
return __stable_partition<typename add_lvalue_reference<_Predicate>::type>
(__first, __last, __pred, __len, __p, forward_iterator_tag());
}
template <class _Predicate, class _BidirectionalIterator, class _Distance, class _Pair>
_BidirectionalIterator
__stable_partition(_BidirectionalIterator __first, _BidirectionalIterator __last, _Predicate __pred,
_Distance __len, _Pair __p, bidirectional_iterator_tag __bit)
{
if (__len == 2)
{
swap(*__first, *__last);
return __last;
}
if (__len == 3)
{
_BidirectionalIterator __m = __first;
if (__pred(*++__m))
{
swap(*__first, *__m);
swap(*__m, *__last);
return __last;
}
swap(*__m, *__last);
swap(*__first, *__m);
return __m;
}
if (__len <= __p.second)
{
typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type;
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h(__p.first, __d);
value_type* __t = __p.first;
::new(__t) value_type(std::__1::move(*__first));
__d.__incr((value_type*)0);
++__t;
_BidirectionalIterator __i = __first;
while (++__i != __last)
{
if (__pred(*__i))
{
*__first = std::__1::move(*__i);
++__first;
}
else
{
::new(__t) value_type(std::__1::move(*__i));
__d.__incr((value_type*)0);
++__t;
}
}
*__first = std::__1::move(*__i);
__i = ++__first;
for (value_type* __t2 = __p.first; __t2 < __t; ++__t2, ++__i)
*__i = std::__1::move(*__t2);
return __first;
}
_BidirectionalIterator __m = __first;
_Distance __len2 = __len / 2;
std::__1::advance(__m, __len2);
_BidirectionalIterator __m1 = __m;
_BidirectionalIterator __first_false = __first;
_Distance __len_half = __len2;
while (!__pred(*--__m1))
{
if (__m1 == __first)
goto __first_half_done;
--__len_half;
}
typedef typename add_lvalue_reference<_Predicate>::type _PredRef;
__first_false = __stable_partition<_PredRef>(__first, __m1, __pred, __len_half, __p, __bit);
__first_half_done:
__m1 = __m;
_BidirectionalIterator __second_false = __last;
++__second_false;
__len_half = __len - __len2;
while (__pred(*__m1))
{
if (++__m1 == __last)
goto __second_half_done;
--__len_half;
}
__second_false = __stable_partition<_PredRef>(__m1, __last, __pred, __len_half, __p, __bit);
__second_half_done:
return std::__1::rotate(__first_false, __m, __second_false);
}
template <class _Predicate, class _BidirectionalIterator>
_BidirectionalIterator
__stable_partition(_BidirectionalIterator __first, _BidirectionalIterator __last, _Predicate __pred,
bidirectional_iterator_tag)
{
typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type;
typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type;
const difference_type __alloc_limit = 4;
while (true)
{
if (__first == __last)
return __first;
if (!__pred(*__first))
break;
++__first;
}
do
{
if (__first == --__last)
return __first;
} while (!__pred(*__last));
difference_type __len = std::__1::distance(__first, __last) + 1;
pair<value_type*, ptrdiff_t> __p(0, 0);
unique_ptr<value_type, __return_temporary_buffer> __h;
if (__len >= __alloc_limit)
{
__p = std::__1::get_temporary_buffer<value_type>(__len);
__h.reset(__p.first);
}
return __stable_partition<typename add_lvalue_reference<_Predicate>::type>
(__first, __last, __pred, __len, __p, bidirectional_iterator_tag());
}
template <class _ForwardIterator, class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
stable_partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred)
{
return __stable_partition<typename add_lvalue_reference<_Predicate>::type>
(__first, __last, __pred, typename iterator_traits<_ForwardIterator>::iterator_category());
}
template <class _ForwardIterator, class _Compare>
_ForwardIterator
is_sorted_until(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)
{
if (__first != __last)
{
_ForwardIterator __i = __first;
while (++__i != __last)
{
if (__comp(*__i, *__first))
return __i;
__first = __i;
}
}
return __last;
}
template<class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
is_sorted_until(_ForwardIterator __first, _ForwardIterator __last)
{
return std::__1::is_sorted_until(__first, __last, __less<typename iterator_traits<_ForwardIterator>::value_type>());
}
template <class _ForwardIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
is_sorted(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp)
{
return std::__1::is_sorted_until(__first, __last, __comp) == __last;
}
template<class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
is_sorted(_ForwardIterator __first, _ForwardIterator __last)
{
return std::__1::is_sorted(__first, __last, __less<typename iterator_traits<_ForwardIterator>::value_type>());
}
template <class _Compare, class _ForwardIterator>
unsigned
__sort3(_ForwardIterator __x, _ForwardIterator __y, _ForwardIterator __z, _Compare __c)
{
unsigned __r = 0;
if (!__c(*__y, *__x))
{
if (!__c(*__z, *__y))
return __r;
swap(*__y, *__z);
__r = 1;
if (__c(*__y, *__x))
{
swap(*__x, *__y);
__r = 2;
}
return __r;
}
if (__c(*__z, *__y))
{
swap(*__x, *__z);
__r = 1;
return __r;
}
swap(*__x, *__y);
__r = 1;
if (__c(*__z, *__y))
{
swap(*__y, *__z);
__r = 2;
}
return __r;
}
template <class _Compare, class _ForwardIterator>
unsigned
__sort4(_ForwardIterator __x1, _ForwardIterator __x2, _ForwardIterator __x3,
_ForwardIterator __x4, _Compare __c)
{
unsigned __r = __sort3<_Compare>(__x1, __x2, __x3, __c);
if (__c(*__x4, *__x3))
{
swap(*__x3, *__x4);
++__r;
if (__c(*__x3, *__x2))
{
swap(*__x2, *__x3);
++__r;
if (__c(*__x2, *__x1))
{
swap(*__x1, *__x2);
++__r;
}
}
}
return __r;
}
template <class _Compare, class _ForwardIterator>
unsigned
__sort5(_ForwardIterator __x1, _ForwardIterator __x2, _ForwardIterator __x3,
_ForwardIterator __x4, _ForwardIterator __x5, _Compare __c)
{
unsigned __r = __sort4<_Compare>(__x1, __x2, __x3, __x4, __c);
if (__c(*__x5, *__x4))
{
swap(*__x4, *__x5);
++__r;
if (__c(*__x4, *__x3))
{
swap(*__x3, *__x4);
++__r;
if (__c(*__x3, *__x2))
{
swap(*__x2, *__x3);
++__r;
if (__c(*__x2, *__x1))
{
swap(*__x1, *__x2);
++__r;
}
}
}
}
return __r;
}
template <class _Compare, class _BirdirectionalIterator>
void
__selection_sort(_BirdirectionalIterator __first, _BirdirectionalIterator __last, _Compare __comp)
{
_BirdirectionalIterator __lm1 = __last;
for (--__lm1; __first != __lm1; ++__first)
{
_BirdirectionalIterator __i = std::__1::min_element<_BirdirectionalIterator,
typename add_lvalue_reference<_Compare>::type>
(__first, __last, __comp);
if (__i != __first)
swap(*__first, *__i);
}
}
template <class _Compare, class _BirdirectionalIterator>
void
__insertion_sort(_BirdirectionalIterator __first, _BirdirectionalIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_BirdirectionalIterator>::value_type value_type;
if (__first != __last)
{
_BirdirectionalIterator __i = __first;
for (++__i; __i != __last; ++__i)
{
_BirdirectionalIterator __j = __i;
value_type __t(std::__1::move(*__j));
for (_BirdirectionalIterator __k = __i; __k != __first && __comp(__t, *--__k); --__j)
*__j = std::__1::move(*__k);
*__j = std::__1::move(__t);
}
}
}
template <class _Compare, class _RandomAccessIterator>
void
__insertion_sort_3(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
_RandomAccessIterator __j = __first+2;
__sort3<_Compare>(__first, __first+1, __j, __comp);
for (_RandomAccessIterator __i = __j+1; __i != __last; ++__i)
{
if (__comp(*__i, *__j))
{
value_type __t(std::__1::move(*__i));
_RandomAccessIterator __k = __j;
__j = __i;
do
{
*__j = std::__1::move(*__k);
__j = __k;
} while (__j != __first && __comp(__t, *--__k));
*__j = std::__1::move(__t);
}
__j = __i;
}
}
template <class _Compare, class _RandomAccessIterator>
bool
__insertion_sort_incomplete(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
switch (__last - __first)
{
case 0:
case 1:
return true;
case 2:
if (__comp(*--__last, *__first))
swap(*__first, *__last);
return true;
case 3:
std::__1::__sort3<_Compare>(__first, __first+1, --__last, __comp);
return true;
case 4:
std::__1::__sort4<_Compare>(__first, __first+1, __first+2, --__last, __comp);
return true;
case 5:
std::__1::__sort5<_Compare>(__first, __first+1, __first+2, __first+3, --__last, __comp);
return true;
}
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
_RandomAccessIterator __j = __first+2;
__sort3<_Compare>(__first, __first+1, __j, __comp);
const unsigned __limit = 8;
unsigned __count = 0;
for (_RandomAccessIterator __i = __j+1; __i != __last; ++__i)
{
if (__comp(*__i, *__j))
{
value_type __t(std::__1::move(*__i));
_RandomAccessIterator __k = __j;
__j = __i;
do
{
*__j = std::__1::move(*__k);
__j = __k;
} while (__j != __first && __comp(__t, *--__k));
*__j = std::__1::move(__t);
if (++__count == __limit)
return ++__i == __last;
}
__j = __i;
}
return true;
}
template <class _Compare, class _BirdirectionalIterator>
void
__insertion_sort_move(_BirdirectionalIterator __first1, _BirdirectionalIterator __last1,
typename iterator_traits<_BirdirectionalIterator>::value_type* __first2, _Compare __comp)
{
typedef typename iterator_traits<_BirdirectionalIterator>::value_type value_type;
if (__first1 != __last1)
{
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h(__first2, __d);
value_type* __last2 = __first2;
::new(__last2) value_type(std::__1::move(*__first1));
__d.__incr((value_type*)0);
for (++__last2; ++__first1 != __last1; ++__last2)
{
value_type* __j2 = __last2;
value_type* __i2 = __j2;
if (__comp(*__first1, *--__i2))
{
::new(__j2) value_type(std::__1::move(*__i2));
__d.__incr((value_type*)0);
for (--__j2; __i2 != __first2 && __comp(*__first1, *--__i2); --__j2)
*__j2 = std::__1::move(*__i2);
*__j2 = std::__1::move(*__first1);
}
else
{
::new(__j2) value_type(std::__1::move(*__first1));
__d.__incr((value_type*)0);
}
}
__h.release();
}
}
template <class _Compare, class _RandomAccessIterator>
void
__sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
const difference_type __limit = is_trivially_copy_constructible<value_type>::value &&
is_trivially_copy_assignable<value_type>::value ? 30 : 6;
while (true)
{
__restart:
difference_type __len = __last - __first;
switch (__len)
{
case 0:
case 1:
return;
case 2:
if (__comp(*--__last, *__first))
swap(*__first, *__last);
return;
case 3:
std::__1::__sort3<_Compare>(__first, __first+1, --__last, __comp);
return;
case 4:
std::__1::__sort4<_Compare>(__first, __first+1, __first+2, --__last, __comp);
return;
case 5:
std::__1::__sort5<_Compare>(__first, __first+1, __first+2, __first+3, --__last, __comp);
return;
}
if (__len <= __limit)
{
std::__1::__insertion_sort_3<_Compare>(__first, __last, __comp);
return;
}
_RandomAccessIterator __m = __first;
_RandomAccessIterator __lm1 = __last;
--__lm1;
unsigned __n_swaps;
{
difference_type __delta;
if (__len >= 1000)
{
__delta = __len/2;
__m += __delta;
__delta /= 2;
__n_swaps = std::__1::__sort5<_Compare>(__first, __first + __delta, __m, __m+__delta, __lm1, __comp);
}
else
{
__delta = __len/2;
__m += __delta;
__n_swaps = std::__1::__sort3<_Compare>(__first, __m, __lm1, __comp);
}
}
_RandomAccessIterator __i = __first;
_RandomAccessIterator __j = __lm1;
if (!__comp(*__i, *__m))
{
while (true)
{
if (__i == --__j)
{
++__i;
__j = __last;
if (!__comp(*__first, *--__j))
{
while (true)
{
if (__i == __j)
return;
if (__comp(*__first, *__i))
{
swap(*__i, *__j);
++__n_swaps;
++__i;
break;
}
++__i;
}
}
if (__i == __j)
return;
while (true)
{
while (!__comp(*__first, *__i))
++__i;
while (__comp(*__first, *--__j))
;
if (__i >= __j)
break;
swap(*__i, *__j);
++__n_swaps;
++__i;
}
__first = __i;
goto __restart;
}
if (__comp(*__j, *__m))
{
swap(*__i, *__j);
++__n_swaps;
break;
}
}
}
++__i;
if (__i < __j)
{
while (true)
{
while (__comp(*__i, *__m))
++__i;
while (!__comp(*--__j, *__m))
;
if (__i > __j)
break;
swap(*__i, *__j);
++__n_swaps;
if (__m == __i)
__m = __j;
++__i;
}
}
if (__i != __m && __comp(*__m, *__i))
{
swap(*__i, *__m);
++__n_swaps;
}
if (__n_swaps == 0)
{
bool __fs = std::__1::__insertion_sort_incomplete<_Compare>(__first, __i, __comp);
if (std::__1::__insertion_sort_incomplete<_Compare>(__i+1, __last, __comp))
{
if (__fs)
return;
__last = __i;
continue;
}
else
{
if (__fs)
{
__first = ++__i;
continue;
}
}
}
if (__i - __first < __last - __i)
{
std::__1::__sort<_Compare>(__first, __i, __comp);
__first = ++__i;
}
else
{
std::__1::__sort<_Compare>(__i+1, __last, __comp);
__last = __i;
}
}
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__sort<_Comp_ref>(__first, __last, __comp);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
std::__1::sort(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort(_Tp** __first, _Tp** __last)
{
std::__1::sort((size_t*)__first, (size_t*)__last, __less<size_t>());
}
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort(__wrap_iter<_Tp*> __first, __wrap_iter<_Tp*> __last)
{
std::__1::sort(__first.base(), __last.base());
}
template <class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort(__wrap_iter<_Tp*> __first, __wrap_iter<_Tp*> __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
std::__1::sort<_Tp*, _Comp_ref>(__first.base(), __last.base(), __comp);
}
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<char>&, char*>(char*, char*, __less<char>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<wchar_t>&, wchar_t*>(wchar_t*, wchar_t*, __less<wchar_t>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<signed char>&, signed char*>(signed char*, signed char*, __less<signed char>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<unsigned char>&, unsigned char*>(unsigned char*, unsigned char*, __less<unsigned char>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<short>&, short*>(short*, short*, __less<short>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<unsigned short>&, unsigned short*>(unsigned short*, unsigned short*, __less<unsigned short>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<int>&, int*>(int*, int*, __less<int>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<unsigned>&, unsigned*>(unsigned*, unsigned*, __less<unsigned>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<long>&, long*>(long*, long*, __less<long>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<unsigned long>&, unsigned long*>(unsigned long*, unsigned long*, __less<unsigned long>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<long long>&, long long*>(long long*, long long*, __less<long long>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<unsigned long long>&, unsigned long long*>(unsigned long long*, unsigned long long*, __less<unsigned long long>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<float>&, float*>(float*, float*, __less<float>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<double>&, double*>(double*, double*, __less<double>&);
extern template __attribute__ ((__visibility__("default"))) void __sort<__less<long double>&, long double*>(long double*, long double*, __less<long double>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<char>&, char*>(char*, char*, __less<char>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<wchar_t>&, wchar_t*>(wchar_t*, wchar_t*, __less<wchar_t>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<signed char>&, signed char*>(signed char*, signed char*, __less<signed char>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<unsigned char>&, unsigned char*>(unsigned char*, unsigned char*, __less<unsigned char>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<short>&, short*>(short*, short*, __less<short>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<unsigned short>&, unsigned short*>(unsigned short*, unsigned short*, __less<unsigned short>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<int>&, int*>(int*, int*, __less<int>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<unsigned>&, unsigned*>(unsigned*, unsigned*, __less<unsigned>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<long>&, long*>(long*, long*, __less<long>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<unsigned long>&, unsigned long*>(unsigned long*, unsigned long*, __less<unsigned long>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<long long>&, long long*>(long long*, long long*, __less<long long>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<unsigned long long>&, unsigned long long*>(unsigned long long*, unsigned long long*, __less<unsigned long long>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<float>&, float*>(float*, float*, __less<float>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<double>&, double*>(double*, double*, __less<double>&);
extern template __attribute__ ((__visibility__("default"))) bool __insertion_sort_incomplete<__less<long double>&, long double*>(long double*, long double*, __less<long double>&);
extern template __attribute__ ((__visibility__("default"))) unsigned __sort5<__less<long double>&, long double*>(long double*, long double*, long double*, long double*, long double*, __less<long double>&);
template <class _Compare, class _ForwardIterator, class _Tp>
_ForwardIterator
__lower_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type;
difference_type __len = std::__1::distance(__first, __last);
while (__len != 0)
{
difference_type __l2 = __len / 2;
_ForwardIterator __m = __first;
std::__1::advance(__m, __l2);
if (__comp(*__m, __value_))
{
__first = ++__m;
__len -= __l2 + 1;
}
else
__len = __l2;
}
return __first;
}
template <class _ForwardIterator, class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
lower_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __lower_bound<_Comp_ref>(__first, __last, __value_, __comp);
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
lower_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_)
{
return std::__1::lower_bound(__first, __last, __value_,
__less<typename iterator_traits<_ForwardIterator>::value_type, _Tp>());
}
template <class _Compare, class _ForwardIterator, class _Tp>
_ForwardIterator
__upper_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type;
difference_type __len = std::__1::distance(__first, __last);
while (__len != 0)
{
difference_type __l2 = __len / 2;
_ForwardIterator __m = __first;
std::__1::advance(__m, __l2);
if (__comp(__value_, *__m))
__len = __l2;
else
{
__first = ++__m;
__len -= __l2 + 1;
}
}
return __first;
}
template <class _ForwardIterator, class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
upper_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __upper_bound<_Comp_ref>(__first, __last, __value_, __comp);
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_ForwardIterator
upper_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_)
{
return std::__1::upper_bound(__first, __last, __value_,
__less<_Tp, typename iterator_traits<_ForwardIterator>::value_type>());
}
template <class _Compare, class _ForwardIterator, class _Tp>
pair<_ForwardIterator, _ForwardIterator>
__equal_range(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type;
difference_type __len = std::__1::distance(__first, __last);
while (__len != 0)
{
difference_type __l2 = __len / 2;
_ForwardIterator __m = __first;
std::__1::advance(__m, __l2);
if (__comp(*__m, __value_))
{
__first = ++__m;
__len -= __l2 + 1;
}
else if (__comp(__value_, *__m))
{
__last = __m;
__len = __l2;
}
else
{
_ForwardIterator __mp1 = __m;
return pair<_ForwardIterator, _ForwardIterator>
(
__lower_bound<_Compare>(__first, __m, __value_, __comp),
__upper_bound<_Compare>(++__mp1, __last, __value_, __comp)
);
}
}
return pair<_ForwardIterator, _ForwardIterator>(__first, __first);
}
template <class _ForwardIterator, class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<_ForwardIterator, _ForwardIterator>
equal_range(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __equal_range<_Comp_ref>(__first, __last, __value_, __comp);
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pair<_ForwardIterator, _ForwardIterator>
equal_range(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_)
{
return std::__1::equal_range(__first, __last, __value_,
__less<typename iterator_traits<_ForwardIterator>::value_type, _Tp>());
}
template <class _Compare, class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
__binary_search(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
__first = __lower_bound<_Compare>(__first, __last, __value_, __comp);
return __first != __last && !__comp(__value_, *__first);
}
template <class _ForwardIterator, class _Tp, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
binary_search(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __binary_search<_Comp_ref>(__first, __last, __value_, __comp);
}
template <class _ForwardIterator, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
binary_search(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_)
{
return std::__1::binary_search(__first, __last, __value_,
__less<typename iterator_traits<_ForwardIterator>::value_type, _Tp>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2, class _OutputIterator>
_OutputIterator
__merge(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
for (; __first1 != __last1; ++__result)
{
if (__first2 == __last2)
return std::__1::copy(__first1, __last1, __result);
if (__comp(*__first2, *__first1))
{
*__result = *__first2;
++__first2;
}
else
{
*__result = *__first1;
++__first1;
}
}
return std::__1::copy(__first2, __last2, __result);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
merge(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return std::__1::__merge<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
merge(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result)
{
typedef typename iterator_traits<_InputIterator1>::value_type __v1;
typedef typename iterator_traits<_InputIterator2>::value_type __v2;
return merge(__first1, __last1, __first2, __last2, __result, __less<__v1, __v2>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2,
class _OutputIterator>
void __half_inplace_merge(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2,
_OutputIterator __result, _Compare __comp)
{
for (; __first1 != __last1; ++__result)
{
if (__first2 == __last2)
{
std::__1::move(__first1, __last1, __result);
return;
}
if (__comp(*__first2, *__first1))
{
*__result = std::__1::move(*__first2);
++__first2;
}
else
{
*__result = std::__1::move(*__first1);
++__first1;
}
}
}
template <class _Compare, class _BidirectionalIterator>
void
__buffered_inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last,
_Compare __comp, typename iterator_traits<_BidirectionalIterator>::difference_type __len1,
typename iterator_traits<_BidirectionalIterator>::difference_type __len2,
typename iterator_traits<_BidirectionalIterator>::value_type* __buff)
{
typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type;
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h2(__buff, __d);
if (__len1 <= __len2)
{
value_type* __p = __buff;
for (_BidirectionalIterator __i = __first; __i != __middle; __d.__incr((value_type*)0), (void) ++__i, ++__p)
::new(__p) value_type(std::__1::move(*__i));
__half_inplace_merge(__buff, __p, __middle, __last, __first, __comp);
}
else
{
value_type* __p = __buff;
for (_BidirectionalIterator __i = __middle; __i != __last; __d.__incr((value_type*)0), (void) ++__i, ++__p)
::new(__p) value_type(std::__1::move(*__i));
typedef reverse_iterator<_BidirectionalIterator> _RBi;
typedef reverse_iterator<value_type*> _Rv;
__half_inplace_merge(_Rv(__p), _Rv(__buff),
_RBi(__middle), _RBi(__first),
_RBi(__last), __invert<_Compare>(__comp));
}
}
template <class _Compare, class _BidirectionalIterator>
void
__inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last,
_Compare __comp, typename iterator_traits<_BidirectionalIterator>::difference_type __len1,
typename iterator_traits<_BidirectionalIterator>::difference_type __len2,
typename iterator_traits<_BidirectionalIterator>::value_type* __buff, ptrdiff_t __buff_size)
{
typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type;
while (true)
{
if (__len2 == 0)
return;
if (__len1 <= __buff_size || __len2 <= __buff_size)
return __buffered_inplace_merge<_Compare>
(__first, __middle, __last, __comp, __len1, __len2, __buff);
for (; true; ++__first, (void) --__len1)
{
if (__len1 == 0)
return;
if (__comp(*__middle, *__first))
break;
}
# 4607 "/Library/Developer/CommandLineTools/usr/include/c++/v1/algorithm" 3
_BidirectionalIterator __m1;
_BidirectionalIterator __m2;
difference_type __len11;
difference_type __len21;
if (__len1 < __len2)
{
__len21 = __len2 / 2;
__m2 = __middle;
std::__1::advance(__m2, __len21);
__m1 = __upper_bound<_Compare>(__first, __middle, *__m2, __comp);
__len11 = std::__1::distance(__first, __m1);
}
else
{
if (__len1 == 1)
{
swap(*__first, *__middle);
return;
}
__len11 = __len1 / 2;
__m1 = __first;
std::__1::advance(__m1, __len11);
__m2 = __lower_bound<_Compare>(__middle, __last, *__m1, __comp);
__len21 = std::__1::distance(__middle, __m2);
}
difference_type __len12 = __len1 - __len11;
difference_type __len22 = __len2 - __len21;
__middle = std::__1::rotate(__m1, __middle, __m2);
if (__len11 + __len21 < __len12 + __len22)
{
__inplace_merge<_Compare>(__first, __m1, __middle, __comp, __len11, __len21, __buff, __buff_size);
__first = __middle;
__middle = __m2;
__len1 = __len12;
__len2 = __len22;
}
else
{
__inplace_merge<_Compare>(__middle, __m2, __last, __comp, __len12, __len22, __buff, __buff_size);
__last = __middle;
__middle = __m1;
__len1 = __len11;
__len2 = __len21;
}
}
}
template <class _BidirectionalIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last,
_Compare __comp)
{
typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type;
typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type;
difference_type __len1 = std::__1::distance(__first, __middle);
difference_type __len2 = std::__1::distance(__middle, __last);
difference_type __buf_size = std::__1::min(__len1, __len2);
pair<value_type*, ptrdiff_t> __buf = std::__1::get_temporary_buffer<value_type>(__buf_size);
unique_ptr<value_type, __return_temporary_buffer> __h(__buf.first);
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return std::__1::__inplace_merge<_Comp_ref>(__first, __middle, __last, __comp, __len1, __len2,
__buf.first, __buf.second);
}
template <class _BidirectionalIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last)
{
std::__1::inplace_merge(__first, __middle, __last,
__less<typename iterator_traits<_BidirectionalIterator>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2>
void
__merge_move_construct(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2,
typename iterator_traits<_InputIterator1>::value_type* __result, _Compare __comp)
{
typedef typename iterator_traits<_InputIterator1>::value_type value_type;
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h(__result, __d);
for (; true; ++__result)
{
if (__first1 == __last1)
{
for (; __first2 != __last2; ++__first2, ++__result, __d.__incr((value_type*)0))
::new (__result) value_type(std::__1::move(*__first2));
__h.release();
return;
}
if (__first2 == __last2)
{
for (; __first1 != __last1; ++__first1, ++__result, __d.__incr((value_type*)0))
::new (__result) value_type(std::__1::move(*__first1));
__h.release();
return;
}
if (__comp(*__first2, *__first1))
{
::new (__result) value_type(std::__1::move(*__first2));
__d.__incr((value_type*)0);
++__first2;
}
else
{
::new (__result) value_type(std::__1::move(*__first1));
__d.__incr((value_type*)0);
++__first1;
}
}
}
template <class _Compare, class _InputIterator1, class _InputIterator2, class _OutputIterator>
void
__merge_move_assign(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2,
_OutputIterator __result, _Compare __comp)
{
for (; __first1 != __last1; ++__result)
{
if (__first2 == __last2)
{
for (; __first1 != __last1; ++__first1, ++__result)
*__result = std::__1::move(*__first1);
return;
}
if (__comp(*__first2, *__first1))
{
*__result = std::__1::move(*__first2);
++__first2;
}
else
{
*__result = std::__1::move(*__first1);
++__first1;
}
}
for (; __first2 != __last2; ++__first2, ++__result)
*__result = std::__1::move(*__first2);
}
template <class _Compare, class _RandomAccessIterator>
void
__stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp,
typename iterator_traits<_RandomAccessIterator>::difference_type __len,
typename iterator_traits<_RandomAccessIterator>::value_type* __buff, ptrdiff_t __buff_size);
template <class _Compare, class _RandomAccessIterator>
void
__stable_sort_move(_RandomAccessIterator __first1, _RandomAccessIterator __last1, _Compare __comp,
typename iterator_traits<_RandomAccessIterator>::difference_type __len,
typename iterator_traits<_RandomAccessIterator>::value_type* __first2)
{
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
switch (__len)
{
case 0:
return;
case 1:
::new(__first2) value_type(std::__1::move(*__first1));
return;
case 2:
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h2(__first2, __d);
if (__comp(*--__last1, *__first1))
{
::new(__first2) value_type(std::__1::move(*__last1));
__d.__incr((value_type*)0);
++__first2;
::new(__first2) value_type(std::__1::move(*__first1));
}
else
{
::new(__first2) value_type(std::__1::move(*__first1));
__d.__incr((value_type*)0);
++__first2;
::new(__first2) value_type(std::__1::move(*__last1));
}
__h2.release();
return;
}
if (__len <= 8)
{
__insertion_sort_move<_Compare>(__first1, __last1, __first2, __comp);
return;
}
typename iterator_traits<_RandomAccessIterator>::difference_type __l2 = __len / 2;
_RandomAccessIterator __m = __first1 + __l2;
__stable_sort<_Compare>(__first1, __m, __comp, __l2, __first2, __l2);
__stable_sort<_Compare>(__m, __last1, __comp, __len - __l2, __first2 + __l2, __len - __l2);
__merge_move_construct<_Compare>(__first1, __m, __m, __last1, __first2, __comp);
}
template <class _Tp>
struct __stable_sort_switch
{
static const unsigned value = 128*is_trivially_copy_assignable<_Tp>::value;
};
template <class _Compare, class _RandomAccessIterator>
void
__stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp,
typename iterator_traits<_RandomAccessIterator>::difference_type __len,
typename iterator_traits<_RandomAccessIterator>::value_type* __buff, ptrdiff_t __buff_size)
{
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
switch (__len)
{
case 0:
case 1:
return;
case 2:
if (__comp(*--__last, *__first))
swap(*__first, *__last);
return;
}
if (__len <= static_cast<difference_type>(__stable_sort_switch<value_type>::value))
{
__insertion_sort<_Compare>(__first, __last, __comp);
return;
}
typename iterator_traits<_RandomAccessIterator>::difference_type __l2 = __len / 2;
_RandomAccessIterator __m = __first + __l2;
if (__len <= __buff_size)
{
__destruct_n __d(0);
unique_ptr<value_type, __destruct_n&> __h2(__buff, __d);
__stable_sort_move<_Compare>(__first, __m, __comp, __l2, __buff);
__d.__set(__l2, (value_type*)0);
__stable_sort_move<_Compare>(__m, __last, __comp, __len - __l2, __buff + __l2);
__d.__set(__len, (value_type*)0);
__merge_move_assign<_Compare>(__buff, __buff + __l2, __buff + __l2, __buff + __len, __first, __comp);
return;
}
__stable_sort<_Compare>(__first, __m, __comp, __l2, __buff, __buff_size);
__stable_sort<_Compare>(__m, __last, __comp, __len - __l2, __buff, __buff_size);
__inplace_merge<_Compare>(__first, __m, __last, __comp, __l2, __len - __l2, __buff, __buff_size);
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
difference_type __len = __last - __first;
pair<value_type*, ptrdiff_t> __buf(0, 0);
unique_ptr<value_type, __return_temporary_buffer> __h;
if (__len > static_cast<difference_type>(__stable_sort_switch<value_type>::value))
{
__buf = std::__1::get_temporary_buffer<value_type>(__len);
__h.reset(__buf.first);
}
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__stable_sort<_Comp_ref>(__first, __last, __comp, __len, __buf.first, __buf.second);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
std::__1::stable_sort(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _RandomAccessIterator, class _Compare>
_RandomAccessIterator
is_heap_until(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename std::__1::iterator_traits<_RandomAccessIterator>::difference_type difference_type;
difference_type __len = __last - __first;
difference_type __p = 0;
difference_type __c = 1;
_RandomAccessIterator __pp = __first;
while (__c < __len)
{
_RandomAccessIterator __cp = __first + __c;
if (__comp(*__pp, *__cp))
return __cp;
++__c;
++__cp;
if (__c == __len)
return __last;
if (__comp(*__pp, *__cp))
return __cp;
++__p;
++__pp;
__c = 2 * __p + 1;
}
return __last;
}
template<class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_RandomAccessIterator
is_heap_until(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
return std::__1::is_heap_until(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
return std::__1::is_heap_until(__first, __last, __comp) == __last;
}
template<class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
return std::__1::is_heap(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _RandomAccessIterator>
void
__sift_up(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp,
typename iterator_traits<_RandomAccessIterator>::difference_type __len)
{
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
if (__len > 1)
{
__len = (__len - 2) / 2;
_RandomAccessIterator __ptr = __first + __len;
if (__comp(*__ptr, *--__last))
{
value_type __t(std::__1::move(*__last));
do
{
*__last = std::__1::move(*__ptr);
__last = __ptr;
if (__len == 0)
break;
__len = (__len - 1) / 2;
__ptr = __first + __len;
} while (__comp(*__ptr, __t));
*__last = std::__1::move(__t);
}
}
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__sift_up<_Comp_ref>(__first, __last, __comp, __last - __first);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
std::__1::push_heap(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _RandomAccessIterator>
void
__sift_down(_RandomAccessIterator __first, _RandomAccessIterator ,
_Compare __comp,
typename iterator_traits<_RandomAccessIterator>::difference_type __len,
_RandomAccessIterator __start)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type;
difference_type __child = __start - __first;
if (__len < 2 || (__len - 2) / 2 < __child)
return;
__child = 2 * __child + 1;
_RandomAccessIterator __child_i = __first + __child;
if ((__child + 1) < __len && __comp(*__child_i, *(__child_i + 1))) {
++__child_i;
++__child;
}
if (__comp(*__child_i, *__start))
return;
value_type __top(std::__1::move(*__start));
do
{
*__start = std::__1::move(*__child_i);
__start = __child_i;
if ((__len - 2) / 2 < __child)
break;
__child = 2 * __child + 1;
__child_i = __first + __child;
if ((__child + 1) < __len && __comp(*__child_i, *(__child_i + 1))) {
++__child_i;
++__child;
}
} while (!__comp(*__child_i, __top));
*__start = std::__1::move(__top);
}
template <class _Compare, class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
__pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp,
typename iterator_traits<_RandomAccessIterator>::difference_type __len)
{
if (__len > 1)
{
swap(*__first, *--__last);
__sift_down<_Compare>(__first, __last, __comp, __len - 1, __first);
}
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__pop_heap<_Comp_ref>(__first, __last, __comp, __last - __first);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
std::__1::pop_heap(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _RandomAccessIterator>
void
__make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
difference_type __n = __last - __first;
if (__n > 1)
{
for (difference_type __start = (__n - 2) / 2; __start >= 0; --__start)
{
__sift_down<_Compare>(__first, __last, __comp, __n, __first + __start);
}
}
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__make_heap<_Comp_ref>(__first, __last, __comp);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
std::__1::make_heap(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _RandomAccessIterator>
void
__sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
for (difference_type __n = __last - __first; __n > 1; --__last, --__n)
__pop_heap<_Compare>(__first, __last, __comp, __n);
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__sort_heap<_Comp_ref>(__first, __last, __comp);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
std::__1::sort_heap(__first, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _RandomAccessIterator>
void
__partial_sort(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last,
_Compare __comp)
{
__make_heap<_Compare>(__first, __middle, __comp);
typename iterator_traits<_RandomAccessIterator>::difference_type __len = __middle - __first;
for (_RandomAccessIterator __i = __middle; __i != __last; ++__i)
{
if (__comp(*__i, *__first))
{
swap(*__i, *__first);
__sift_down<_Compare>(__first, __middle, __comp, __len, __first);
}
}
__sort_heap<_Compare>(__first, __middle, __comp);
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
partial_sort(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last,
_Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__partial_sort<_Comp_ref>(__first, __middle, __last, __comp);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
partial_sort(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last)
{
std::__1::partial_sort(__first, __middle, __last,
__less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _InputIterator, class _RandomAccessIterator>
_RandomAccessIterator
__partial_sort_copy(_InputIterator __first, _InputIterator __last,
_RandomAccessIterator __result_first, _RandomAccessIterator __result_last, _Compare __comp)
{
_RandomAccessIterator __r = __result_first;
if (__r != __result_last)
{
for (; __first != __last && __r != __result_last; (void) ++__first, ++__r)
*__r = *__first;
__make_heap<_Compare>(__result_first, __r, __comp);
typename iterator_traits<_RandomAccessIterator>::difference_type __len = __r - __result_first;
for (; __first != __last; ++__first)
if (__comp(*__first, *__result_first))
{
*__result_first = *__first;
__sift_down<_Compare>(__result_first, __r, __comp, __len, __result_first);
}
__sort_heap<_Compare>(__result_first, __r, __comp);
}
return __r;
}
template <class _InputIterator, class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_RandomAccessIterator
partial_sort_copy(_InputIterator __first, _InputIterator __last,
_RandomAccessIterator __result_first, _RandomAccessIterator __result_last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __partial_sort_copy<_Comp_ref>(__first, __last, __result_first, __result_last, __comp);
}
template <class _InputIterator, class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_RandomAccessIterator
partial_sort_copy(_InputIterator __first, _InputIterator __last,
_RandomAccessIterator __result_first, _RandomAccessIterator __result_last)
{
return std::__1::partial_sort_copy(__first, __last, __result_first, __result_last,
__less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _RandomAccessIterator>
void
__nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type;
const difference_type __limit = 7;
while (true)
{
__restart:
if (__nth == __last)
return;
difference_type __len = __last - __first;
switch (__len)
{
case 0:
case 1:
return;
case 2:
if (__comp(*--__last, *__first))
swap(*__first, *__last);
return;
case 3:
{
_RandomAccessIterator __m = __first;
std::__1::__sort3<_Compare>(__first, ++__m, --__last, __comp);
return;
}
}
if (__len <= __limit)
{
__selection_sort<_Compare>(__first, __last, __comp);
return;
}
_RandomAccessIterator __m = __first + __len/2;
_RandomAccessIterator __lm1 = __last;
unsigned __n_swaps = std::__1::__sort3<_Compare>(__first, __m, --__lm1, __comp);
_RandomAccessIterator __i = __first;
_RandomAccessIterator __j = __lm1;
if (!__comp(*__i, *__m))
{
while (true)
{
if (__i == --__j)
{
++__i;
__j = __last;
if (!__comp(*__first, *--__j))
{
while (true)
{
if (__i == __j)
return;
if (__comp(*__first, *__i))
{
swap(*__i, *__j);
++__n_swaps;
++__i;
break;
}
++__i;
}
}
if (__i == __j)
return;
while (true)
{
while (!__comp(*__first, *__i))
++__i;
while (__comp(*__first, *--__j))
;
if (__i >= __j)
break;
swap(*__i, *__j);
++__n_swaps;
++__i;
}
if (__nth < __i)
return;
__first = __i;
goto __restart;
}
if (__comp(*__j, *__m))
{
swap(*__i, *__j);
++__n_swaps;
break;
}
}
}
++__i;
if (__i < __j)
{
while (true)
{
while (__comp(*__i, *__m))
++__i;
while (!__comp(*--__j, *__m))
;
if (__i >= __j)
break;
swap(*__i, *__j);
++__n_swaps;
if (__m == __i)
__m = __j;
++__i;
}
}
if (__i != __m && __comp(*__m, *__i))
{
swap(*__i, *__m);
++__n_swaps;
}
if (__nth == __i)
return;
if (__n_swaps == 0)
{
if (__nth < __i)
{
__j = __m = __first;
while (++__j != __i)
{
if (__comp(*__j, *__m))
goto not_sorted;
__m = __j;
}
return;
}
else
{
__j = __m = __i;
while (++__j != __last)
{
if (__comp(*__j, *__m))
goto not_sorted;
__m = __j;
}
return;
}
}
not_sorted:
if (__nth < __i)
{
__last = __i;
}
else
{
__first = ++__i;
}
}
}
template <class _RandomAccessIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
__nth_element<_Comp_ref>(__first, __nth, __last, __comp);
}
template <class _RandomAccessIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __last)
{
std::__1::nth_element(__first, __nth, __last, __less<typename iterator_traits<_RandomAccessIterator>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2>
bool
__includes(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _InputIterator2 __last2,
_Compare __comp)
{
for (; __first2 != __last2; ++__first1)
{
if (__first1 == __last1 || __comp(*__first2, *__first1))
return false;
if (!__comp(*__first1, *__first2))
++__first2;
}
return true;
}
template <class _InputIterator1, class _InputIterator2, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
includes(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _InputIterator2 __last2,
_Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __includes<_Comp_ref>(__first1, __last1, __first2, __last2, __comp);
}
template <class _InputIterator1, class _InputIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
includes(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _InputIterator2 __last2)
{
return std::__1::includes(__first1, __last1, __first2, __last2,
__less<typename iterator_traits<_InputIterator1>::value_type,
typename iterator_traits<_InputIterator2>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2, class _OutputIterator>
_OutputIterator
__set_union(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
for (; __first1 != __last1; ++__result)
{
if (__first2 == __last2)
return std::__1::copy(__first1, __last1, __result);
if (__comp(*__first2, *__first1))
{
*__result = *__first2;
++__first2;
}
else
{
if (!__comp(*__first1, *__first2))
++__first2;
*__result = *__first1;
++__first1;
}
}
return std::__1::copy(__first2, __last2, __result);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_union(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __set_union<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_union(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result)
{
return std::__1::set_union(__first1, __last1, __first2, __last2, __result,
__less<typename iterator_traits<_InputIterator1>::value_type,
typename iterator_traits<_InputIterator2>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2, class _OutputIterator>
_OutputIterator
__set_intersection(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
while (__first1 != __last1 && __first2 != __last2)
{
if (__comp(*__first1, *__first2))
++__first1;
else
{
if (!__comp(*__first2, *__first1))
{
*__result = *__first1;
++__result;
++__first1;
}
++__first2;
}
}
return __result;
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_intersection(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __set_intersection<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_intersection(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result)
{
return std::__1::set_intersection(__first1, __last1, __first2, __last2, __result,
__less<typename iterator_traits<_InputIterator1>::value_type,
typename iterator_traits<_InputIterator2>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2, class _OutputIterator>
_OutputIterator
__set_difference(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
while (__first1 != __last1)
{
if (__first2 == __last2)
return std::__1::copy(__first1, __last1, __result);
if (__comp(*__first1, *__first2))
{
*__result = *__first1;
++__result;
++__first1;
}
else
{
if (!__comp(*__first2, *__first1))
++__first1;
++__first2;
}
}
return __result;
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_difference(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __set_difference<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_difference(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result)
{
return std::__1::set_difference(__first1, __last1, __first2, __last2, __result,
__less<typename iterator_traits<_InputIterator1>::value_type,
typename iterator_traits<_InputIterator2>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2, class _OutputIterator>
_OutputIterator
__set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
while (__first1 != __last1)
{
if (__first2 == __last2)
return std::__1::copy(__first1, __last1, __result);
if (__comp(*__first1, *__first2))
{
*__result = *__first1;
++__result;
++__first1;
}
else
{
if (__comp(*__first2, *__first1))
{
*__result = *__first2;
++__result;
}
else
++__first1;
++__first2;
}
}
return std::__1::copy(__first2, __last2, __result);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __set_symmetric_difference<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp);
}
template <class _InputIterator1, class _InputIterator2, class _OutputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result)
{
return std::__1::set_symmetric_difference(__first1, __last1, __first2, __last2, __result,
__less<typename iterator_traits<_InputIterator1>::value_type,
typename iterator_traits<_InputIterator2>::value_type>());
}
template <class _Compare, class _InputIterator1, class _InputIterator2>
bool
__lexicographical_compare(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _Compare __comp)
{
for (; __first2 != __last2; ++__first1, (void) ++__first2)
{
if (__first1 == __last1 || __comp(*__first1, *__first2))
return true;
if (__comp(*__first2, *__first1))
return false;
}
return false;
}
template <class _InputIterator1, class _InputIterator2, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
lexicographical_compare(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __lexicographical_compare<_Comp_ref>(__first1, __last1, __first2, __last2, __comp);
}
template <class _InputIterator1, class _InputIterator2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
lexicographical_compare(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _InputIterator2 __last2)
{
return std::__1::lexicographical_compare(__first1, __last1, __first2, __last2,
__less<typename iterator_traits<_InputIterator1>::value_type,
typename iterator_traits<_InputIterator2>::value_type>());
}
template <class _Compare, class _BidirectionalIterator>
bool
__next_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp)
{
_BidirectionalIterator __i = __last;
if (__first == __last || __first == --__i)
return false;
while (true)
{
_BidirectionalIterator __ip1 = __i;
if (__comp(*--__i, *__ip1))
{
_BidirectionalIterator __j = __last;
while (!__comp(*__i, *--__j))
;
swap(*__i, *__j);
std::__1::reverse(__ip1, __last);
return true;
}
if (__i == __first)
{
std::__1::reverse(__first, __last);
return false;
}
}
}
template <class _BidirectionalIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
next_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __next_permutation<_Comp_ref>(__first, __last, __comp);
}
template <class _BidirectionalIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
next_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last)
{
return std::__1::next_permutation(__first, __last,
__less<typename iterator_traits<_BidirectionalIterator>::value_type>());
}
template <class _Compare, class _BidirectionalIterator>
bool
__prev_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp)
{
_BidirectionalIterator __i = __last;
if (__first == __last || __first == --__i)
return false;
while (true)
{
_BidirectionalIterator __ip1 = __i;
if (__comp(*__ip1, *--__i))
{
_BidirectionalIterator __j = __last;
while (!__comp(*--__j, *__i))
;
swap(*__i, *__j);
std::__1::reverse(__ip1, __last);
return true;
}
if (__i == __first)
{
std::__1::reverse(__first, __last);
return false;
}
}
}
template <class _BidirectionalIterator, class _Compare>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
prev_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp)
{
typedef typename add_lvalue_reference<_Compare>::type _Comp_ref;
return __prev_permutation<_Comp_ref>(__first, __last, __comp);
}
template <class _BidirectionalIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
prev_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last)
{
return std::__1::prev_permutation(__first, __last,
__less<typename iterator_traits<_BidirectionalIterator>::value_type>());
}
} }
# 57 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdio" 1 3
# 100 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdio" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/stdio.h" 1 3
# 101 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdio" 2 3
# 104 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cstdio" 3
namespace std {inline namespace __1 {
using ::FILE;
using ::fpos_t;
using ::size_t;
using ::fclose;
using ::fflush;
using ::setbuf;
using ::setvbuf;
using ::fprintf;
using ::fscanf;
using ::snprintf;
using ::sprintf;
using ::sscanf;
using ::vfprintf;
using ::vfscanf;
using ::vsscanf;
using ::vsnprintf;
using ::vsprintf;
using ::fgetc;
using ::fgets;
using ::fputc;
using ::fputs;
using ::getc;
using ::putc;
using ::ungetc;
using ::fread;
using ::fwrite;
using ::fgetpos;
using ::fseek;
using ::fsetpos;
using ::ftell;
using ::rewind;
using ::clearerr;
using ::feof;
using ::ferror;
using ::perror;
using ::fopen;
using ::freopen;
using ::remove;
using ::rename;
using ::tmpfile;
using ::tmpnam;
using ::getchar;
using ::gets;
using ::scanf;
using ::vscanf;
using ::printf;
using ::putchar;
using ::puts;
using ::vprintf;
} }
# 58 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 2 3
# 64 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 68 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 2 3
namespace std {inline namespace __1 {
template <class _CharT>
struct __attribute__ ((__type_visibility__("default"))) char_traits
{
typedef _CharT char_type;
typedef int int_type;
typedef streamoff off_type;
typedef streampos pos_type;
typedef mbstate_t state_type;
static inline void
assign(char_type& __c1, const char_type& __c2) throw() {__c1 = __c2;}
static inline bool eq(char_type __c1, char_type __c2) throw()
{return __c1 == __c2;}
static inline bool lt(char_type __c1, char_type __c2) throw()
{return __c1 < __c2;}
static
int compare(const char_type* __s1, const char_type* __s2, size_t __n);
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
size_t length(const char_type* __s);
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
const char_type* find(const char_type* __s, size_t __n, const char_type& __a);
static char_type* move(char_type* __s1, const char_type* __s2, size_t __n);
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* copy(char_type* __s1, const char_type* __s2, size_t __n);
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* assign(char_type* __s, size_t __n, char_type __a);
static inline int_type not_eof(int_type __c) throw()
{return eq_int_type(__c, eof()) ? ~eof() : __c;}
static inline char_type to_char_type(int_type __c) throw()
{return char_type(__c);}
static inline int_type to_int_type(char_type __c) throw()
{return int_type(__c);}
static inline bool eq_int_type(int_type __c1, int_type __c2) throw()
{return __c1 == __c2;}
static inline int_type eof() throw()
{return int_type((-1));}
};
template <class _CharT>
int
char_traits<_CharT>::compare(const char_type* __s1, const char_type* __s2, size_t __n)
{
for (; __n; --__n, ++__s1, ++__s2)
{
if (lt(*__s1, *__s2))
return -1;
if (lt(*__s2, *__s1))
return 1;
}
return 0;
}
template <class _CharT>
inline
size_t
char_traits<_CharT>::length(const char_type* __s)
{
size_t __len = 0;
for (; !eq(*__s, char_type(0)); ++__s)
++__len;
return __len;
}
template <class _CharT>
inline
const _CharT*
char_traits<_CharT>::find(const char_type* __s, size_t __n, const char_type& __a)
{
for (; __n; --__n)
{
if (eq(*__s, __a))
return __s;
++__s;
}
return 0;
}
template <class _CharT>
_CharT*
char_traits<_CharT>::move(char_type* __s1, const char_type* __s2, size_t __n)
{
char_type* __r = __s1;
if (__s1 < __s2)
{
for (; __n; --__n, ++__s1, ++__s2)
assign(*__s1, *__s2);
}
else if (__s2 < __s1)
{
__s1 += __n;
__s2 += __n;
for (; __n; --__n)
assign(*--__s1, *--__s2);
}
return __r;
}
template <class _CharT>
inline
_CharT*
char_traits<_CharT>::copy(char_type* __s1, const char_type* __s2, size_t __n)
{
((void)0);
char_type* __r = __s1;
for (; __n; --__n, ++__s1, ++__s2)
assign(*__s1, *__s2);
return __r;
}
template <class _CharT>
inline
_CharT*
char_traits<_CharT>::assign(char_type* __s, size_t __n, char_type __a)
{
char_type* __r = __s;
for (; __n; --__n, ++__s)
assign(*__s, __a);
return __r;
}
template <>
struct __attribute__ ((__type_visibility__("default"))) char_traits<char>
{
typedef char char_type;
typedef int int_type;
typedef streamoff off_type;
typedef streampos pos_type;
typedef mbstate_t state_type;
static inline
void assign(char_type& __c1, const char_type& __c2) throw() {__c1 = __c2;}
static inline bool eq(char_type __c1, char_type __c2) throw()
{return __c1 == __c2;}
static inline bool lt(char_type __c1, char_type __c2) throw()
{return (unsigned char)__c1 < (unsigned char)__c2;}
static
int compare(const char_type* __s1, const char_type* __s2, size_t __n) throw();
static inline size_t
length(const char_type* __s) throw() {return __builtin_strlen(__s);}
static
const char_type* find(const char_type* __s, size_t __n, const char_type& __a) throw();
static inline char_type* move(char_type* __s1, const char_type* __s2, size_t __n) throw()
{return __n == 0 ? __s1 : (char_type*) memmove(__s1, __s2, __n);}
static inline char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) throw()
{
((void)0);
return __n == 0 ? __s1 : (char_type*)memcpy(__s1, __s2, __n);
}
static inline char_type* assign(char_type* __s, size_t __n, char_type __a) throw()
{return __n == 0 ? __s : (char_type*)memset(__s, to_int_type(__a), __n);}
static inline int_type not_eof(int_type __c) throw()
{return eq_int_type(__c, eof()) ? ~eof() : __c;}
static inline char_type to_char_type(int_type __c) throw()
{return char_type(__c);}
static inline int_type to_int_type(char_type __c) throw()
{return int_type((unsigned char)__c);}
static inline bool eq_int_type(int_type __c1, int_type __c2) throw()
{return __c1 == __c2;}
static inline int_type eof() throw()
{return int_type((-1));}
};
inline
int
char_traits<char>::compare(const char_type* __s1, const char_type* __s2, size_t __n) throw()
{
if (__n == 0)
return 0;
return memcmp(__s1, __s2, __n);
# 262 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 3
}
inline
const char*
char_traits<char>::find(const char_type* __s, size_t __n, const char_type& __a) throw()
{
if (__n == 0)
return __null;
return (const char_type*) memchr(__s, to_int_type(__a), __n);
# 283 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 3
}
template <>
struct __attribute__ ((__type_visibility__("default"))) char_traits<wchar_t>
{
typedef wchar_t char_type;
typedef wint_t int_type;
typedef streamoff off_type;
typedef streampos pos_type;
typedef mbstate_t state_type;
static inline
void assign(char_type& __c1, const char_type& __c2) throw() {__c1 = __c2;}
static inline bool eq(char_type __c1, char_type __c2) throw()
{return __c1 == __c2;}
static inline bool lt(char_type __c1, char_type __c2) throw()
{return __c1 < __c2;}
static
int compare(const char_type* __s1, const char_type* __s2, size_t __n) throw();
static
size_t length(const char_type* __s) throw();
static
const char_type* find(const char_type* __s, size_t __n, const char_type& __a) throw();
static inline char_type* move(char_type* __s1, const char_type* __s2, size_t __n) throw()
{return __n == 0 ? __s1 : (char_type*)wmemmove(__s1, __s2, __n);}
static inline char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) throw()
{
((void)0);
return __n == 0 ? __s1 : (char_type*)wmemcpy(__s1, __s2, __n);
}
static inline char_type* assign(char_type* __s, size_t __n, char_type __a) throw()
{return __n == 0 ? __s : (char_type*)wmemset(__s, __a, __n);}
static inline int_type not_eof(int_type __c) throw()
{return eq_int_type(__c, eof()) ? ~eof() : __c;}
static inline char_type to_char_type(int_type __c) throw()
{return char_type(__c);}
static inline int_type to_int_type(char_type __c) throw()
{return int_type(__c);}
static inline bool eq_int_type(int_type __c1, int_type __c2) throw()
{return __c1 == __c2;}
static inline int_type eof() throw()
{return int_type(((__darwin_wint_t)-1));}
};
inline
int
char_traits<wchar_t>::compare(const char_type* __s1, const char_type* __s2, size_t __n) throw()
{
if (__n == 0)
return 0;
return wmemcmp(__s1, __s2, __n);
# 352 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 3
}
inline
size_t
char_traits<wchar_t>::length(const char_type* __s) throw()
{
return wcslen(__s);
}
inline
const wchar_t*
char_traits<wchar_t>::find(const char_type* __s, size_t __n, const char_type& __a) throw()
{
if (__n == 0)
return __null;
return wmemchr(__s, __a, __n);
# 389 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__string" 3
}
template <>
struct __attribute__ ((__type_visibility__("default"))) char_traits<char16_t>
{
typedef char16_t char_type;
typedef uint_least16_t int_type;
typedef streamoff off_type;
typedef u16streampos pos_type;
typedef mbstate_t state_type;
static inline
void assign(char_type& __c1, const char_type& __c2) throw() {__c1 = __c2;}
static inline bool eq(char_type __c1, char_type __c2) throw()
{return __c1 == __c2;}
static inline bool lt(char_type __c1, char_type __c2) throw()
{return __c1 < __c2;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
int compare(const char_type* __s1, const char_type* __s2, size_t __n) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
size_t length(const char_type* __s) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
const char_type* find(const char_type* __s, size_t __n, const char_type& __a) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* move(char_type* __s1, const char_type* __s2, size_t __n) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* assign(char_type* __s, size_t __n, char_type __a) throw();
static inline int_type not_eof(int_type __c) throw()
{return eq_int_type(__c, eof()) ? ~eof() : __c;}
static inline char_type to_char_type(int_type __c) throw()
{return char_type(__c);}
static inline int_type to_int_type(char_type __c) throw()
{return int_type(__c);}
static inline bool eq_int_type(int_type __c1, int_type __c2) throw()
{return __c1 == __c2;}
static inline int_type eof() throw()
{return int_type(0xFFFF);}
};
inline
int
char_traits<char16_t>::compare(const char_type* __s1, const char_type* __s2, size_t __n) throw()
{
for (; __n; --__n, ++__s1, ++__s2)
{
if (lt(*__s1, *__s2))
return -1;
if (lt(*__s2, *__s1))
return 1;
}
return 0;
}
inline
size_t
char_traits<char16_t>::length(const char_type* __s) throw()
{
size_t __len = 0;
for (; !eq(*__s, char_type(0)); ++__s)
++__len;
return __len;
}
inline
const char16_t*
char_traits<char16_t>::find(const char_type* __s, size_t __n, const char_type& __a) throw()
{
for (; __n; --__n)
{
if (eq(*__s, __a))
return __s;
++__s;
}
return 0;
}
inline
char16_t*
char_traits<char16_t>::move(char_type* __s1, const char_type* __s2, size_t __n) throw()
{
char_type* __r = __s1;
if (__s1 < __s2)
{
for (; __n; --__n, ++__s1, ++__s2)
assign(*__s1, *__s2);
}
else if (__s2 < __s1)
{
__s1 += __n;
__s2 += __n;
for (; __n; --__n)
assign(*--__s1, *--__s2);
}
return __r;
}
inline
char16_t*
char_traits<char16_t>::copy(char_type* __s1, const char_type* __s2, size_t __n) throw()
{
((void)0);
char_type* __r = __s1;
for (; __n; --__n, ++__s1, ++__s2)
assign(*__s1, *__s2);
return __r;
}
inline
char16_t*
char_traits<char16_t>::assign(char_type* __s, size_t __n, char_type __a) throw()
{
char_type* __r = __s;
for (; __n; --__n, ++__s)
assign(*__s, __a);
return __r;
}
template <>
struct __attribute__ ((__type_visibility__("default"))) char_traits<char32_t>
{
typedef char32_t char_type;
typedef uint_least32_t int_type;
typedef streamoff off_type;
typedef u32streampos pos_type;
typedef mbstate_t state_type;
static inline
void assign(char_type& __c1, const char_type& __c2) throw() {__c1 = __c2;}
static inline bool eq(char_type __c1, char_type __c2) throw()
{return __c1 == __c2;}
static inline bool lt(char_type __c1, char_type __c2) throw()
{return __c1 < __c2;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
int compare(const char_type* __s1, const char_type* __s2, size_t __n) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
size_t length(const char_type* __s) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) static
const char_type* find(const char_type* __s, size_t __n, const char_type& __a) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* move(char_type* __s1, const char_type* __s2, size_t __n) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
static char_type* assign(char_type* __s, size_t __n, char_type __a) throw();
static inline int_type not_eof(int_type __c) throw()
{return eq_int_type(__c, eof()) ? ~eof() : __c;}
static inline char_type to_char_type(int_type __c) throw()
{return char_type(__c);}
static inline int_type to_int_type(char_type __c) throw()
{return int_type(__c);}
static inline bool eq_int_type(int_type __c1, int_type __c2) throw()
{return __c1 == __c2;}
static inline int_type eof() throw()
{return int_type(0xFFFFFFFF);}
};
inline
int
char_traits<char32_t>::compare(const char_type* __s1, const char_type* __s2, size_t __n) throw()
{
for (; __n; --__n, ++__s1, ++__s2)
{
if (lt(*__s1, *__s2))
return -1;
if (lt(*__s2, *__s1))
return 1;
}
return 0;
}
inline
size_t
char_traits<char32_t>::length(const char_type* __s) throw()
{
size_t __len = 0;
for (; !eq(*__s, char_type(0)); ++__s)
++__len;
return __len;
}
inline
const char32_t*
char_traits<char32_t>::find(const char_type* __s, size_t __n, const char_type& __a) throw()
{
for (; __n; --__n)
{
if (eq(*__s, __a))
return __s;
++__s;
}
return 0;
}
inline
char32_t*
char_traits<char32_t>::move(char_type* __s1, const char_type* __s2, size_t __n) throw()
{
char_type* __r = __s1;
if (__s1 < __s2)
{
for (; __n; --__n, ++__s1, ++__s2)
assign(*__s1, *__s2);
}
else if (__s2 < __s1)
{
__s1 += __n;
__s2 += __n;
for (; __n; --__n)
assign(*--__s1, *--__s2);
}
return __r;
}
inline
char32_t*
char_traits<char32_t>::copy(char_type* __s1, const char_type* __s2, size_t __n) throw()
{
((void)0);
char_type* __r = __s1;
for (; __n; --__n, ++__s1, ++__s2)
assign(*__s1, *__s2);
return __r;
}
inline
char32_t*
char_traits<char32_t>::assign(char_type* __s, size_t __n, char_type __a) throw()
{
char_type* __r = __s;
for (; __n; --__n, ++__s)
assign(*__s, __a);
return __r;
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find(const _CharT *__p, _SizeT __sz,
_CharT __c, _SizeT __pos) throw()
{
if (__pos >= __sz)
return __npos;
const _CharT* __r = _Traits::find(__p + __pos, __sz - __pos, __c);
if (__r == 0)
return __npos;
return static_cast<_SizeT>(__r - __p);
}
template <class _CharT, class _Traits>
inline const _CharT *
__search_substring(const _CharT *__first1, const _CharT *__last1,
const _CharT *__first2, const _CharT *__last2) {
const ptrdiff_t __len2 = __last2 - __first2;
if (__len2 == 0)
return __first1;
ptrdiff_t __len1 = __last1 - __first1;
if (__len1 < __len2)
return __last1;
_CharT __f2 = *__first2;
while (true) {
__len1 = __last1 - __first1;
if (__len1 < __len2)
return __last1;
__first1 = _Traits::find(__first1, __len1 - __len2 + 1, __f2);
if (__first1 == 0)
return __last1;
if (_Traits::compare(__first1, __first2, __len2) == 0)
return __first1;
++__first1;
}
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find(const _CharT *__p, _SizeT __sz,
const _CharT* __s, _SizeT __pos, _SizeT __n) throw()
{
if (__pos > __sz)
return __npos;
if (__n == 0)
return __pos;
const _CharT *__r = __search_substring<_CharT, _Traits>(
__p + __pos, __p + __sz, __s, __s + __n);
if (__r == __p + __sz)
return __npos;
return static_cast<_SizeT>(__r - __p);
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_rfind(const _CharT *__p, _SizeT __sz,
_CharT __c, _SizeT __pos) throw()
{
if (__sz < 1)
return __npos;
if (__pos < __sz)
++__pos;
else
__pos = __sz;
for (const _CharT* __ps = __p + __pos; __ps != __p;)
{
if (_Traits::eq(*--__ps, __c))
return static_cast<_SizeT>(__ps - __p);
}
return __npos;
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_rfind(const _CharT *__p, _SizeT __sz,
const _CharT* __s, _SizeT __pos, _SizeT __n) throw()
{
__pos = std::__1::min(__pos, __sz);
if (__n < __sz - __pos)
__pos += __n;
else
__pos = __sz;
const _CharT* __r = std::__1::__find_end(
__p, __p + __pos, __s, __s + __n, _Traits::eq,
random_access_iterator_tag(), random_access_iterator_tag());
if (__n > 0 && __r == __p + __pos)
return __npos;
return static_cast<_SizeT>(__r - __p);
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find_first_of(const _CharT *__p, _SizeT __sz,
const _CharT* __s, _SizeT __pos, _SizeT __n) throw()
{
if (__pos >= __sz || __n == 0)
return __npos;
const _CharT* __r = std::__1::__find_first_of_ce
(__p + __pos, __p + __sz, __s, __s + __n, _Traits::eq );
if (__r == __p + __sz)
return __npos;
return static_cast<_SizeT>(__r - __p);
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find_last_of(const _CharT *__p, _SizeT __sz,
const _CharT* __s, _SizeT __pos, _SizeT __n) throw()
{
if (__n != 0)
{
if (__pos < __sz)
++__pos;
else
__pos = __sz;
for (const _CharT* __ps = __p + __pos; __ps != __p;)
{
const _CharT* __r = _Traits::find(__s, __n, *--__ps);
if (__r)
return static_cast<_SizeT>(__ps - __p);
}
}
return __npos;
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find_first_not_of(const _CharT *__p, _SizeT __sz,
const _CharT* __s, _SizeT __pos, _SizeT __n) throw()
{
if (__pos < __sz)
{
const _CharT* __pe = __p + __sz;
for (const _CharT* __ps = __p + __pos; __ps != __pe; ++__ps)
if (_Traits::find(__s, __n, *__ps) == 0)
return static_cast<_SizeT>(__ps - __p);
}
return __npos;
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find_first_not_of(const _CharT *__p, _SizeT __sz,
_CharT __c, _SizeT __pos) throw()
{
if (__pos < __sz)
{
const _CharT* __pe = __p + __sz;
for (const _CharT* __ps = __p + __pos; __ps != __pe; ++__ps)
if (!_Traits::eq(*__ps, __c))
return static_cast<_SizeT>(__ps - __p);
}
return __npos;
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find_last_not_of(const _CharT *__p, _SizeT __sz,
const _CharT* __s, _SizeT __pos, _SizeT __n) throw()
{
if (__pos < __sz)
++__pos;
else
__pos = __sz;
for (const _CharT* __ps = __p + __pos; __ps != __p;)
if (_Traits::find(__s, __n, *--__ps) == 0)
return static_cast<_SizeT>(__ps - __p);
return __npos;
}
template<class _CharT, class _SizeT, class _Traits, _SizeT __npos>
inline _SizeT __attribute__ ((__visibility__("hidden"), __always_inline__))
__str_find_last_not_of(const _CharT *__p, _SizeT __sz,
_CharT __c, _SizeT __pos) throw()
{
if (__pos < __sz)
++__pos;
else
__pos = __sz;
for (const _CharT* __ps = __p + __pos; __ps != __p;)
if (!_Traits::eq(*--__ps, __c))
return static_cast<_SizeT>(__ps - __p);
return __npos;
}
template<class _Ptr>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
size_t __do_string_hash(_Ptr __p, _Ptr __e)
{
typedef typename iterator_traits<_Ptr>::value_type value_type;
return __murmur2_or_cityhash<size_t>()(__p, (__e-__p)*sizeof(value_type));
}
template <class _CharT, class _Iter, class _Traits=char_traits<_CharT> >
struct __quoted_output_proxy
{
_Iter __first;
_Iter __last;
_CharT __delim;
_CharT __escape;
__quoted_output_proxy(_Iter __f, _Iter __l, _CharT __d, _CharT __e)
: __first(__f), __last(__l), __delim(__d), __escape(__e) {}
};
} }
# 177 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 2 3
# 185 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 189 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 2 3
namespace std {inline namespace __1 {
template<class _CharT, class _Traits = char_traits<_CharT> >
class __attribute__ ((__type_visibility__("default"))) basic_string_view {
public:
typedef _Traits traits_type;
typedef _CharT value_type;
typedef _CharT* pointer;
typedef const _CharT* const_pointer;
typedef _CharT& reference;
typedef const _CharT& const_reference;
typedef const_pointer const_iterator;
typedef const_iterator iterator;
typedef std::__1::reverse_iterator<const_iterator> const_reverse_iterator;
typedef const_reverse_iterator reverse_iterator;
typedef size_t size_type;
typedef ptrdiff_t difference_type;
static const size_type npos = -1;
_Static_assert(is_pod<value_type>::value, "Character type of basic_string_view must be a POD");
_Static_assert((is_same<_CharT, typename traits_type::char_type>::value), "traits_type::char_type must be the same type as CharT");
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string_view() throw() : __data (std::__1::__get_nullptr_t()), __size(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string_view(const basic_string_view&) throw() = default;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string_view& operator=(const basic_string_view&) throw() = default;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string_view(const _CharT* __s, size_type __len) throw()
: __data(__s), __size(__len)
{
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string_view(const _CharT* __s)
: __data(__s), __size(_Traits::length(__s)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator begin() const throw() { return cbegin(); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator end() const throw() { return cend(); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator cbegin() const throw() { return __data; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator cend() const throw() { return __data + __size; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator rbegin() const throw() { return const_reverse_iterator(cend()); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator rend() const throw() { return const_reverse_iterator(cbegin()); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator crbegin() const throw() { return const_reverse_iterator(cend()); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator crend() const throw() { return const_reverse_iterator(cbegin()); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type size() const throw() { return __size; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type length() const throw() { return __size; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type max_size() const throw() { return numeric_limits<size_type>::max(); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool empty() const throw() { return __size == 0; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference operator[](size_type __pos) const throw() { return __data[__pos]; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference at(size_type __pos) const
{
return __pos >= size()
? (__throw_out_of_range("string_view::at"), __data[0])
: __data[__pos];
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference front() const
{
return ((void)0), __data[0];
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference back() const
{
return ((void)0), __data[__size-1];
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_pointer data() const throw() { return __data; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
void remove_prefix(size_type __n) throw()
{
((void)0);
__data += __n;
__size -= __n;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void remove_suffix(size_type __n) throw()
{
((void)0);
__size -= __n;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(basic_string_view& __other) throw()
{
const value_type *__p = __data;
__data = __other.__data;
__other.__data = __p;
size_type __sz = __size;
__size = __other.__size;
__other.__size = __sz;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type copy(_CharT* __s, size_type __n, size_type __pos = 0) const
{
if (__pos > size())
__throw_out_of_range("string_view::copy");
size_type __rlen = std::__1::min(__n, size() - __pos);
_Traits::copy(__s, data() + __pos, __rlen);
return __rlen;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string_view substr(size_type __pos = 0, size_type __n = npos) const
{
return __pos > size()
? (__throw_out_of_range("string_view::substr"), basic_string_view())
: basic_string_view(data() + __pos, std::__1::min(__n, size() - __pos));
}
int compare(basic_string_view __sv) const throw()
{
size_type __rlen = std::__1::min( size(), __sv.size());
int __retval = _Traits::compare(data(), __sv.data(), __rlen);
if ( __retval == 0 )
__retval = size() == __sv.size() ? 0 : ( size() < __sv.size() ? -1 : 1 );
return __retval;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(size_type __pos1, size_type __n1, basic_string_view __sv) const
{
return substr(__pos1, __n1).compare(__sv);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare( size_type __pos1, size_type __n1,
basic_string_view __sv, size_type __pos2, size_type __n2) const
{
return substr(__pos1, __n1).compare(__sv.substr(__pos2, __n2));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(const _CharT* __s) const throw()
{
return compare(basic_string_view(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(size_type __pos1, size_type __n1, const _CharT* __s) const
{
return substr(__pos1, __n1).compare(basic_string_view(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(size_type __pos1, size_type __n1, const _CharT* __s, size_type __n2) const
{
return substr(__pos1, __n1).compare(basic_string_view(__s, __n2));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(basic_string_view __s, size_type __pos = 0) const throw()
{
((void)0);
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __s.data(), __pos, __s.size());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(_CharT __c, size_type __pos = 0) const throw()
{
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(const _CharT* __s, size_type __pos, size_type __n) const
{
((void)0);
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(const _CharT* __s, size_type __pos = 0) const
{
((void)0);
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(basic_string_view __s, size_type __pos = npos) const throw()
{
((void)0);
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __s.data(), __pos, __s.size());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(_CharT __c, size_type __pos = npos) const throw()
{
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(const _CharT* __s, size_type __pos, size_type __n) const
{
((void)0);
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(const _CharT* __s, size_type __pos=npos) const
{
((void)0);
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(basic_string_view __s, size_type __pos = 0) const throw()
{
((void)0);
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __s.data(), __pos, __s.size());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(_CharT __c, size_type __pos = 0) const throw()
{ return find(__c, __pos); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(const _CharT* __s, size_type __pos, size_type __n) const
{
((void)0);
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(const _CharT* __s, size_type __pos=0) const
{
((void)0);
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(basic_string_view __s, size_type __pos=npos) const throw()
{
((void)0);
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __s.data(), __pos, __s.size());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(_CharT __c, size_type __pos = npos) const throw()
{ return rfind(__c, __pos); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(const _CharT* __s, size_type __pos, size_type __n) const
{
((void)0);
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(const _CharT* __s, size_type __pos=npos) const
{
((void)0);
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(basic_string_view __s, size_type __pos=0) const throw()
{
((void)0);
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s.data(), __pos, __s.size());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(_CharT __c, size_type __pos=0) const throw()
{
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(const _CharT* __s, size_type __pos, size_type __n) const
{
((void)0);
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(const _CharT* __s, size_type __pos=0) const
{
((void)0);
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(basic_string_view __s, size_type __pos=npos) const throw()
{
((void)0);
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s.data(), __pos, __s.size());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(_CharT __c, size_type __pos=npos) const throw()
{
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(const _CharT* __s, size_type __pos, size_type __n) const
{
((void)0);
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(const _CharT* __s, size_type __pos=npos) const
{
((void)0);
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
# 601 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 3
private:
const value_type* __data;
size_type __size;
};
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(basic_string_view<_CharT, _Traits> __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
if ( __lhs.size() != __rhs.size()) return false;
return __lhs.compare(__rhs) == 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(basic_string_view<_CharT, _Traits> __lhs,
typename common_type<basic_string_view<_CharT, _Traits> >::type __rhs) throw()
{
if ( __lhs.size() != __rhs.size()) return false;
return __lhs.compare(__rhs) == 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(typename common_type<basic_string_view<_CharT, _Traits> >::type __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
if ( __lhs.size() != __rhs.size()) return false;
return __lhs.compare(__rhs) == 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(basic_string_view<_CharT, _Traits> __lhs, basic_string_view<_CharT, _Traits> __rhs) throw()
{
if ( __lhs.size() != __rhs.size())
return true;
return __lhs.compare(__rhs) != 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(basic_string_view<_CharT, _Traits> __lhs,
typename common_type<basic_string_view<_CharT, _Traits> >::type __rhs) throw()
{
if ( __lhs.size() != __rhs.size())
return true;
return __lhs.compare(__rhs) != 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(typename common_type<basic_string_view<_CharT, _Traits> >::type __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
if ( __lhs.size() != __rhs.size())
return true;
return __lhs.compare(__rhs) != 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator<(basic_string_view<_CharT, _Traits> __lhs, basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator<(basic_string_view<_CharT, _Traits> __lhs,
typename common_type<basic_string_view<_CharT, _Traits> >::type __rhs) throw()
{
return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator<(typename common_type<basic_string_view<_CharT, _Traits> >::type __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator> (basic_string_view<_CharT, _Traits> __lhs, basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) > 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator>(basic_string_view<_CharT, _Traits> __lhs,
typename common_type<basic_string_view<_CharT, _Traits> >::type __rhs) throw()
{
return __lhs.compare(__rhs) > 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator>(typename common_type<basic_string_view<_CharT, _Traits> >::type __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) > 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator<=(basic_string_view<_CharT, _Traits> __lhs, basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) <= 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator<=(basic_string_view<_CharT, _Traits> __lhs,
typename common_type<basic_string_view<_CharT, _Traits> >::type __rhs) throw()
{
return __lhs.compare(__rhs) <= 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator<=(typename common_type<basic_string_view<_CharT, _Traits> >::type __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) <= 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator>=(basic_string_view<_CharT, _Traits> __lhs, basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) >= 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator>=(basic_string_view<_CharT, _Traits> __lhs,
typename common_type<basic_string_view<_CharT, _Traits> >::type __rhs) throw()
{
return __lhs.compare(__rhs) >= 0;
}
template<class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator>=(typename common_type<basic_string_view<_CharT, _Traits> >::type __lhs,
basic_string_view<_CharT, _Traits> __rhs) throw()
{
return __lhs.compare(__rhs) >= 0;
}
typedef basic_string_view<char> string_view;
typedef basic_string_view<char16_t> u16string_view;
typedef basic_string_view<char32_t> u32string_view;
typedef basic_string_view<wchar_t> wstring_view;
template<class _CharT, class _Traits>
struct __attribute__ ((__type_visibility__("default"))) hash<basic_string_view<_CharT, _Traits> >
: public unary_function<basic_string_view<_CharT, _Traits>, size_t>
{
size_t operator()(const basic_string_view<_CharT, _Traits> __val) const throw();
};
template<class _CharT, class _Traits>
size_t
hash<basic_string_view<_CharT, _Traits> >::operator()(
const basic_string_view<_CharT, _Traits> __val) const throw()
{
return __do_string_hash(__val.data(), __val.data() + __val.size());
}
# 821 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string_view" 3
} }
# 478 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwchar" 1 3
# 107 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwchar" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwctype" 1 3
# 54 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwctype" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cctype" 1 3
# 43 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cctype" 3
namespace std {inline namespace __1 {
# 104 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cctype" 3
using ::isalnum;
using ::isalpha;
using ::isblank;
using ::iscntrl;
using ::isdigit;
using ::isgraph;
using ::islower;
using ::isprint;
using ::ispunct;
using ::isspace;
using ::isupper;
using ::isxdigit;
using ::tolower;
using ::toupper;
} }
# 55 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwctype" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wctype.h" 1 3
# 52 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wctype.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wctype.h" 1 3 4
# 36 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wctype.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_wctrans_t.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_wctrans_t.h" 3 4
typedef __darwin_wctrans_t wctrans_t;
# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wctype.h" 2 3 4
# 49 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wctype.h" 3 4
inline int
iswblank(wint_t _wc)
{
return (__istype(_wc, 0x00020000L));
}
inline int
iswascii(wint_t _wc)
{
return ((_wc & ~0x7F) == 0);
}
inline int
iswhexnumber(wint_t _wc)
{
return (__istype(_wc, 0x00010000L));
}
inline int
iswideogram(wint_t _wc)
{
return (__istype(_wc, 0x00080000L));
}
inline int
iswnumber(wint_t _wc)
{
return (__istype(_wc, 0x00000400L));
}
inline int
iswphonogram(wint_t _wc)
{
return (__istype(_wc, 0x00200000L));
}
inline int
iswrune(wint_t _wc)
{
return (__istype(_wc, 0xFFFFFFF0L));
}
inline int
iswspecial(wint_t _wc)
{
return (__istype(_wc, 0x00100000L));
}
# 117 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/wctype.h" 3 4
extern "C" {
wint_t nextwctype(wint_t, wctype_t);
wint_t towctrans(wint_t, wctrans_t);
wctrans_t
wctrans(const char *);
}
# 55 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wctype.h" 2 3
# 56 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwctype" 2 3
# 59 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwctype" 3
namespace std {inline namespace __1 {
using ::wint_t;
using ::wctrans_t;
using ::wctype_t;
using ::iswalnum;
using ::iswalpha;
using ::iswblank;
using ::iswcntrl;
using ::iswdigit;
using ::iswgraph;
using ::iswlower;
using ::iswprint;
using ::iswpunct;
using ::iswspace;
using ::iswupper;
using ::iswxdigit;
using ::iswctype;
using ::wctype;
using ::towlower;
using ::towupper;
using ::towctrans;
using ::wctrans;
} }
# 108 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwchar" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/wchar.h" 1 3
# 109 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwchar" 2 3
# 112 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cwchar" 3
namespace std {inline namespace __1 {
using ::mbstate_t;
using ::size_t;
using ::tm;
using ::wint_t;
using ::FILE;
using ::fwprintf;
using ::fwscanf;
using ::swprintf;
using ::vfwprintf;
using ::vswprintf;
using ::swscanf;
using ::vfwscanf;
using ::vswscanf;
using ::fgetwc;
using ::fgetws;
using ::fputwc;
using ::fputws;
using ::fwide;
using ::getwc;
using ::putwc;
using ::ungetwc;
using ::wcstod;
using ::wcstof;
using ::wcstold;
using ::wcstol;
using ::wcstoll;
using ::wcstoul;
using ::wcstoull;
using ::wcscpy;
using ::wcsncpy;
using ::wcscat;
using ::wcsncat;
using ::wcscmp;
using ::wcscoll;
using ::wcsncmp;
using ::wcsxfrm;
using ::wcschr;
using ::wcspbrk;
using ::wcsrchr;
using ::wcsstr;
using ::wmemchr;
using ::wcscspn;
using ::wcslen;
using ::wcsspn;
using ::wcstok;
using ::wmemcmp;
using ::wmemcpy;
using ::wmemmove;
using ::wmemset;
using ::wcsftime;
using ::btowc;
using ::wctob;
using ::mbsinit;
using ::mbrlen;
using ::mbrtowc;
using ::wcrtomb;
using ::mbsrtowcs;
using ::wcsrtombs;
using ::getwchar;
using ::vwscanf;
using ::wscanf;
using ::putwchar;
using ::vwprintf;
using ::wprintf;
} }
# 482 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 2 3
# 498 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 502 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 2 3
namespace std {inline namespace __1 {
template <class _StateT>
class __attribute__ ((__type_visibility__("default"))) fpos
{
private:
_StateT __st_;
streamoff __off_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) fpos(streamoff __off = streamoff()) : __st_(), __off_(__off) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator streamoff() const {return __off_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _StateT state() const {return __st_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void state(_StateT __st) {__st_ = __st;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) fpos& operator+=(streamoff __off) {__off_ += __off; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) fpos operator+ (streamoff __off) const {fpos __t(*this); __t += __off; return __t;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) fpos& operator-=(streamoff __off) {__off_ -= __off; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) fpos operator- (streamoff __off) const {fpos __t(*this); __t -= __off; return __t;}
};
template <class _StateT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
streamoff operator-(const fpos<_StateT>& __x, const fpos<_StateT>& __y)
{return streamoff(__x) - streamoff(__y);}
template <class _StateT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const fpos<_StateT>& __x, const fpos<_StateT>& __y)
{return streamoff(__x) == streamoff(__y);}
template <class _StateT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const fpos<_StateT>& __x, const fpos<_StateT>& __y)
{return streamoff(__x) != streamoff(__y);}
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const basic_string<_CharT, _Traits, _Allocator>& __x,
const basic_string<_CharT, _Traits, _Allocator>& __y);
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const _CharT* __x, const basic_string<_CharT,_Traits,_Allocator>& __y);
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(_CharT __x, const basic_string<_CharT,_Traits,_Allocator>& __y);
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const basic_string<_CharT, _Traits, _Allocator>& __x, const _CharT* __y);
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const basic_string<_CharT, _Traits, _Allocator>& __x, _CharT __y);
extern template __attribute__ ((__visibility__("default"))) string operator+<char, char_traits<char>, allocator<char> >(char const*, string const&);
template <bool>
class __attribute__ ((__type_visibility__("default"))) __basic_string_common
{
protected:
__attribute__ ((noreturn)) void __throw_length_error() const;
__attribute__ ((noreturn)) void __throw_out_of_range() const;
};
template <bool __b>
void
__basic_string_common<__b>::__throw_length_error() const
{
std::__1::__throw_length_error("basic_string");
}
template <bool __b>
void
__basic_string_common<__b>::__throw_out_of_range() const
{
std::__1::__throw_out_of_range("basic_string");
}
extern template class __attribute__ ((__visibility__("default"))) __basic_string_common<true>;
template <class _Iter>
struct __libcpp_string_gets_noexcept_iterator_impl : public false_type {};
# 612 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
template <class _Iter>
struct __libcpp_string_gets_noexcept_iterator
: public integral_constant<bool,(__libcpp_is_trivial_iterator<_Iter>::value || __libcpp_string_gets_noexcept_iterator_impl<_Iter>::value)> {};
template <class _CharT, class _Traits, class _Tp>
struct __can_be_converted_to_string_view : public integral_constant<bool,(( is_convertible<const _Tp&, basic_string_view<_CharT, _Traits> >::value && !is_convertible<const _Tp&, const _CharT*>::value))> {};
# 636 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
template<class _CharT, class _Traits, class _Allocator>
class __attribute__ ((__type_visibility__("default"))) basic_string
: private __basic_string_common<true>
{
public:
typedef basic_string __self;
typedef basic_string_view<_CharT, _Traits> __self_view;
typedef _Traits traits_type;
typedef _CharT value_type;
typedef _Allocator allocator_type;
typedef allocator_traits<allocator_type> __alloc_traits;
typedef typename __alloc_traits::size_type size_type;
typedef typename __alloc_traits::difference_type difference_type;
typedef value_type& reference;
typedef const value_type& const_reference;
typedef typename __alloc_traits::pointer pointer;
typedef typename __alloc_traits::const_pointer const_pointer;
_Static_assert(is_pod<value_type>::value, "Character type of basic_string must be a POD");
_Static_assert((is_same<_CharT, typename traits_type::char_type>::value), "traits_type::char_type must be the same type as CharT");
_Static_assert((is_same<typename allocator_type::value_type, value_type>::value), "Allocator::value_type must be same type as value_type");
typedef __wrap_iter<pointer> iterator;
typedef __wrap_iter<const_pointer> const_iterator;
typedef std::__1::reverse_iterator<iterator> reverse_iterator;
typedef std::__1::reverse_iterator<const_iterator> const_reverse_iterator;
private:
# 703 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
struct __long
{
size_type __cap_;
size_type __size_;
pointer __data_;
};
static const size_type __short_mask = 0x01;
static const size_type __long_mask = 0x1ul;
enum {__min_cap = (sizeof(__long) - 1)/sizeof(value_type) > 2 ?
(sizeof(__long) - 1)/sizeof(value_type) : 2};
struct __short
{
union
{
unsigned char __size_;
value_type __lx;
};
value_type __data_[__min_cap];
};
union __ulx{__long __lx; __short __lxx;};
enum {__n_words = sizeof(__ulx) / sizeof(size_type)};
struct __raw
{
size_type __words[__n_words];
};
struct __rep
{
union
{
__long __l;
__short __s;
__raw __r;
};
};
__compressed_pair<__rep, allocator_type> __r_;
public:
static const size_type npos = -1;
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string()
;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit basic_string(const allocator_type& __a)
;
basic_string(const basic_string& __str);
basic_string(const basic_string& __str, const allocator_type& __a);
# 782 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string(const _CharT* __s);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(const _CharT* __s, const _Allocator& __a);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(const _CharT* __s, size_type __n);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(const _CharT* __s, size_type __n, const _Allocator& __a);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(size_type __n, _CharT __c);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(size_type __n, _CharT __c, const _Allocator& __a);
basic_string(const basic_string& __str, size_type __pos, size_type __n,
const _Allocator& __a = _Allocator());
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(const basic_string& __str, size_type __pos,
const _Allocator& __a = _Allocator());
template<class _Tp>
inline __attribute__ ((__visibility__("hidden")))
basic_string(const _Tp& __t, size_type __pos, size_type __n,
const allocator_type& __a = allocator_type(),
typename enable_if<__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value, void>::type* = 0);
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit
basic_string(__self_view __sv);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(__self_view __sv, const _Allocator& __a);
template<class _InputIterator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(_InputIterator __first, _InputIterator __last);
template<class _InputIterator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string(_InputIterator __first, _InputIterator __last, const allocator_type& __a);
inline ~basic_string();
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator __self_view() const throw() { return __self_view(data(), size()); }
basic_string& operator=(const basic_string& __str);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& operator=(__self_view __sv) {return assign(__sv);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string& operator=(const value_type* __s) {return assign(__s);}
basic_string& operator=(value_type __c);
# 856 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
iterator begin() throw()
{return iterator(__get_pointer());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator begin() const throw()
{return const_iterator(__get_pointer());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iterator end() throw()
{return iterator(__get_pointer() + size());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator end() const throw()
{return const_iterator(__get_pointer() + size());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator rbegin() throw()
{return reverse_iterator(end());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator rbegin() const throw()
{return const_reverse_iterator(end());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
reverse_iterator rend() throw()
{return reverse_iterator(begin());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator rend() const throw()
{return const_reverse_iterator(begin());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator cbegin() const throw()
{return begin();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_iterator cend() const throw()
{return end();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator crbegin() const throw()
{return rbegin();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reverse_iterator crend() const throw()
{return rend();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_type size() const throw()
{return __is_long() ? __get_long_size() : __get_short_size();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_type length() const throw() {return size();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_type max_size() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_type capacity() const throw()
{return (__is_long() ? __get_long_cap()
: static_cast<size_type>(__min_cap)) - 1;}
void resize(size_type __n, value_type __c);
__attribute__ ((__visibility__("hidden"), __always_inline__)) void resize(size_type __n) {resize(__n, value_type());}
void reserve(size_type __res_arg = 0);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void shrink_to_fit() throw() {reserve();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void clear() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool empty() const throw() {return size() == 0;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_reference operator[](size_type __pos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference operator[](size_type __pos) throw();
const_reference at(size_type __n) const;
reference at(size_type __n);
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string& operator+=(const basic_string& __str) {return append(__str);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string& operator+=(__self_view __sv) {return append(__sv);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string& operator+=(const value_type* __s) {return append(__s);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) basic_string& operator+=(value_type __c) {push_back(__c); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& append(const basic_string& __str);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& append(__self_view __sv) { return append(__sv.data(), __sv.size()); }
basic_string& append(const basic_string& __str, size_type __pos, size_type __n=npos);
template <class _Tp>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string&
>::type
append(const _Tp& __t, size_type __pos, size_type __n=npos);
basic_string& append(const value_type* __s, size_type __n);
basic_string& append(const value_type* __s);
basic_string& append(size_type __n, value_type __c);
template <class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden")))
basic_string& __append_forward_unsafe(_ForwardIterator, _ForwardIterator);
template<class _InputIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_exactly_input_iterator<_InputIterator>::value
|| !__libcpp_string_gets_noexcept_iterator<_InputIterator>::value,
basic_string&
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
append(_InputIterator __first, _InputIterator __last) {
const basic_string __temp (__first, __last, __alloc());
append(__temp.data(), __temp.size());
return *this;
}
template<class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value
&& __libcpp_string_gets_noexcept_iterator<_ForwardIterator>::value,
basic_string&
>::type
__attribute__ ((__visibility__("hidden"), __always_inline__))
append(_ForwardIterator __first, _ForwardIterator __last) {
return __append_forward_unsafe(__first, __last);
}
void push_back(value_type __c);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void pop_back();
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference front();
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_reference front() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference back();
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_reference back() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& assign(__self_view __sv) { return assign(__sv.data(), __sv.size()); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& assign(const basic_string& __str) { return *this = __str; }
basic_string& assign(const basic_string& __str, size_type __pos, size_type __n=npos);
template <class _Tp>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string&
>::type
assign(const _Tp & __t, size_type __pos, size_type __n=npos);
basic_string& assign(const value_type* __s, size_type __n);
basic_string& assign(const value_type* __s);
basic_string& assign(size_type __n, value_type __c);
template<class _InputIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_exactly_input_iterator<_InputIterator>::value
|| !__libcpp_string_gets_noexcept_iterator<_InputIterator>::value,
basic_string&
>::type
assign(_InputIterator __first, _InputIterator __last);
template<class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value
&& __libcpp_string_gets_noexcept_iterator<_ForwardIterator>::value,
basic_string&
>::type
assign(_ForwardIterator __first, _ForwardIterator __last);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& insert(size_type __pos1, const basic_string& __str);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& insert(size_type __pos1, __self_view __sv) { return insert(__pos1, __sv.data(), __sv.size()); }
template <class _Tp>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string&
>::type
insert(size_type __pos1, const _Tp& __t, size_type __pos2, size_type __n=npos);
basic_string& insert(size_type __pos1, const basic_string& __str, size_type __pos2, size_type __n=npos);
basic_string& insert(size_type __pos, const value_type* __s, size_type __n);
basic_string& insert(size_type __pos, const value_type* __s);
basic_string& insert(size_type __pos, size_type __n, value_type __c);
iterator insert(const_iterator __pos, value_type __c);
__attribute__ ((__visibility__("hidden"), __always_inline__))
iterator insert(const_iterator __pos, size_type __n, value_type __c);
template<class _InputIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_exactly_input_iterator<_InputIterator>::value
|| !__libcpp_string_gets_noexcept_iterator<_InputIterator>::value,
iterator
>::type
insert(const_iterator __pos, _InputIterator __first, _InputIterator __last);
template<class _ForwardIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value
&& __libcpp_string_gets_noexcept_iterator<_ForwardIterator>::value,
iterator
>::type
insert(const_iterator __pos, _ForwardIterator __first, _ForwardIterator __last);
basic_string& erase(size_type __pos = 0, size_type __n = npos);
__attribute__ ((__visibility__("hidden"), __always_inline__))
iterator erase(const_iterator __pos);
__attribute__ ((__visibility__("hidden"), __always_inline__))
iterator erase(const_iterator __first, const_iterator __last);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(size_type __pos1, size_type __n1, const basic_string& __str);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(size_type __pos1, size_type __n1, __self_view __sv) { return replace(__pos1, __n1, __sv.data(), __sv.size()); }
basic_string& replace(size_type __pos1, size_type __n1, const basic_string& __str, size_type __pos2, size_type __n2=npos);
template <class _Tp>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string&
>::type
replace(size_type __pos1, size_type __n1, const _Tp& __t, size_type __pos2, size_type __n2=npos);
basic_string& replace(size_type __pos, size_type __n1, const value_type* __s, size_type __n2);
basic_string& replace(size_type __pos, size_type __n1, const value_type* __s);
basic_string& replace(size_type __pos, size_type __n1, size_type __n2, value_type __c);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(const_iterator __i1, const_iterator __i2, const basic_string& __str);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(const_iterator __i1, const_iterator __i2, __self_view __sv) { return replace(__i1 - begin(), __i2 - __i1, __sv); }
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(const_iterator __i1, const_iterator __i2, const value_type* __s, size_type __n);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(const_iterator __i1, const_iterator __i2, const value_type* __s);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string& replace(const_iterator __i1, const_iterator __i2, size_type __n, value_type __c);
template<class _InputIterator>
inline __attribute__ ((__visibility__("hidden")))
typename enable_if
<
__is_input_iterator<_InputIterator>::value,
basic_string&
>::type
replace(const_iterator __i1, const_iterator __i2, _InputIterator __j1, _InputIterator __j2);
size_type copy(value_type* __s, size_type __n, size_type __pos = 0) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string substr(size_type __pos = 0, size_type __n = npos) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(basic_string& __str)
;
__attribute__ ((__visibility__("hidden"), __always_inline__))
const value_type* c_str() const throw() {return data();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const value_type* data() const throw() {return std::__1::__to_raw_pointer(__get_pointer());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
allocator_type get_allocator() const throw() {return __alloc();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(const basic_string& __str, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(__self_view __sv, size_type __pos = 0) const throw();
size_type find(const value_type* __s, size_type __pos, size_type __n) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find(const value_type* __s, size_type __pos = 0) const throw();
size_type find(value_type __c, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(const basic_string& __str, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(__self_view __sv, size_type __pos = npos) const throw();
size_type rfind(const value_type* __s, size_type __pos, size_type __n) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type rfind(const value_type* __s, size_type __pos = npos) const throw();
size_type rfind(value_type __c, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(const basic_string& __str, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(__self_view __sv, size_type __pos = 0) const throw();
size_type find_first_of(const value_type* __s, size_type __pos, size_type __n) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(const value_type* __s, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_of(value_type __c, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(const basic_string& __str, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(__self_view __sv, size_type __pos = npos) const throw();
size_type find_last_of(const value_type* __s, size_type __pos, size_type __n) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(const value_type* __s, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_of(value_type __c, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(const basic_string& __str, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(__self_view __sv, size_type __pos = 0) const throw();
size_type find_first_not_of(const value_type* __s, size_type __pos, size_type __n) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(const value_type* __s, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_first_not_of(value_type __c, size_type __pos = 0) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(const basic_string& __str, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(__self_view __sv, size_type __pos = npos) const throw();
size_type find_last_not_of(const value_type* __s, size_type __pos, size_type __n) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(const value_type* __s, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type find_last_not_of(value_type __c, size_type __pos = npos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(const basic_string& __str) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(__self_view __sv) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(size_type __pos1, size_type __n1, __self_view __sv) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(size_type __pos1, size_type __n1, const basic_string& __str) const;
int compare(size_type __pos1, size_type __n1, const basic_string& __str, size_type __pos2, size_type __n2=npos) const;
template <class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
int
>::type
compare(size_type __pos1, size_type __n1, const _Tp& __t, size_type __pos2, size_type __n2=npos) const;
int compare(const value_type* __s) const throw();
int compare(size_type __pos1, size_type __n1, const value_type* __s) const;
int compare(size_type __pos1, size_type __n1, const value_type* __s, size_type __n2) const;
# 1251 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool __invariants() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __is_long() const throw()
{return bool(__r_.first().__s.__size_ & __short_mask);}
# 1266 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
allocator_type& __alloc() throw()
{return __r_.second();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const allocator_type& __alloc() const throw()
{return __r_.second();}
# 1294 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __set_short_size(size_type __s) throw()
{__r_.first().__s.__size_ = (unsigned char)(__s << 1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type __get_short_size() const throw()
{return __r_.first().__s.__size_ >> 1;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __set_long_size(size_type __s) throw()
{__r_.first().__l.__size_ = __s;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type __get_long_size() const throw()
{return __r_.first().__l.__size_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __set_size(size_type __s) throw()
{if (__is_long()) __set_long_size(__s); else __set_short_size(__s);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __set_long_cap(size_type __s) throw()
{__r_.first().__l.__cap_ = __long_mask | __s;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type __get_long_cap() const throw()
{return __r_.first().__l.__cap_ & size_type(~__long_mask);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __set_long_pointer(pointer __p) throw()
{__r_.first().__l.__data_ = __p;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer __get_long_pointer() throw()
{return __r_.first().__l.__data_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_pointer __get_long_pointer() const throw()
{return __r_.first().__l.__data_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer __get_short_pointer() throw()
{return pointer_traits<pointer>::pointer_to(__r_.first().__s.__data_[0]);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_pointer __get_short_pointer() const throw()
{return pointer_traits<const_pointer>::pointer_to(__r_.first().__s.__data_[0]);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
pointer __get_pointer() throw()
{return __is_long() ? __get_long_pointer() : __get_short_pointer();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_pointer __get_pointer() const throw()
{return __is_long() ? __get_long_pointer() : __get_short_pointer();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __zero() throw()
{
size_type (&__a)[__n_words] = __r_.first().__r.__words;
for (unsigned __i = 0; __i < __n_words; ++__i)
__a[__i] = 0;
}
template <size_type __a> static
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_type __align_it(size_type __s) throw()
{return (__s + (__a-1)) & ~(__a-1);}
enum {__alignment = 16};
static __attribute__ ((__visibility__("hidden"), __always_inline__))
size_type __recommend(size_type __s) throw()
{return (__s < __min_cap ? static_cast<size_type>(__min_cap) :
__align_it<sizeof(value_type) < __alignment ?
__alignment/sizeof(value_type) : 1 > (__s+1)) - 1;}
inline
void __init(const value_type* __s, size_type __sz, size_type __reserve);
inline
void __init(const value_type* __s, size_type __sz);
inline
void __init(size_type __n, value_type __c);
template <class _InputIterator>
inline
typename enable_if
<
__is_exactly_input_iterator<_InputIterator>::value,
void
>::type
__init(_InputIterator __first, _InputIterator __last);
template <class _ForwardIterator>
inline
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value,
void
>::type
__init(_ForwardIterator __first, _ForwardIterator __last);
void __grow_by(size_type __old_cap, size_type __delta_cap, size_type __old_sz,
size_type __n_copy, size_type __n_del, size_type __n_add = 0);
void __grow_by_and_replace(size_type __old_cap, size_type __delta_cap, size_type __old_sz,
size_type __n_copy, size_type __n_del,
size_type __n_add, const value_type* __p_new_stuff);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __erase_to_end(size_type __pos);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __copy_assign_alloc(const basic_string& __str)
{__copy_assign_alloc(__str, integral_constant<bool,
__alloc_traits::propagate_on_container_copy_assignment::value>());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __copy_assign_alloc(const basic_string& __str, true_type)
{
if (__alloc() == __str.__alloc())
__alloc() = __str.__alloc();
else
{
if (!__str.__is_long())
{
clear();
shrink_to_fit();
__alloc() = __str.__alloc();
}
else
{
allocator_type __a = __str.__alloc();
pointer __p = __alloc_traits::allocate(__a, __str.__get_long_cap());
clear();
shrink_to_fit();
__alloc() = std::__1::move(__a);
__set_long_pointer(__p);
__set_long_cap(__str.__get_long_cap());
__set_long_size(__str.size());
}
}
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __copy_assign_alloc(const basic_string&, false_type) throw()
{}
# 1453 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
__attribute__ ((__visibility__("hidden"), __always_inline__))
void
__move_assign_alloc(basic_string& __str)
{__move_assign_alloc(__str, integral_constant<bool,
__alloc_traits::propagate_on_container_move_assignment::value>());}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __move_assign_alloc(basic_string& __c, true_type)
{
__alloc() = std::__1::move(__c.__alloc());
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __move_assign_alloc(basic_string&, false_type)
throw()
{}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __invalidate_all_iterators();
__attribute__ ((__visibility__("hidden"), __always_inline__)) void __invalidate_iterators_past(size_type);
friend basic_string operator+<>(const basic_string&, const basic_string&);
friend basic_string operator+<>(const value_type*, const basic_string&);
friend basic_string operator+<>(value_type, const basic_string&);
friend basic_string operator+<>(const basic_string&, const value_type*);
friend basic_string operator+<>(const basic_string&, value_type);
};
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_string<_CharT, _Traits, _Allocator>::__invalidate_all_iterators()
{
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_string<_CharT, _Traits, _Allocator>::__invalidate_iterators_past(size_type
)
{
# 1522 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string()
{
__zero();
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(const allocator_type& __a)
: __r_(__second_tag(), __a)
{
__zero();
}
template <class _CharT, class _Traits, class _Allocator>
void basic_string<_CharT, _Traits, _Allocator>::__init(const value_type* __s,
size_type __sz,
size_type __reserve)
{
if (__reserve > max_size())
this->__throw_length_error();
pointer __p;
if (__reserve < __min_cap)
{
__set_short_size(__sz);
__p = __get_short_pointer();
}
else
{
size_type __cap = __recommend(__reserve);
__p = __alloc_traits::allocate(__alloc(), __cap+1);
__set_long_pointer(__p);
__set_long_cap(__cap+1);
__set_long_size(__sz);
}
traits_type::copy(std::__1::__to_raw_pointer(__p), __s, __sz);
traits_type::assign(__p[__sz], value_type());
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::__init(const value_type* __s, size_type __sz)
{
if (__sz > max_size())
this->__throw_length_error();
pointer __p;
if (__sz < __min_cap)
{
__set_short_size(__sz);
__p = __get_short_pointer();
}
else
{
size_type __cap = __recommend(__sz);
__p = __alloc_traits::allocate(__alloc(), __cap+1);
__set_long_pointer(__p);
__set_long_cap(__cap+1);
__set_long_size(__sz);
}
traits_type::copy(std::__1::__to_raw_pointer(__p), __s, __sz);
traits_type::assign(__p[__sz], value_type());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(const _CharT* __s)
{
((void)0);
__init(__s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(const _CharT* __s, const _Allocator& __a)
: __r_(__second_tag(), __a)
{
((void)0);
__init(__s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(const _CharT* __s, size_type __n)
{
((void)0);
__init(__s, __n);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(const _CharT* __s, size_type __n, const _Allocator& __a)
: __r_(__second_tag(), __a)
{
((void)0);
__init(__s, __n);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>::basic_string(const basic_string& __str)
: __r_(__second_tag(), __alloc_traits::select_on_container_copy_construction(__str.__alloc()))
{
if (!__str.__is_long())
__r_.first().__r = __str.__r_.first().__r;
else
__init(std::__1::__to_raw_pointer(__str.__get_long_pointer()), __str.__get_long_size());
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>::basic_string(
const basic_string& __str, const allocator_type& __a)
: __r_(__second_tag(), __a)
{
if (!__str.__is_long())
__r_.first().__r = __str.__r_.first().__r;
else
__init(std::__1::__to_raw_pointer(__str.__get_long_pointer()), __str.__get_long_size());
}
# 1714 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::__init(size_type __n, value_type __c)
{
if (__n > max_size())
this->__throw_length_error();
pointer __p;
if (__n < __min_cap)
{
__set_short_size(__n);
__p = __get_short_pointer();
}
else
{
size_type __cap = __recommend(__n);
__p = __alloc_traits::allocate(__alloc(), __cap+1);
__set_long_pointer(__p);
__set_long_cap(__cap+1);
__set_long_size(__n);
}
traits_type::assign(std::__1::__to_raw_pointer(__p), __n, __c);
traits_type::assign(__p[__n], value_type());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(size_type __n, _CharT __c)
{
__init(__n, __c);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(size_type __n, _CharT __c, const _Allocator& __a)
: __r_(__second_tag(), __a)
{
__init(__n, __c);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>::basic_string(const basic_string& __str,
size_type __pos, size_type __n,
const _Allocator& __a)
: __r_(__second_tag(), __a)
{
size_type __str_sz = __str.size();
if (__pos > __str_sz)
this->__throw_out_of_range();
__init(__str.data() + __pos, std::__1::min(__n, __str_sz - __pos));
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(const basic_string& __str, size_type __pos,
const _Allocator& __a)
: __r_(__second_tag(), __a)
{
size_type __str_sz = __str.size();
if (__pos > __str_sz)
this->__throw_out_of_range();
__init(__str.data() + __pos, __str_sz - __pos);
}
template <class _CharT, class _Traits, class _Allocator>
template <class _Tp>
basic_string<_CharT, _Traits, _Allocator>::basic_string(
const _Tp& __t, size_type __pos, size_type __n, const allocator_type& __a,
typename enable_if<__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value, void>::type *)
: __r_(__second_tag(), __a)
{
__self_view __sv = __self_view(__t).substr(__pos, __n);
__init(__sv.data(), __sv.size());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(__self_view __sv)
{
__init(__sv.data(), __sv.size());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(__self_view __sv, const _Allocator& __a)
: __r_(__second_tag(), __a)
{
__init(__sv.data(), __sv.size());
}
template <class _CharT, class _Traits, class _Allocator>
template <class _InputIterator>
typename enable_if
<
__is_exactly_input_iterator<_InputIterator>::value,
void
>::type
basic_string<_CharT, _Traits, _Allocator>::__init(_InputIterator __first, _InputIterator __last)
{
__zero();
try
{
for (; __first != __last; ++__first)
push_back(*__first);
}
catch (...)
{
if (__is_long())
__alloc_traits::deallocate(__alloc(), __get_long_pointer(), __get_long_cap());
throw;
}
}
template <class _CharT, class _Traits, class _Allocator>
template <class _ForwardIterator>
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value,
void
>::type
basic_string<_CharT, _Traits, _Allocator>::__init(_ForwardIterator __first, _ForwardIterator __last)
{
size_type __sz = static_cast<size_type>(std::__1::distance(__first, __last));
if (__sz > max_size())
this->__throw_length_error();
pointer __p;
if (__sz < __min_cap)
{
__set_short_size(__sz);
__p = __get_short_pointer();
}
else
{
size_type __cap = __recommend(__sz);
__p = __alloc_traits::allocate(__alloc(), __cap+1);
__set_long_pointer(__p);
__set_long_cap(__cap+1);
__set_long_size(__sz);
}
for (; __first != __last; ++__first, (void) ++__p)
traits_type::assign(*__p, *__first);
traits_type::assign(*__p, value_type());
}
template <class _CharT, class _Traits, class _Allocator>
template<class _InputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(_InputIterator __first, _InputIterator __last)
{
__init(__first, __last);
}
template <class _CharT, class _Traits, class _Allocator>
template<class _InputIterator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>::basic_string(_InputIterator __first, _InputIterator __last,
const allocator_type& __a)
: __r_(__second_tag(), __a)
{
__init(__first, __last);
}
# 1934 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>::~basic_string()
{
if (__is_long())
__alloc_traits::deallocate(__alloc(), __get_long_pointer(), __get_long_cap());
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::__grow_by_and_replace
(size_type __old_cap, size_type __delta_cap, size_type __old_sz,
size_type __n_copy, size_type __n_del, size_type __n_add, const value_type* __p_new_stuff)
{
size_type __ms = max_size();
if (__delta_cap > __ms - __old_cap - 1)
this->__throw_length_error();
pointer __old_p = __get_pointer();
size_type __cap = __old_cap < __ms / 2 - __alignment ?
__recommend(std::__1::max(__old_cap + __delta_cap, 2 * __old_cap)) :
__ms - 1;
pointer __p = __alloc_traits::allocate(__alloc(), __cap+1);
__invalidate_all_iterators();
if (__n_copy != 0)
traits_type::copy(std::__1::__to_raw_pointer(__p),
std::__1::__to_raw_pointer(__old_p), __n_copy);
if (__n_add != 0)
traits_type::copy(std::__1::__to_raw_pointer(__p) + __n_copy, __p_new_stuff, __n_add);
size_type __sec_cp_sz = __old_sz - __n_del - __n_copy;
if (__sec_cp_sz != 0)
traits_type::copy(std::__1::__to_raw_pointer(__p) + __n_copy + __n_add,
std::__1::__to_raw_pointer(__old_p) + __n_copy + __n_del, __sec_cp_sz);
if (__old_cap+1 != __min_cap)
__alloc_traits::deallocate(__alloc(), __old_p, __old_cap+1);
__set_long_pointer(__p);
__set_long_cap(__cap+1);
__old_sz = __n_copy + __n_add + __sec_cp_sz;
__set_long_size(__old_sz);
traits_type::assign(__p[__old_sz], value_type());
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::__grow_by(size_type __old_cap, size_type __delta_cap, size_type __old_sz,
size_type __n_copy, size_type __n_del, size_type __n_add)
{
size_type __ms = max_size();
if (__delta_cap > __ms - __old_cap)
this->__throw_length_error();
pointer __old_p = __get_pointer();
size_type __cap = __old_cap < __ms / 2 - __alignment ?
__recommend(std::__1::max(__old_cap + __delta_cap, 2 * __old_cap)) :
__ms - 1;
pointer __p = __alloc_traits::allocate(__alloc(), __cap+1);
__invalidate_all_iterators();
if (__n_copy != 0)
traits_type::copy(std::__1::__to_raw_pointer(__p),
std::__1::__to_raw_pointer(__old_p), __n_copy);
size_type __sec_cp_sz = __old_sz - __n_del - __n_copy;
if (__sec_cp_sz != 0)
traits_type::copy(std::__1::__to_raw_pointer(__p) + __n_copy + __n_add,
std::__1::__to_raw_pointer(__old_p) + __n_copy + __n_del,
__sec_cp_sz);
if (__old_cap+1 != __min_cap)
__alloc_traits::deallocate(__alloc(), __old_p, __old_cap+1);
__set_long_pointer(__p);
__set_long_cap(__cap+1);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::assign(const value_type* __s, size_type __n)
{
((void)0);
size_type __cap = capacity();
if (__cap >= __n)
{
value_type* __p = std::__1::__to_raw_pointer(__get_pointer());
traits_type::move(__p, __s, __n);
traits_type::assign(__p[__n], value_type());
__set_size(__n);
__invalidate_iterators_past(__n);
}
else
{
size_type __sz = size();
__grow_by_and_replace(__cap, __n - __cap, __sz, 0, __sz, __n, __s);
}
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::assign(size_type __n, value_type __c)
{
size_type __cap = capacity();
if (__cap < __n)
{
size_type __sz = size();
__grow_by(__cap, __n - __cap, __sz, 0, __sz);
}
else
__invalidate_iterators_past(__n);
value_type* __p = std::__1::__to_raw_pointer(__get_pointer());
traits_type::assign(__p, __n, __c);
traits_type::assign(__p[__n], value_type());
__set_size(__n);
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::operator=(value_type __c)
{
pointer __p;
if (__is_long())
{
__p = __get_long_pointer();
__set_long_size(1);
}
else
{
__p = __get_short_pointer();
__set_short_size(1);
}
traits_type::assign(*__p, __c);
traits_type::assign(*++__p, value_type());
__invalidate_iterators_past(1);
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::operator=(const basic_string& __str)
{
if (this != &__str)
{
__copy_assign_alloc(__str);
assign(__str.data(), __str.size());
}
return *this;
}
# 2125 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
template <class _CharT, class _Traits, class _Allocator>
template<class _InputIterator>
typename enable_if
<
__is_exactly_input_iterator <_InputIterator>::value
|| !__libcpp_string_gets_noexcept_iterator<_InputIterator>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::assign(_InputIterator __first, _InputIterator __last)
{
const basic_string __temp(__first, __last, __alloc());
assign(__temp.data(), __temp.size());
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
template<class _ForwardIterator>
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value
&& __libcpp_string_gets_noexcept_iterator<_ForwardIterator>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::assign(_ForwardIterator __first, _ForwardIterator __last)
{
size_type __n = static_cast<size_type>(std::__1::distance(__first, __last));
size_type __cap = capacity();
if (__cap < __n)
{
size_type __sz = size();
__grow_by(__cap, __n - __cap, __sz, 0, __sz);
}
else
__invalidate_iterators_past(__n);
pointer __p = __get_pointer();
for (; __first != __last; ++__first, ++__p)
traits_type::assign(*__p, *__first);
traits_type::assign(*__p, value_type());
__set_size(__n);
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::assign(const basic_string& __str, size_type __pos, size_type __n)
{
size_type __sz = __str.size();
if (__pos > __sz)
this->__throw_out_of_range();
return assign(__str.data() + __pos, std::__1::min(__n, __sz - __pos));
}
template <class _CharT, class _Traits, class _Allocator>
template <class _Tp>
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::assign(const _Tp & __t, size_type __pos, size_type __n)
{
__self_view __sv = __t;
size_type __sz = __sv.size();
if (__pos > __sz)
this->__throw_out_of_range();
return assign(__sv.data() + __pos, std::__1::min(__n, __sz - __pos));
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::assign(const value_type* __s)
{
((void)0);
return assign(__s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::append(const value_type* __s, size_type __n)
{
((void)0);
size_type __cap = capacity();
size_type __sz = size();
if (__cap - __sz >= __n)
{
if (__n)
{
value_type* __p = std::__1::__to_raw_pointer(__get_pointer());
traits_type::copy(__p + __sz, __s, __n);
__sz += __n;
__set_size(__sz);
traits_type::assign(__p[__sz], value_type());
}
}
else
__grow_by_and_replace(__cap, __sz + __n - __cap, __sz, __sz, 0, __n, __s);
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::append(size_type __n, value_type __c)
{
if (__n)
{
size_type __cap = capacity();
size_type __sz = size();
if (__cap - __sz < __n)
__grow_by(__cap, __sz + __n - __cap, __sz, __sz, 0);
pointer __p = __get_pointer();
traits_type::assign(std::__1::__to_raw_pointer(__p) + __sz, __n, __c);
__sz += __n;
__set_size(__sz);
traits_type::assign(__p[__sz], value_type());
}
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::push_back(value_type __c)
{
bool __is_short = !__is_long();
size_type __cap;
size_type __sz;
if (__is_short)
{
__cap = __min_cap - 1;
__sz = __get_short_size();
}
else
{
__cap = __get_long_cap() - 1;
__sz = __get_long_size();
}
if (__sz == __cap)
{
__grow_by(__cap, 1, __sz, __sz, 0);
__is_short = !__is_long();
}
pointer __p;
if (__is_short)
{
__p = __get_short_pointer() + __sz;
__set_short_size(__sz+1);
}
else
{
__p = __get_long_pointer() + __sz;
__set_long_size(__sz+1);
}
traits_type::assign(*__p, __c);
traits_type::assign(*++__p, value_type());
}
template <class _Tp>
bool __ptr_in_range (const _Tp* __p, const _Tp* __first, const _Tp* __last)
{
return __first <= __p && __p < __last;
}
template <class _Tp1, class _Tp2>
bool __ptr_in_range (const _Tp1*, const _Tp2*, const _Tp2*)
{
return false;
}
template <class _CharT, class _Traits, class _Allocator>
template<class _ForwardIterator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::__append_forward_unsafe(
_ForwardIterator __first, _ForwardIterator __last)
{
_Static_assert(__is_forward_iterator<_ForwardIterator>::value, "function requires a ForwardIterator");
size_type __sz = size();
size_type __cap = capacity();
size_type __n = static_cast<size_type>(std::__1::distance(__first, __last));
if (__n)
{
typedef typename iterator_traits<_ForwardIterator>::reference _CharRef;
_CharRef __tmp_ref = *__first;
if (__ptr_in_range(std::__1::addressof(__tmp_ref), data(), data() + size()))
{
const basic_string __temp (__first, __last, __alloc());
append(__temp.data(), __temp.size());
}
else
{
if (__cap - __sz < __n)
__grow_by(__cap, __sz + __n - __cap, __sz, __sz, 0);
pointer __p = __get_pointer() + __sz;
for (; __first != __last; ++__p, ++__first)
traits_type::assign(*__p, *__first);
traits_type::assign(*__p, value_type());
__set_size(__sz + __n);
}
}
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::append(const basic_string& __str)
{
return append(__str.data(), __str.size());
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::append(const basic_string& __str, size_type __pos, size_type __n)
{
size_type __sz = __str.size();
if (__pos > __sz)
this->__throw_out_of_range();
return append(__str.data() + __pos, std::__1::min(__n, __sz - __pos));
}
template <class _CharT, class _Traits, class _Allocator>
template <class _Tp>
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::append(const _Tp & __t, size_type __pos, size_type __n)
{
__self_view __sv = __t;
size_type __sz = __sv.size();
if (__pos > __sz)
this->__throw_out_of_range();
return append(__sv.data() + __pos, std::__1::min(__n, __sz - __pos));
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::append(const value_type* __s)
{
((void)0);
return append(__s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::insert(size_type __pos, const value_type* __s, size_type __n)
{
((void)0);
size_type __sz = size();
if (__pos > __sz)
this->__throw_out_of_range();
size_type __cap = capacity();
if (__cap - __sz >= __n)
{
if (__n)
{
value_type* __p = std::__1::__to_raw_pointer(__get_pointer());
size_type __n_move = __sz - __pos;
if (__n_move != 0)
{
if (__p + __pos <= __s && __s < __p + __sz)
__s += __n;
traits_type::move(__p + __pos + __n, __p + __pos, __n_move);
}
traits_type::move(__p + __pos, __s, __n);
__sz += __n;
__set_size(__sz);
traits_type::assign(__p[__sz], value_type());
}
}
else
__grow_by_and_replace(__cap, __sz + __n - __cap, __sz, __pos, 0, __n, __s);
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::insert(size_type __pos, size_type __n, value_type __c)
{
size_type __sz = size();
if (__pos > __sz)
this->__throw_out_of_range();
if (__n)
{
size_type __cap = capacity();
value_type* __p;
if (__cap - __sz >= __n)
{
__p = std::__1::__to_raw_pointer(__get_pointer());
size_type __n_move = __sz - __pos;
if (__n_move != 0)
traits_type::move(__p + __pos + __n, __p + __pos, __n_move);
}
else
{
__grow_by(__cap, __sz + __n - __cap, __sz, __pos, 0, __n);
__p = std::__1::__to_raw_pointer(__get_long_pointer());
}
traits_type::assign(__p + __pos, __n, __c);
__sz += __n;
__set_size(__sz);
traits_type::assign(__p[__sz], value_type());
}
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
template<class _InputIterator>
typename enable_if
<
__is_exactly_input_iterator<_InputIterator>::value
|| !__libcpp_string_gets_noexcept_iterator<_InputIterator>::value,
typename basic_string<_CharT, _Traits, _Allocator>::iterator
>::type
basic_string<_CharT, _Traits, _Allocator>::insert(const_iterator __pos, _InputIterator __first, _InputIterator __last)
{
const basic_string __temp(__first, __last, __alloc());
return insert(__pos, __temp.data(), __temp.data() + __temp.size());
}
template <class _CharT, class _Traits, class _Allocator>
template<class _ForwardIterator>
typename enable_if
<
__is_forward_iterator<_ForwardIterator>::value
&& __libcpp_string_gets_noexcept_iterator<_ForwardIterator>::value,
typename basic_string<_CharT, _Traits, _Allocator>::iterator
>::type
basic_string<_CharT, _Traits, _Allocator>::insert(const_iterator __pos, _ForwardIterator __first, _ForwardIterator __last)
{
size_type __ip = static_cast<size_type>(__pos - begin());
size_type __n = static_cast<size_type>(std::__1::distance(__first, __last));
if (__n)
{
typedef typename iterator_traits<_ForwardIterator>::reference _CharRef;
_CharRef __tmp_char = *__first;
if (__ptr_in_range(std::__1::addressof(__tmp_char), data(), data() + size()))
{
const basic_string __temp(__first, __last, __alloc());
return insert(__pos, __temp.data(), __temp.data() + __temp.size());
}
size_type __sz = size();
size_type __cap = capacity();
value_type* __p;
if (__cap - __sz >= __n)
{
__p = std::__1::__to_raw_pointer(__get_pointer());
size_type __n_move = __sz - __ip;
if (__n_move != 0)
traits_type::move(__p + __ip + __n, __p + __ip, __n_move);
}
else
{
__grow_by(__cap, __sz + __n - __cap, __sz, __ip, 0, __n);
__p = std::__1::__to_raw_pointer(__get_long_pointer());
}
__sz += __n;
__set_size(__sz);
traits_type::assign(__p[__sz], value_type());
for (__p += __ip; __first != __last; ++__p, ++__first)
traits_type::assign(*__p, *__first);
}
return begin() + __ip;
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::insert(size_type __pos1, const basic_string& __str)
{
return insert(__pos1, __str.data(), __str.size());
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::insert(size_type __pos1, const basic_string& __str,
size_type __pos2, size_type __n)
{
size_type __str_sz = __str.size();
if (__pos2 > __str_sz)
this->__throw_out_of_range();
return insert(__pos1, __str.data() + __pos2, std::__1::min(__n, __str_sz - __pos2));
}
template <class _CharT, class _Traits, class _Allocator>
template <class _Tp>
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::insert(size_type __pos1, const _Tp& __t,
size_type __pos2, size_type __n)
{
__self_view __sv = __t;
size_type __str_sz = __sv.size();
if (__pos2 > __str_sz)
this->__throw_out_of_range();
return insert(__pos1, __sv.data() + __pos2, std::__1::min(__n, __str_sz - __pos2));
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::insert(size_type __pos, const value_type* __s)
{
((void)0);
return insert(__pos, __s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::iterator
basic_string<_CharT, _Traits, _Allocator>::insert(const_iterator __pos, value_type __c)
{
size_type __ip = static_cast<size_type>(__pos - begin());
size_type __sz = size();
size_type __cap = capacity();
value_type* __p;
if (__cap == __sz)
{
__grow_by(__cap, 1, __sz, __ip, 0, 1);
__p = std::__1::__to_raw_pointer(__get_long_pointer());
}
else
{
__p = std::__1::__to_raw_pointer(__get_pointer());
size_type __n_move = __sz - __ip;
if (__n_move != 0)
traits_type::move(__p + __ip + 1, __p + __ip, __n_move);
}
traits_type::assign(__p[__ip], __c);
traits_type::assign(__p[++__sz], value_type());
__set_size(__sz);
return begin() + static_cast<difference_type>(__ip);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::iterator
basic_string<_CharT, _Traits, _Allocator>::insert(const_iterator __pos, size_type __n, value_type __c)
{
difference_type __p = __pos - begin();
insert(static_cast<size_type>(__p), __n, __c);
return begin() + __p;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(size_type __pos, size_type __n1, const value_type* __s, size_type __n2)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
((void)0);
size_type __sz = size();
if (__pos > __sz)
this->__throw_out_of_range();
__n1 = std::__1::min(__n1, __sz - __pos);
size_type __cap = capacity();
if (__cap - __sz + __n1 >= __n2)
{
value_type* __p = std::__1::__to_raw_pointer(__get_pointer());
if (__n1 != __n2)
{
size_type __n_move = __sz - __pos - __n1;
if (__n_move != 0)
{
if (__n1 > __n2)
{
traits_type::move(__p + __pos, __s, __n2);
traits_type::move(__p + __pos + __n2, __p + __pos + __n1, __n_move);
goto __finish;
}
if (__p + __pos < __s && __s < __p + __sz)
{
if (__p + __pos + __n1 <= __s)
__s += __n2 - __n1;
else
{
traits_type::move(__p + __pos, __s, __n1);
__pos += __n1;
__s += __n2;
__n2 -= __n1;
__n1 = 0;
}
}
traits_type::move(__p + __pos + __n2, __p + __pos + __n1, __n_move);
}
}
traits_type::move(__p + __pos, __s, __n2);
__finish:
__sz += __n2 - __n1;
__set_size(__sz);
__invalidate_iterators_past(__sz);
traits_type::assign(__p[__sz], value_type());
}
else
__grow_by_and_replace(__cap, __sz - __n1 + __n2 - __cap, __sz, __pos, __n1, __n2, __s);
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(size_type __pos, size_type __n1, size_type __n2, value_type __c)
__attribute__((__no_sanitize__("unsigned-integer-overflow")))
{
size_type __sz = size();
if (__pos > __sz)
this->__throw_out_of_range();
__n1 = std::__1::min(__n1, __sz - __pos);
size_type __cap = capacity();
value_type* __p;
if (__cap - __sz + __n1 >= __n2)
{
__p = std::__1::__to_raw_pointer(__get_pointer());
if (__n1 != __n2)
{
size_type __n_move = __sz - __pos - __n1;
if (__n_move != 0)
traits_type::move(__p + __pos + __n2, __p + __pos + __n1, __n_move);
}
}
else
{
__grow_by(__cap, __sz - __n1 + __n2 - __cap, __sz, __pos, __n1, __n2);
__p = std::__1::__to_raw_pointer(__get_long_pointer());
}
traits_type::assign(__p + __pos, __n2, __c);
__sz += __n2 - __n1;
__set_size(__sz);
__invalidate_iterators_past(__sz);
traits_type::assign(__p[__sz], value_type());
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
template<class _InputIterator>
typename enable_if
<
__is_input_iterator<_InputIterator>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::replace(const_iterator __i1, const_iterator __i2,
_InputIterator __j1, _InputIterator __j2)
{
const basic_string __temp(__j1, __j2, __alloc());
return this->replace(__i1, __i2, __temp);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(size_type __pos1, size_type __n1, const basic_string& __str)
{
return replace(__pos1, __n1, __str.data(), __str.size());
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(size_type __pos1, size_type __n1, const basic_string& __str,
size_type __pos2, size_type __n2)
{
size_type __str_sz = __str.size();
if (__pos2 > __str_sz)
this->__throw_out_of_range();
return replace(__pos1, __n1, __str.data() + __pos2, std::__1::min(__n2, __str_sz - __pos2));
}
template <class _CharT, class _Traits, class _Allocator>
template <class _Tp>
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
basic_string<_CharT, _Traits, _Allocator>&
>::type
basic_string<_CharT, _Traits, _Allocator>::replace(size_type __pos1, size_type __n1, const _Tp& __t,
size_type __pos2, size_type __n2)
{
__self_view __sv = __t;
size_type __str_sz = __sv.size();
if (__pos2 > __str_sz)
this->__throw_out_of_range();
return replace(__pos1, __n1, __sv.data() + __pos2, std::__1::min(__n2, __str_sz - __pos2));
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(size_type __pos, size_type __n1, const value_type* __s)
{
((void)0);
return replace(__pos, __n1, __s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(const_iterator __i1, const_iterator __i2, const basic_string& __str)
{
return replace(static_cast<size_type>(__i1 - begin()), static_cast<size_type>(__i2 - __i1),
__str.data(), __str.size());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(const_iterator __i1, const_iterator __i2, const value_type* __s, size_type __n)
{
return replace(static_cast<size_type>(__i1 - begin()), static_cast<size_type>(__i2 - __i1), __s, __n);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(const_iterator __i1, const_iterator __i2, const value_type* __s)
{
return replace(static_cast<size_type>(__i1 - begin()), static_cast<size_type>(__i2 - __i1), __s);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::replace(const_iterator __i1, const_iterator __i2, size_type __n, value_type __c)
{
return replace(static_cast<size_type>(__i1 - begin()), static_cast<size_type>(__i2 - __i1), __n, __c);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>&
basic_string<_CharT, _Traits, _Allocator>::erase(size_type __pos, size_type __n)
{
size_type __sz = size();
if (__pos > __sz)
this->__throw_out_of_range();
if (__n)
{
value_type* __p = std::__1::__to_raw_pointer(__get_pointer());
__n = std::__1::min(__n, __sz - __pos);
size_type __n_move = __sz - __pos - __n;
if (__n_move != 0)
traits_type::move(__p + __pos, __p + __pos + __n, __n_move);
__sz -= __n;
__set_size(__sz);
__invalidate_iterators_past(__sz);
traits_type::assign(__p[__sz], value_type());
}
return *this;
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::iterator
basic_string<_CharT, _Traits, _Allocator>::erase(const_iterator __pos)
{
((void)0);
iterator __b = begin();
size_type __r = static_cast<size_type>(__pos - __b);
erase(__r, 1);
return __b + static_cast<difference_type>(__r);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::iterator
basic_string<_CharT, _Traits, _Allocator>::erase(const_iterator __first, const_iterator __last)
{
((void)0);
iterator __b = begin();
size_type __r = static_cast<size_type>(__first - __b);
erase(__r, static_cast<size_type>(__last - __first));
return __b + static_cast<difference_type>(__r);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_string<_CharT, _Traits, _Allocator>::pop_back()
{
((void)0);
size_type __sz;
if (__is_long())
{
__sz = __get_long_size() - 1;
__set_long_size(__sz);
traits_type::assign(*(__get_long_pointer() + __sz), value_type());
}
else
{
__sz = __get_short_size() - 1;
__set_short_size(__sz);
traits_type::assign(*(__get_short_pointer() + __sz), value_type());
}
__invalidate_iterators_past(__sz);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_string<_CharT, _Traits, _Allocator>::clear() throw()
{
__invalidate_all_iterators();
if (__is_long())
{
traits_type::assign(*__get_long_pointer(), value_type());
__set_long_size(0);
}
else
{
traits_type::assign(*__get_short_pointer(), value_type());
__set_short_size(0);
}
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_string<_CharT, _Traits, _Allocator>::__erase_to_end(size_type __pos)
{
if (__is_long())
{
traits_type::assign(*(__get_long_pointer() + __pos), value_type());
__set_long_size(__pos);
}
else
{
traits_type::assign(*(__get_short_pointer() + __pos), value_type());
__set_short_size(__pos);
}
__invalidate_iterators_past(__pos);
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::resize(size_type __n, value_type __c)
{
size_type __sz = size();
if (__n > __sz)
append(__n - __sz, __c);
else
__erase_to_end(__n);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::max_size() const throw()
{
size_type __m = __alloc_traits::max_size(__alloc());
return __m - __alignment;
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_string<_CharT, _Traits, _Allocator>::reserve(size_type __res_arg)
{
if (__res_arg > max_size())
this->__throw_length_error();
size_type __cap = capacity();
size_type __sz = size();
__res_arg = std::__1::max(__res_arg, __sz);
__res_arg = __recommend(__res_arg);
if (__res_arg != __cap)
{
pointer __new_data, __p;
bool __was_long, __now_long;
if (__res_arg == __min_cap - 1)
{
__was_long = true;
__now_long = false;
__new_data = __get_short_pointer();
__p = __get_long_pointer();
}
else
{
if (__res_arg > __cap)
__new_data = __alloc_traits::allocate(__alloc(), __res_arg+1);
else
{
try
{
__new_data = __alloc_traits::allocate(__alloc(), __res_arg+1);
}
catch (...)
{
return;
}
}
__now_long = true;
__was_long = __is_long();
__p = __get_pointer();
}
traits_type::copy(std::__1::__to_raw_pointer(__new_data),
std::__1::__to_raw_pointer(__p), size()+1);
if (__was_long)
__alloc_traits::deallocate(__alloc(), __p, __cap+1);
if (__now_long)
{
__set_long_cap(__res_arg+1);
__set_long_size(__sz);
__set_long_pointer(__new_data);
}
else
__set_short_size(__sz);
__invalidate_all_iterators();
}
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::const_reference
basic_string<_CharT, _Traits, _Allocator>::operator[](size_type __pos) const throw()
{
((void)0);
return *(data() + __pos);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::reference
basic_string<_CharT, _Traits, _Allocator>::operator[](size_type __pos) throw()
{
((void)0);
return *(__get_pointer() + __pos);
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::const_reference
basic_string<_CharT, _Traits, _Allocator>::at(size_type __n) const
{
if (__n >= size())
this->__throw_out_of_range();
return (*this)[__n];
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::reference
basic_string<_CharT, _Traits, _Allocator>::at(size_type __n)
{
if (__n >= size())
this->__throw_out_of_range();
return (*this)[__n];
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::reference
basic_string<_CharT, _Traits, _Allocator>::front()
{
((void)0);
return *__get_pointer();
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::const_reference
basic_string<_CharT, _Traits, _Allocator>::front() const
{
((void)0);
return *data();
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::reference
basic_string<_CharT, _Traits, _Allocator>::back()
{
((void)0);
return *(__get_pointer() + size() - 1);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::const_reference
basic_string<_CharT, _Traits, _Allocator>::back() const
{
((void)0);
return *(data() + size() - 1);
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::copy(value_type* __s, size_type __n, size_type __pos) const
{
size_type __sz = size();
if (__pos > __sz)
this->__throw_out_of_range();
size_type __rlen = std::__1::min(__n, __sz - __pos);
traits_type::copy(__s, data() + __pos, __rlen);
return __rlen;
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, _Allocator>
basic_string<_CharT, _Traits, _Allocator>::substr(size_type __pos, size_type __n) const
{
return basic_string(*this, __pos, __n, __alloc());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_string<_CharT, _Traits, _Allocator>::swap(basic_string& __str)
{
((void)0);
std::__1::swap(__r_.first(), __str.__r_.first());
__swap_allocator(__alloc(), __str.__alloc());
}
template <class _Traits>
struct __attribute__ ((__visibility__("hidden"))) __traits_eq
{
typedef typename _Traits::char_type char_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const char_type& __x, const char_type& __y) throw()
{return _Traits::eq(__x, __y);}
};
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find(const value_type* __s,
size_type __pos,
size_type __n) const throw()
{
((void)0);
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find(const basic_string& __str,
size_type __pos) const throw()
{
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __str.data(), __pos, __str.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find(__self_view __sv,
size_type __pos) const throw()
{
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __sv.data(), __pos, __sv.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find(const value_type* __s,
size_type __pos) const throw()
{
((void)0);
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find(value_type __c,
size_type __pos) const throw()
{
return __str_find<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::rfind(const value_type* __s,
size_type __pos,
size_type __n) const throw()
{
((void)0);
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::rfind(const basic_string& __str,
size_type __pos) const throw()
{
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __str.data(), __pos, __str.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::rfind(__self_view __sv,
size_type __pos) const throw()
{
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __sv.data(), __pos, __sv.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::rfind(const value_type* __s,
size_type __pos) const throw()
{
((void)0);
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::rfind(value_type __c,
size_type __pos) const throw()
{
return __str_rfind<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_of(const value_type* __s,
size_type __pos,
size_type __n) const throw()
{
((void)0);
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_of(const basic_string& __str,
size_type __pos) const throw()
{
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __str.data(), __pos, __str.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_of(__self_view __sv,
size_type __pos) const throw()
{
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __sv.data(), __pos, __sv.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_of(const value_type* __s,
size_type __pos) const throw()
{
((void)0);
return __str_find_first_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_of(value_type __c,
size_type __pos) const throw()
{
return find(__c, __pos);
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_of(const value_type* __s,
size_type __pos,
size_type __n) const throw()
{
((void)0);
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_of(const basic_string& __str,
size_type __pos) const throw()
{
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __str.data(), __pos, __str.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_of(__self_view __sv,
size_type __pos) const throw()
{
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __sv.data(), __pos, __sv.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_of(const value_type* __s,
size_type __pos) const throw()
{
((void)0);
return __str_find_last_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_of(value_type __c,
size_type __pos) const throw()
{
return rfind(__c, __pos);
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_not_of(const value_type* __s,
size_type __pos,
size_type __n) const throw()
{
((void)0);
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_not_of(const basic_string& __str,
size_type __pos) const throw()
{
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __str.data(), __pos, __str.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_not_of(__self_view __sv,
size_type __pos) const throw()
{
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __sv.data(), __pos, __sv.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_not_of(const value_type* __s,
size_type __pos) const throw()
{
((void)0);
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_first_not_of(value_type __c,
size_type __pos) const throw()
{
return __str_find_first_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
template<class _CharT, class _Traits, class _Allocator>
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_not_of(const value_type* __s,
size_type __pos,
size_type __n) const throw()
{
((void)0);
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, __n);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_not_of(const basic_string& __str,
size_type __pos) const throw()
{
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __str.data(), __pos, __str.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_not_of(__self_view __sv,
size_type __pos) const throw()
{
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __sv.data(), __pos, __sv.size());
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_not_of(const value_type* __s,
size_type __pos) const throw()
{
((void)0);
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __s, __pos, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::find_last_not_of(value_type __c,
size_type __pos) const throw()
{
return __str_find_last_not_of<value_type, size_type, traits_type, npos>
(data(), size(), __c, __pos);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int
basic_string<_CharT, _Traits, _Allocator>::compare(__self_view __sv) const throw()
{
size_t __lhs_sz = size();
size_t __rhs_sz = __sv.size();
int __result = traits_type::compare(data(), __sv.data(),
std::__1::min(__lhs_sz, __rhs_sz));
if (__result != 0)
return __result;
if (__lhs_sz < __rhs_sz)
return -1;
if (__lhs_sz > __rhs_sz)
return 1;
return 0;
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int
basic_string<_CharT, _Traits, _Allocator>::compare(const basic_string& __str) const throw()
{
return compare(__self_view(__str));
}
template <class _CharT, class _Traits, class _Allocator>
int
basic_string<_CharT, _Traits, _Allocator>::compare(size_type __pos1,
size_type __n1,
const value_type* __s,
size_type __n2) const
{
((void)0);
size_type __sz = size();
if (__pos1 > __sz || __n2 == npos)
this->__throw_out_of_range();
size_type __rlen = std::__1::min(__n1, __sz - __pos1);
int __r = traits_type::compare(data() + __pos1, __s, std::__1::min(__rlen, __n2));
if (__r == 0)
{
if (__rlen < __n2)
__r = -1;
else if (__rlen > __n2)
__r = 1;
}
return __r;
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int
basic_string<_CharT, _Traits, _Allocator>::compare(size_type __pos1,
size_type __n1,
__self_view __sv) const
{
return compare(__pos1, __n1, __sv.data(), __sv.size());
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int
basic_string<_CharT, _Traits, _Allocator>::compare(size_type __pos1,
size_type __n1,
const basic_string& __str) const
{
return compare(__pos1, __n1, __str.data(), __str.size());
}
template <class _CharT, class _Traits, class _Allocator>
template <class _Tp>
typename enable_if
<
__can_be_converted_to_string_view<_CharT, _Traits, _Tp>::value,
int
>::type
basic_string<_CharT, _Traits, _Allocator>::compare(size_type __pos1,
size_type __n1,
const _Tp& __t,
size_type __pos2,
size_type __n2) const
{
__self_view __sv = __t;
return __self_view(*this).substr(__pos1, __n1).compare(__sv.substr(__pos2, __n2));
}
template <class _CharT, class _Traits, class _Allocator>
int
basic_string<_CharT, _Traits, _Allocator>::compare(size_type __pos1,
size_type __n1,
const basic_string& __str,
size_type __pos2,
size_type __n2) const
{
return compare(__pos1, __n1, __self_view(__str), __pos2, __n2);
}
template <class _CharT, class _Traits, class _Allocator>
int
basic_string<_CharT, _Traits, _Allocator>::compare(const value_type* __s) const throw()
{
((void)0);
return compare(0, npos, __s, traits_type::length(__s));
}
template <class _CharT, class _Traits, class _Allocator>
int
basic_string<_CharT, _Traits, _Allocator>::compare(size_type __pos1,
size_type __n1,
const value_type* __s) const
{
((void)0);
return compare(__pos1, __n1, __s, traits_type::length(__s));
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
basic_string<_CharT, _Traits, _Allocator>::__invariants() const
{
if (size() > capacity())
return false;
if (capacity() < __min_cap - 1)
return false;
if (data() == 0)
return false;
if (data()[size()] != value_type(0))
return false;
return true;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
size_t __lhs_sz = __lhs.size();
return __lhs_sz == __rhs.size() && _Traits::compare(__lhs.data(),
__rhs.data(),
__lhs_sz) == 0;
}
template<class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const basic_string<char, char_traits<char>, _Allocator>& __lhs,
const basic_string<char, char_traits<char>, _Allocator>& __rhs) throw()
{
size_t __lhs_sz = __lhs.size();
if (__lhs_sz != __rhs.size())
return false;
const char* __lp = __lhs.data();
const char* __rp = __rhs.data();
if (__lhs.__is_long())
return char_traits<char>::compare(__lp, __rp, __lhs_sz) == 0;
for (; __lhs_sz != 0; --__lhs_sz, ++__lp, ++__rp)
if (*__lp != *__rp)
return false;
return true;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const _CharT* __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
typedef basic_string<_CharT, _Traits, _Allocator> _String;
((void)0);
size_t __lhs_len = _Traits::length(__lhs);
if (__lhs_len != __rhs.size()) return false;
return __rhs.compare(0, _String::npos, __lhs, __lhs_len) == 0;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const basic_string<_CharT,_Traits,_Allocator>& __lhs,
const _CharT* __rhs) throw()
{
typedef basic_string<_CharT, _Traits, _Allocator> _String;
((void)0);
size_t __rhs_len = _Traits::length(__rhs);
if (__rhs_len != __lhs.size()) return false;
return __lhs.compare(0, _String::npos, __rhs, __rhs_len) == 0;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const basic_string<_CharT,_Traits,_Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return !(__lhs == __rhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const _CharT* __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return !(__lhs == __rhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const _CharT* __rhs) throw()
{
return !(__lhs == __rhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator< (const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator< (const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const _CharT* __rhs) throw()
{
return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator< (const _CharT* __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return __rhs.compare(__lhs) > 0;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return __rhs < __lhs;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const _CharT* __rhs) throw()
{
return __rhs < __lhs;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const _CharT* __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return __rhs < __lhs;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return !(__rhs < __lhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const _CharT* __rhs) throw()
{
return !(__rhs < __lhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const _CharT* __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return !(__rhs < __lhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return !(__lhs < __rhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const _CharT* __rhs) throw()
{
return !(__lhs < __rhs);
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const _CharT* __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) throw()
{
return !(__lhs < __rhs);
}
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs)
{
basic_string<_CharT, _Traits, _Allocator> __r(__lhs.get_allocator());
typename basic_string<_CharT, _Traits, _Allocator>::size_type __lhs_sz = __lhs.size();
typename basic_string<_CharT, _Traits, _Allocator>::size_type __rhs_sz = __rhs.size();
__r.__init(__lhs.data(), __lhs_sz, __lhs_sz + __rhs_sz);
__r.append(__rhs.data(), __rhs_sz);
return __r;
}
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const _CharT* __lhs , const basic_string<_CharT,_Traits,_Allocator>& __rhs)
{
basic_string<_CharT, _Traits, _Allocator> __r(__rhs.get_allocator());
typename basic_string<_CharT, _Traits, _Allocator>::size_type __lhs_sz = _Traits::length(__lhs);
typename basic_string<_CharT, _Traits, _Allocator>::size_type __rhs_sz = __rhs.size();
__r.__init(__lhs, __lhs_sz, __lhs_sz + __rhs_sz);
__r.append(__rhs.data(), __rhs_sz);
return __r;
}
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(_CharT __lhs, const basic_string<_CharT,_Traits,_Allocator>& __rhs)
{
basic_string<_CharT, _Traits, _Allocator> __r(__rhs.get_allocator());
typename basic_string<_CharT, _Traits, _Allocator>::size_type __rhs_sz = __rhs.size();
__r.__init(&__lhs, 1, 1 + __rhs_sz);
__r.append(__rhs.data(), __rhs_sz);
return __r;
}
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const basic_string<_CharT, _Traits, _Allocator>& __lhs, const _CharT* __rhs)
{
basic_string<_CharT, _Traits, _Allocator> __r(__lhs.get_allocator());
typename basic_string<_CharT, _Traits, _Allocator>::size_type __lhs_sz = __lhs.size();
typename basic_string<_CharT, _Traits, _Allocator>::size_type __rhs_sz = _Traits::length(__rhs);
__r.__init(__lhs.data(), __lhs_sz, __lhs_sz + __rhs_sz);
__r.append(__rhs, __rhs_sz);
return __r;
}
template<class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
operator+(const basic_string<_CharT, _Traits, _Allocator>& __lhs, _CharT __rhs)
{
basic_string<_CharT, _Traits, _Allocator> __r(__lhs.get_allocator());
typename basic_string<_CharT, _Traits, _Allocator>::size_type __lhs_sz = __lhs.size();
__r.__init(__lhs.data(), __lhs_sz, __lhs_sz + 1);
__r.push_back(__rhs);
return __r;
}
# 3886 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(basic_string<_CharT, _Traits, _Allocator>& __lhs,
basic_string<_CharT, _Traits, _Allocator>& __rhs)
{
__lhs.swap(__rhs);
}
typedef basic_string<char16_t> u16string;
typedef basic_string<char32_t> u32string;
__attribute__ ((__visibility__("default"))) int stoi (const string& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) long stol (const string& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) unsigned long stoul (const string& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) long long stoll (const string& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) unsigned long long stoull(const string& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) float stof (const string& __str, size_t* __idx = 0);
__attribute__ ((__visibility__("default"))) double stod (const string& __str, size_t* __idx = 0);
__attribute__ ((__visibility__("default"))) long double stold(const string& __str, size_t* __idx = 0);
__attribute__ ((__visibility__("default"))) string to_string(int __val);
__attribute__ ((__visibility__("default"))) string to_string(unsigned __val);
__attribute__ ((__visibility__("default"))) string to_string(long __val);
__attribute__ ((__visibility__("default"))) string to_string(unsigned long __val);
__attribute__ ((__visibility__("default"))) string to_string(long long __val);
__attribute__ ((__visibility__("default"))) string to_string(unsigned long long __val);
__attribute__ ((__visibility__("default"))) string to_string(float __val);
__attribute__ ((__visibility__("default"))) string to_string(double __val);
__attribute__ ((__visibility__("default"))) string to_string(long double __val);
__attribute__ ((__visibility__("default"))) int stoi (const wstring& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) long stol (const wstring& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) unsigned long stoul (const wstring& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) long long stoll (const wstring& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) unsigned long long stoull(const wstring& __str, size_t* __idx = 0, int __base = 10);
__attribute__ ((__visibility__("default"))) float stof (const wstring& __str, size_t* __idx = 0);
__attribute__ ((__visibility__("default"))) double stod (const wstring& __str, size_t* __idx = 0);
__attribute__ ((__visibility__("default"))) long double stold(const wstring& __str, size_t* __idx = 0);
__attribute__ ((__visibility__("default"))) wstring to_wstring(int __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(unsigned __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(long __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(unsigned long __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(long long __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(unsigned long long __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(float __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(double __val);
__attribute__ ((__visibility__("default"))) wstring to_wstring(long double __val);
template<class _CharT, class _Traits, class _Allocator>
const typename basic_string<_CharT, _Traits, _Allocator>::size_type
basic_string<_CharT, _Traits, _Allocator>::npos;
template<class _CharT, class _Traits, class _Allocator>
struct __attribute__ ((__type_visibility__("default"))) hash<basic_string<_CharT, _Traits, _Allocator> >
: public unary_function<basic_string<_CharT, _Traits, _Allocator>, size_t>
{
size_t
operator()(const basic_string<_CharT, _Traits, _Allocator>& __val) const throw();
};
template<class _CharT, class _Traits, class _Allocator>
size_t
hash<basic_string<_CharT, _Traits, _Allocator> >::operator()(
const basic_string<_CharT, _Traits, _Allocator>& __val) const throw()
{
return __do_string_hash(__val.data(), __val.data() + __val.size());
}
template<class _CharT, class _Traits, class _Allocator>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os,
const basic_string<_CharT, _Traits, _Allocator>& __str);
template<class _CharT, class _Traits, class _Allocator>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is,
basic_string<_CharT, _Traits, _Allocator>& __str);
template<class _CharT, class _Traits, class _Allocator>
basic_istream<_CharT, _Traits>&
getline(basic_istream<_CharT, _Traits>& __is,
basic_string<_CharT, _Traits, _Allocator>& __str, _CharT __dlm);
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_istream<_CharT, _Traits>&
getline(basic_istream<_CharT, _Traits>& __is,
basic_string<_CharT, _Traits, _Allocator>& __str);
# 4036 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
extern template class __attribute__ ((__visibility__("default"))) basic_string<char>;
extern template class __attribute__ ((__visibility__("default"))) basic_string<wchar_t>;
# 4072 "/Library/Developer/CommandLineTools/usr/include/c++/v1/string" 3
} }
# 19 "./src/include/node_sodium.h" 2
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 1 3
# 174 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 1 3
# 138 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ios" 1 3
# 216 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ios" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 1 3
# 18 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 1 3
# 191 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 1 3
# 15 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 1 3
# 305 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 1 3
# 83 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/climits" 1 3
# 42 "/Library/Developer/CommandLineTools/usr/include/c++/v1/climits" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits.h" 1 3
# 45 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits.h" 3
# 58 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits.h" 3
# 1 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/limits.h" 1 3 4
# 37 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/limits.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/limits.h" 1 3 4
# 64 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/limits.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/limits.h" 1 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/limits.h" 1 3 4
# 40 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/limits.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/_limits.h" 1 3 4
# 41 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/i386/limits.h" 2 3 4
# 7 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/machine/limits.h" 2 3 4
# 65 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/limits.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/syslimits.h" 1 3 4
# 66 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/limits.h" 2 3 4
# 38 "/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/include/limits.h" 2 3 4
# 59 "/Library/Developer/CommandLineTools/usr/include/c++/v1/limits.h" 2 3
# 43 "/Library/Developer/CommandLineTools/usr/include/c++/v1/climits" 2 3
# 46 "/Library/Developer/CommandLineTools/usr/include/c++/v1/climits" 3
# 84 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 2 3
# 88 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 92 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 2 3
namespace std {inline namespace __1 {
template <intmax_t _Xp, intmax_t _Yp>
struct __static_gcd
{
static const intmax_t value = __static_gcd<_Yp, _Xp % _Yp>::value;
};
template <intmax_t _Xp>
struct __static_gcd<_Xp, 0>
{
static const intmax_t value = _Xp;
};
template <>
struct __static_gcd<0, 0>
{
static const intmax_t value = 1;
};
template <intmax_t _Xp, intmax_t _Yp>
struct __static_lcm
{
static const intmax_t value = _Xp / __static_gcd<_Xp, _Yp>::value * _Yp;
};
template <intmax_t _Xp>
struct __static_abs
{
static const intmax_t value = _Xp < 0 ? -_Xp : _Xp;
};
template <intmax_t _Xp>
struct __static_sign
{
static const intmax_t value = _Xp == 0 ? 0 : (_Xp < 0 ? -1 : 1);
};
template <intmax_t _Xp, intmax_t _Yp, intmax_t = __static_sign<_Yp>::value>
class __ll_add;
template <intmax_t _Xp, intmax_t _Yp>
class __ll_add<_Xp, _Yp, 1>
{
static const intmax_t min = (1LL << (sizeof(intmax_t) * 8 - 1)) + 1;
static const intmax_t max = -min;
_Static_assert(_Xp <= max - _Yp, "overflow in __ll_add");
public:
static const intmax_t value = _Xp + _Yp;
};
template <intmax_t _Xp, intmax_t _Yp>
class __ll_add<_Xp, _Yp, 0>
{
public:
static const intmax_t value = _Xp;
};
template <intmax_t _Xp, intmax_t _Yp>
class __ll_add<_Xp, _Yp, -1>
{
static const intmax_t min = (1LL << (sizeof(intmax_t) * 8 - 1)) + 1;
static const intmax_t max = -min;
_Static_assert(min - _Yp <= _Xp, "overflow in __ll_add");
public:
static const intmax_t value = _Xp + _Yp;
};
template <intmax_t _Xp, intmax_t _Yp, intmax_t = __static_sign<_Yp>::value>
class __ll_sub;
template <intmax_t _Xp, intmax_t _Yp>
class __ll_sub<_Xp, _Yp, 1>
{
static const intmax_t min = (1LL << (sizeof(intmax_t) * 8 - 1)) + 1;
static const intmax_t max = -min;
_Static_assert(min + _Yp <= _Xp, "overflow in __ll_sub");
public:
static const intmax_t value = _Xp - _Yp;
};
template <intmax_t _Xp, intmax_t _Yp>
class __ll_sub<_Xp, _Yp, 0>
{
public:
static const intmax_t value = _Xp;
};
template <intmax_t _Xp, intmax_t _Yp>
class __ll_sub<_Xp, _Yp, -1>
{
static const intmax_t min = (1LL << (sizeof(intmax_t) * 8 - 1)) + 1;
static const intmax_t max = -min;
_Static_assert(_Xp <= max + _Yp, "overflow in __ll_sub");
public:
static const intmax_t value = _Xp - _Yp;
};
template <intmax_t _Xp, intmax_t _Yp>
class __ll_mul
{
static const intmax_t nan = (1LL << (sizeof(intmax_t) * 8 - 1));
static const intmax_t min = nan + 1;
static const intmax_t max = -min;
static const intmax_t __a_x = __static_abs<_Xp>::value;
static const intmax_t __a_y = __static_abs<_Yp>::value;
_Static_assert(_Xp != nan && _Yp != nan && __a_x <= max / __a_y, "overflow in __ll_mul");
public:
static const intmax_t value = _Xp * _Yp;
};
template <intmax_t _Yp>
class __ll_mul<0, _Yp>
{
public:
static const intmax_t value = 0;
};
template <intmax_t _Xp>
class __ll_mul<_Xp, 0>
{
public:
static const intmax_t value = 0;
};
template <>
class __ll_mul<0, 0>
{
public:
static const intmax_t value = 0;
};
template <intmax_t _Xp, intmax_t _Yp>
class __ll_div
{
static const intmax_t nan = (1LL << (sizeof(intmax_t) * 8 - 1));
static const intmax_t min = nan + 1;
static const intmax_t max = -min;
_Static_assert(_Xp != nan && _Yp != nan && _Yp != 0, "overflow in __ll_div");
public:
static const intmax_t value = _Xp / _Yp;
};
template <intmax_t _Num, intmax_t _Den = 1>
class __attribute__ ((__type_visibility__("default"))) ratio
{
_Static_assert(__static_abs<_Num>::value >= 0, "ratio numerator is out of range");
_Static_assert(_Den != 0, "ratio divide by 0");
_Static_assert(__static_abs<_Den>::value > 0, "ratio denominator is out of range");
static const intmax_t __na = __static_abs<_Num>::value;
static const intmax_t __da = __static_abs<_Den>::value;
static const intmax_t __s = __static_sign<_Num>::value * __static_sign<_Den>::value;
static const intmax_t __gcd = __static_gcd<__na, __da>::value;
public:
static const intmax_t num = __s * __na / __gcd;
static const intmax_t den = __da / __gcd;
typedef ratio<num, den> type;
};
template <intmax_t _Num, intmax_t _Den>
const intmax_t ratio<_Num, _Den>::num;
template <intmax_t _Num, intmax_t _Den>
const intmax_t ratio<_Num, _Den>::den;
template <class _Tp> struct __is_ratio : false_type {};
template <intmax_t _Num, intmax_t _Den> struct __is_ratio<ratio<_Num, _Den> > : true_type {};
typedef ratio<1LL, 1000000000000000000LL> atto;
typedef ratio<1LL, 1000000000000000LL> femto;
typedef ratio<1LL, 1000000000000LL> pico;
typedef ratio<1LL, 1000000000LL> nano;
typedef ratio<1LL, 1000000LL> micro;
typedef ratio<1LL, 1000LL> milli;
typedef ratio<1LL, 100LL> centi;
typedef ratio<1LL, 10LL> deci;
typedef ratio< 10LL, 1LL> deca;
typedef ratio< 100LL, 1LL> hecto;
typedef ratio< 1000LL, 1LL> kilo;
typedef ratio< 1000000LL, 1LL> mega;
typedef ratio< 1000000000LL, 1LL> giga;
typedef ratio< 1000000000000LL, 1LL> tera;
typedef ratio< 1000000000000000LL, 1LL> peta;
typedef ratio<1000000000000000000LL, 1LL> exa;
template <class _R1, class _R2>
struct __ratio_multiply
{
private:
static const intmax_t __gcd_n1_d2 = __static_gcd<_R1::num, _R2::den>::value;
static const intmax_t __gcd_d1_n2 = __static_gcd<_R1::den, _R2::num>::value;
public:
typedef typename ratio
<
__ll_mul<_R1::num / __gcd_n1_d2, _R2::num / __gcd_d1_n2>::value,
__ll_mul<_R2::den / __gcd_n1_d2, _R1::den / __gcd_d1_n2>::value
>::type type;
};
# 312 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_multiply
: public __ratio_multiply<_R1, _R2>::type {};
template <class _R1, class _R2>
struct __ratio_divide
{
private:
static const intmax_t __gcd_n1_n2 = __static_gcd<_R1::num, _R2::num>::value;
static const intmax_t __gcd_d1_d2 = __static_gcd<_R1::den, _R2::den>::value;
public:
typedef typename ratio
<
__ll_mul<_R1::num / __gcd_n1_n2, _R2::den / __gcd_d1_d2>::value,
__ll_mul<_R2::num / __gcd_n1_n2, _R1::den / __gcd_d1_d2>::value
>::type type;
};
# 339 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_divide
: public __ratio_divide<_R1, _R2>::type {};
template <class _R1, class _R2>
struct __ratio_add
{
private:
static const intmax_t __gcd_n1_n2 = __static_gcd<_R1::num, _R2::num>::value;
static const intmax_t __gcd_d1_d2 = __static_gcd<_R1::den, _R2::den>::value;
public:
typedef typename ratio_multiply
<
ratio<__gcd_n1_n2, _R1::den / __gcd_d1_d2>,
ratio
<
__ll_add
<
__ll_mul<_R1::num / __gcd_n1_n2, _R2::den / __gcd_d1_d2>::value,
__ll_mul<_R2::num / __gcd_n1_n2, _R1::den / __gcd_d1_d2>::value
>::value,
_R2::den
>
>::type type;
};
# 374 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_add
: public __ratio_add<_R1, _R2>::type {};
template <class _R1, class _R2>
struct __ratio_subtract
{
private:
static const intmax_t __gcd_n1_n2 = __static_gcd<_R1::num, _R2::num>::value;
static const intmax_t __gcd_d1_d2 = __static_gcd<_R1::den, _R2::den>::value;
public:
typedef typename ratio_multiply
<
ratio<__gcd_n1_n2, _R1::den / __gcd_d1_d2>,
ratio
<
__ll_sub
<
__ll_mul<_R1::num / __gcd_n1_n2, _R2::den / __gcd_d1_d2>::value,
__ll_mul<_R2::num / __gcd_n1_n2, _R1::den / __gcd_d1_d2>::value
>::value,
_R2::den
>
>::type type;
};
# 409 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_subtract
: public __ratio_subtract<_R1, _R2>::type {};
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_equal
: public integral_constant<bool,((_R1::num == _R2::num && _R1::den == _R2::den))> {};
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_not_equal
: public integral_constant<bool,((!ratio_equal<_R1, _R2>::value))> {};
template <class _R1, class _R2, bool _Odd = false,
intmax_t _Q1 = _R1::num / _R1::den, intmax_t _M1 = _R1::num % _R1::den,
intmax_t _Q2 = _R2::num / _R2::den, intmax_t _M2 = _R2::num % _R2::den>
struct __ratio_less1
{
static const bool value = _Odd ? _Q2 < _Q1 : _Q1 < _Q2;
};
template <class _R1, class _R2, bool _Odd, intmax_t _Qp>
struct __ratio_less1<_R1, _R2, _Odd, _Qp, 0, _Qp, 0>
{
static const bool value = false;
};
template <class _R1, class _R2, bool _Odd, intmax_t _Qp, intmax_t _M2>
struct __ratio_less1<_R1, _R2, _Odd, _Qp, 0, _Qp, _M2>
{
static const bool value = !_Odd;
};
template <class _R1, class _R2, bool _Odd, intmax_t _Qp, intmax_t _M1>
struct __ratio_less1<_R1, _R2, _Odd, _Qp, _M1, _Qp, 0>
{
static const bool value = _Odd;
};
template <class _R1, class _R2, bool _Odd, intmax_t _Qp, intmax_t _M1,
intmax_t _M2>
struct __ratio_less1<_R1, _R2, _Odd, _Qp, _M1, _Qp, _M2>
{
static const bool value = __ratio_less1<ratio<_R1::den, _M1>,
ratio<_R2::den, _M2>, !_Odd>::value;
};
template <class _R1, class _R2, intmax_t _S1 = __static_sign<_R1::num>::value,
intmax_t _S2 = __static_sign<_R2::num>::value>
struct __ratio_less
{
static const bool value = _S1 < _S2;
};
template <class _R1, class _R2>
struct __ratio_less<_R1, _R2, 1LL, 1LL>
{
static const bool value = __ratio_less1<_R1, _R2>::value;
};
template <class _R1, class _R2>
struct __ratio_less<_R1, _R2, -1LL, -1LL>
{
static const bool value = __ratio_less1<ratio<-_R2::num, _R2::den>, ratio<-_R1::num, _R1::den> >::value;
};
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_less
: public integral_constant<bool,((__ratio_less<_R1, _R2>::value))> {};
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_less_equal
: public integral_constant<bool,((!ratio_less<_R2, _R1>::value))> {};
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_greater
: public integral_constant<bool,((ratio_less<_R2, _R1>::value))> {};
template <class _R1, class _R2>
struct __attribute__ ((__type_visibility__("default"))) ratio_greater_equal
: public integral_constant<bool,((!ratio_less<_R1, _R2>::value))> {};
template <class _R1, class _R2>
struct __ratio_gcd
{
typedef ratio<__static_gcd<_R1::num, _R2::num>::value,
__static_lcm<_R1::den, _R2::den>::value> type;
};
# 529 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ratio" 3
} }
# 306 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 2 3
# 310 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 314 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 2 3
namespace std {inline namespace __1 {
namespace chrono
{
template <class _Rep, class _Period = ratio<1> > class __attribute__ ((__type_visibility__("default"))) duration;
template <class _Tp>
struct __is_duration : false_type {};
template <class _Rep, class _Period>
struct __is_duration<duration<_Rep, _Period> > : true_type {};
template <class _Rep, class _Period>
struct __is_duration<const duration<_Rep, _Period> > : true_type {};
template <class _Rep, class _Period>
struct __is_duration<volatile duration<_Rep, _Period> > : true_type {};
template <class _Rep, class _Period>
struct __is_duration<const volatile duration<_Rep, _Period> > : true_type {};
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
struct __attribute__ ((__type_visibility__("default"))) common_type<chrono::duration<_Rep1, _Period1>,
chrono::duration<_Rep2, _Period2> >
{
typedef chrono::duration<typename common_type<_Rep1, _Rep2>::type,
typename __ratio_gcd<_Period1, _Period2>::type> type;
};
namespace chrono {
template <class _FromDuration, class _ToDuration,
class _Period = typename ratio_divide<typename _FromDuration::period, typename _ToDuration::period>::type,
bool = _Period::num == 1,
bool = _Period::den == 1>
struct __duration_cast;
template <class _FromDuration, class _ToDuration, class _Period>
struct __duration_cast<_FromDuration, _ToDuration, _Period, true, true>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_ToDuration operator()(const _FromDuration& __fd) const
{
return _ToDuration(static_cast<typename _ToDuration::rep>(__fd.count()));
}
};
template <class _FromDuration, class _ToDuration, class _Period>
struct __duration_cast<_FromDuration, _ToDuration, _Period, true, false>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_ToDuration operator()(const _FromDuration& __fd) const
{
typedef typename common_type<typename _ToDuration::rep, typename _FromDuration::rep, intmax_t>::type _Ct;
return _ToDuration(static_cast<typename _ToDuration::rep>(
static_cast<_Ct>(__fd.count()) / static_cast<_Ct>(_Period::den)));
}
};
template <class _FromDuration, class _ToDuration, class _Period>
struct __duration_cast<_FromDuration, _ToDuration, _Period, false, true>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_ToDuration operator()(const _FromDuration& __fd) const
{
typedef typename common_type<typename _ToDuration::rep, typename _FromDuration::rep, intmax_t>::type _Ct;
return _ToDuration(static_cast<typename _ToDuration::rep>(
static_cast<_Ct>(__fd.count()) * static_cast<_Ct>(_Period::num)));
}
};
template <class _FromDuration, class _ToDuration, class _Period>
struct __duration_cast<_FromDuration, _ToDuration, _Period, false, false>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_ToDuration operator()(const _FromDuration& __fd) const
{
typedef typename common_type<typename _ToDuration::rep, typename _FromDuration::rep, intmax_t>::type _Ct;
return _ToDuration(static_cast<typename _ToDuration::rep>(
static_cast<_Ct>(__fd.count()) * static_cast<_Ct>(_Period::num)
/ static_cast<_Ct>(_Period::den)));
}
};
template <class _ToDuration, class _Rep, class _Period>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
__is_duration<_ToDuration>::value,
_ToDuration
>::type
duration_cast(const duration<_Rep, _Period>& __fd)
{
return __duration_cast<duration<_Rep, _Period>, _ToDuration>()(__fd);
}
template <class _Rep>
struct __attribute__ ((__type_visibility__("default"))) treat_as_floating_point : is_floating_point<_Rep> {};
template <class _Rep>
struct __attribute__ ((__type_visibility__("default"))) duration_values
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) static _Rep zero() {return _Rep(0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static _Rep max() {return numeric_limits<_Rep>::max();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static _Rep min() {return numeric_limits<_Rep>::lowest();}
};
# 490 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 3
template <class _Rep, class _Period>
class __attribute__ ((__type_visibility__("default"))) duration
{
_Static_assert(!__is_duration<_Rep>::value, "A duration representation can not be a duration");
_Static_assert(__is_ratio<_Period>::value, "Second template parameter of duration must be a std::ratio");
_Static_assert(_Period::num > 0, "duration period must be positive");
template <class _R1, class _R2>
struct __no_overflow
{
private:
static const intmax_t __gcd_n1_n2 = __static_gcd<_R1::num, _R2::num>::value;
static const intmax_t __gcd_d1_d2 = __static_gcd<_R1::den, _R2::den>::value;
static const intmax_t __n1 = _R1::num / __gcd_n1_n2;
static const intmax_t __d1 = _R1::den / __gcd_d1_d2;
static const intmax_t __n2 = _R2::num / __gcd_n1_n2;
static const intmax_t __d2 = _R2::den / __gcd_d1_d2;
static const intmax_t max = -((intmax_t(1) << (sizeof(intmax_t) * 8 - 1)) + 1);
template <intmax_t _Xp, intmax_t _Yp, bool __overflow>
struct __mul
{
static const intmax_t value = _Xp * _Yp;
};
template <intmax_t _Xp, intmax_t _Yp>
struct __mul<_Xp, _Yp, true>
{
static const intmax_t value = 1;
};
public:
static const bool value = (__n1 <= max / __d2) && (__n2 <= max / __d1);
typedef ratio<__mul<__n1, __d2, !value>::value,
__mul<__n2, __d1, !value>::value> type;
};
public:
typedef _Rep rep;
typedef typename _Period::type period;
private:
rep __rep_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
duration() {}
template <class _Rep2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit duration(const _Rep2& __r,
typename enable_if
<
is_convertible<_Rep2, rep>::value &&
(treat_as_floating_point<rep>::value ||
!treat_as_floating_point<_Rep2>::value)
>::type* = 0)
: __rep_(__r) {}
template <class _Rep2, class _Period2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
duration(const duration<_Rep2, _Period2>& __d,
typename enable_if
<
__no_overflow<_Period2, period>::value && (
treat_as_floating_point<rep>::value ||
(__no_overflow<_Period2, period>::type::den == 1 &&
!treat_as_floating_point<_Rep2>::value))
>::type* = 0)
: __rep_(std::__1::chrono::duration_cast<duration>(__d).count()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) rep count() const {return __rep_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) typename common_type<duration>::type operator+() const {return typename common_type<duration>::type(*this);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) typename common_type<duration>::type operator-() const {return typename common_type<duration>::type(-__rep_);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator++() {++__rep_; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration operator++(int) {return duration(__rep_++);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator--() {--__rep_; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration operator--(int) {return duration(__rep_--);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator+=(const duration& __d) {__rep_ += __d.count(); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator-=(const duration& __d) {__rep_ -= __d.count(); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator*=(const rep& rhs) {__rep_ *= rhs; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator/=(const rep& rhs) {__rep_ /= rhs; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator%=(const rep& rhs) {__rep_ %= rhs; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration& operator%=(const duration& rhs) {__rep_ %= rhs.count(); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static duration zero() {return duration(duration_values<rep>::zero());}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static duration min() {return duration(duration_values<rep>::min());}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static duration max() {return duration(duration_values<rep>::max());}
};
typedef duration<long long, nano> nanoseconds;
typedef duration<long long, micro> microseconds;
typedef duration<long long, milli> milliseconds;
typedef duration<long long > seconds;
typedef duration< long, ratio< 60> > minutes;
typedef duration< long, ratio<3600> > hours;
template <class _LhsDuration, class _RhsDuration>
struct __duration_eq
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _LhsDuration& __lhs, const _RhsDuration& __rhs) const
{
typedef typename common_type<_LhsDuration, _RhsDuration>::type _Ct;
return _Ct(__lhs).count() == _Ct(__rhs).count();
}
};
template <class _LhsDuration>
struct __duration_eq<_LhsDuration, _LhsDuration>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _LhsDuration& __lhs, const _LhsDuration& __rhs) const
{return __lhs.count() == __rhs.count();}
};
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
return __duration_eq<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >()(__lhs, __rhs);
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
return !(__lhs == __rhs);
}
template <class _LhsDuration, class _RhsDuration>
struct __duration_lt
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _LhsDuration& __lhs, const _RhsDuration& __rhs) const
{
typedef typename common_type<_LhsDuration, _RhsDuration>::type _Ct;
return _Ct(__lhs).count() < _Ct(__rhs).count();
}
};
template <class _LhsDuration>
struct __duration_lt<_LhsDuration, _LhsDuration>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _LhsDuration& __lhs, const _LhsDuration& __rhs) const
{return __lhs.count() < __rhs.count();}
};
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator< (const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
return __duration_lt<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >()(__lhs, __rhs);
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator> (const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
return __rhs < __lhs;
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
return !(__rhs < __lhs);
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
return !(__lhs < __rhs);
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type
operator+(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
typedef typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type _Cd;
return _Cd(_Cd(__lhs).count() + _Cd(__rhs).count());
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type
operator-(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
typedef typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type _Cd;
return _Cd(_Cd(__lhs).count() - _Cd(__rhs).count());
}
template <class _Rep1, class _Period, class _Rep2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_convertible<_Rep2, typename common_type<_Rep1, _Rep2>::type>::value,
duration<typename common_type<_Rep1, _Rep2>::type, _Period>
>::type
operator*(const duration<_Rep1, _Period>& __d, const _Rep2& __s)
{
typedef typename common_type<_Rep1, _Rep2>::type _Cr;
typedef duration<_Cr, _Period> _Cd;
return _Cd(_Cd(__d).count() * static_cast<_Cr>(__s));
}
template <class _Rep1, class _Period, class _Rep2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_convertible<_Rep1, typename common_type<_Rep1, _Rep2>::type>::value,
duration<typename common_type<_Rep1, _Rep2>::type, _Period>
>::type
operator*(const _Rep1& __s, const duration<_Rep2, _Period>& __d)
{
return __d * __s;
}
template <class _Duration, class _Rep, bool = __is_duration<_Rep>::value>
struct __duration_divide_result
{
};
template <class _Duration, class _Rep2,
bool = is_convertible<_Rep2,
typename common_type<typename _Duration::rep, _Rep2>::type>::value>
struct __duration_divide_imp
{
};
template <class _Rep1, class _Period, class _Rep2>
struct __duration_divide_imp<duration<_Rep1, _Period>, _Rep2, true>
{
typedef duration<typename common_type<_Rep1, _Rep2>::type, _Period> type;
};
template <class _Rep1, class _Period, class _Rep2>
struct __duration_divide_result<duration<_Rep1, _Period>, _Rep2, false>
: __duration_divide_imp<duration<_Rep1, _Period>, _Rep2>
{
};
template <class _Rep1, class _Period, class _Rep2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __duration_divide_result<duration<_Rep1, _Period>, _Rep2>::type
operator/(const duration<_Rep1, _Period>& __d, const _Rep2& __s)
{
typedef typename common_type<_Rep1, _Rep2>::type _Cr;
typedef duration<_Cr, _Period> _Cd;
return _Cd(_Cd(__d).count() / static_cast<_Cr>(__s));
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename common_type<_Rep1, _Rep2>::type
operator/(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
typedef typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type _Ct;
return _Ct(__lhs).count() / _Ct(__rhs).count();
}
template <class _Rep1, class _Period, class _Rep2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __duration_divide_result<duration<_Rep1, _Period>, _Rep2>::type
operator%(const duration<_Rep1, _Period>& __d, const _Rep2& __s)
{
typedef typename common_type<_Rep1, _Rep2>::type _Cr;
typedef duration<_Cr, _Period> _Cd;
return _Cd(_Cd(__d).count() % static_cast<_Cr>(__s));
}
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type
operator%(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
typedef typename common_type<_Rep1, _Rep2>::type _Cr;
typedef typename common_type<duration<_Rep1, _Period1>, duration<_Rep2, _Period2> >::type _Cd;
return _Cd(static_cast<_Cr>(_Cd(__lhs).count()) % static_cast<_Cr>(_Cd(__rhs).count()));
}
template <class _Clock, class _Duration = typename _Clock::duration>
class __attribute__ ((__type_visibility__("default"))) time_point
{
_Static_assert(__is_duration<_Duration>::value, "Second template parameter of time_point must be a std::chrono::duration");
public:
typedef _Clock clock;
typedef _Duration duration;
typedef typename duration::rep rep;
typedef typename duration::period period;
private:
duration __d_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) time_point() : __d_(duration::zero()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit time_point(const duration& __d) : __d_(__d) {}
template <class _Duration2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
time_point(const time_point<clock, _Duration2>& t,
typename enable_if
<
is_convertible<_Duration2, duration>::value
>::type* = 0)
: __d_(t.time_since_epoch()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) duration time_since_epoch() const {return __d_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) time_point& operator+=(const duration& __d) {__d_ += __d; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) time_point& operator-=(const duration& __d) {__d_ -= __d; return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static time_point min() {return time_point(duration::min());}
__attribute__ ((__visibility__("hidden"), __always_inline__)) static time_point max() {return time_point(duration::max());}
};
}
template <class _Clock, class _Duration1, class _Duration2>
struct __attribute__ ((__type_visibility__("default"))) common_type<chrono::time_point<_Clock, _Duration1>,
chrono::time_point<_Clock, _Duration2> >
{
typedef chrono::time_point<_Clock, typename common_type<_Duration1, _Duration2>::type> type;
};
namespace chrono {
template <class _ToDuration, class _Clock, class _Duration>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
time_point<_Clock, _ToDuration>
time_point_cast(const time_point<_Clock, _Duration>& __t)
{
return time_point<_Clock, _ToDuration>(std::__1::chrono::duration_cast<_ToDuration>(__t.time_since_epoch()));
}
# 946 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 3
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return __lhs.time_since_epoch() == __rhs.time_since_epoch();
}
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return !(__lhs == __rhs);
}
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return __lhs.time_since_epoch() < __rhs.time_since_epoch();
}
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return __rhs < __lhs;
}
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<=(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return !(__rhs < __lhs);
}
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator>=(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return !(__lhs < __rhs);
}
template <class _Clock, class _Duration1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type>
operator+(const time_point<_Clock, _Duration1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
typedef time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type> _Tr;
return _Tr (__lhs.time_since_epoch() + __rhs);
}
template <class _Rep1, class _Period1, class _Clock, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
time_point<_Clock, typename common_type<duration<_Rep1, _Period1>, _Duration2>::type>
operator+(const duration<_Rep1, _Period1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return __rhs + __lhs;
}
template <class _Clock, class _Duration1, class _Rep2, class _Period2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type>
operator-(const time_point<_Clock, _Duration1>& __lhs, const duration<_Rep2, _Period2>& __rhs)
{
typedef time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type> _Ret;
return _Ret(__lhs.time_since_epoch() -__rhs);
}
template <class _Clock, class _Duration1, class _Duration2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename common_type<_Duration1, _Duration2>::type
operator-(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs)
{
return __lhs.time_since_epoch() - __rhs.time_since_epoch();
}
class __attribute__ ((__visibility__("default"))) system_clock
{
public:
typedef microseconds duration;
typedef duration::rep rep;
typedef duration::period period;
typedef chrono::time_point<system_clock> time_point;
static const bool is_steady = false;
static time_point now() throw();
static time_t to_time_t (const time_point& __t) throw();
static time_point from_time_t(time_t __t) throw();
};
class __attribute__ ((__visibility__("default"))) steady_clock
{
public:
typedef nanoseconds duration;
typedef duration::rep rep;
typedef duration::period period;
typedef chrono::time_point<steady_clock, duration> time_point;
static const bool is_steady = true;
static time_point now() throw();
};
typedef steady_clock high_resolution_clock;
}
# 1164 "/Library/Developer/CommandLineTools/usr/include/c++/v1/chrono" 3
} }
# 16 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/system_error" 1 3
# 229 "/Library/Developer/CommandLineTools/usr/include/c++/v1/system_error" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cerrno" 1 3
# 27 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cerrno" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/errno.h" 1 3
# 30 "/Library/Developer/CommandLineTools/usr/include/c++/v1/errno.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/errno.h" 1 3 4
# 23 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/errno.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/errno.h" 1 3 4
# 79 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/errno.h" 3 4
extern "C" {
extern int * __error(void);
}
# 24 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/errno.h" 2 3 4
# 33 "/Library/Developer/CommandLineTools/usr/include/c++/v1/errno.h" 2 3
# 28 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cerrno" 2 3
# 31 "/Library/Developer/CommandLineTools/usr/include/c++/v1/cerrno" 3
# 230 "/Library/Developer/CommandLineTools/usr/include/c++/v1/system_error" 2 3
# 237 "/Library/Developer/CommandLineTools/usr/include/c++/v1/system_error" 3
namespace std {inline namespace __1 {
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_error_code_enum
: public false_type {};
# 254 "/Library/Developer/CommandLineTools/usr/include/c++/v1/system_error" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) is_error_condition_enum
: public false_type {};
# 267 "/Library/Developer/CommandLineTools/usr/include/c++/v1/system_error" 3
struct __attribute__ ((__visibility__("default"))) errc { enum __lx
{
address_family_not_supported = 47,
address_in_use = 48,
address_not_available = 49,
already_connected = 56,
argument_list_too_long = 7,
argument_out_of_domain = 33,
bad_address = 14,
bad_file_descriptor = 9,
bad_message = 94,
broken_pipe = 32,
connection_aborted = 53,
connection_already_in_progress = 37,
connection_refused = 61,
connection_reset = 54,
cross_device_link = 18,
destination_address_required = 39,
device_or_resource_busy = 16,
directory_not_empty = 66,
executable_format_error = 8,
file_exists = 17,
file_too_large = 27,
filename_too_long = 63,
function_not_supported = 78,
host_unreachable = 65,
identifier_removed = 90,
illegal_byte_sequence = 92,
inappropriate_io_control_operation = 25,
interrupted = 4,
invalid_argument = 22,
invalid_seek = 29,
io_error = 5,
is_a_directory = 21,
message_size = 40,
network_down = 50,
network_reset = 52,
network_unreachable = 51,
no_buffer_space = 55,
no_child_process = 10,
no_link = 97,
no_lock_available = 77,
no_message_available = 96,
no_message = 91,
no_protocol_option = 42,
no_space_on_device = 28,
no_stream_resources = 98,
no_such_device_or_address = 6,
no_such_device = 19,
no_such_file_or_directory = 2,
no_such_process = 3,
not_a_directory = 20,
not_a_socket = 38,
not_a_stream = 99,
not_connected = 57,
not_enough_memory = 12,
not_supported = 45,
operation_canceled = 89,
operation_in_progress = 36,
operation_not_permitted = 1,
operation_not_supported = 102,
operation_would_block = 35,
owner_dead = 105,
permission_denied = 13,
protocol_error = 100,
protocol_not_supported = 43,
read_only_file_system = 30,
resource_deadlock_would_occur = 11,
resource_unavailable_try_again = 35,
result_out_of_range = 34,
state_not_recoverable = 104,
stream_timeout = 101,
text_file_busy = 26,
timed_out = 60,
too_many_files_open_in_system = 23,
too_many_files_open = 24,
too_many_links = 31,
too_many_symbolic_link_levels = 62,
value_too_large = 84,
wrong_protocol_type = 41
};
__lx __v_; __attribute__ ((__visibility__("hidden"), __always_inline__)) errc(__lx __v) : __v_(__v) {} __attribute__ ((__visibility__("hidden"), __always_inline__)) explicit errc(int __v) : __v_(static_cast<__lx>(__v)) {} __attribute__ ((__visibility__("hidden"), __always_inline__)) operator int() const {return __v_;} };
template <>
struct __attribute__ ((__type_visibility__("default"))) is_error_condition_enum<errc>
: true_type { };
template <>
struct __attribute__ ((__type_visibility__("default"))) is_error_condition_enum<errc::__lx>
: true_type { };
class __attribute__ ((__visibility__("default"))) error_condition;
class __attribute__ ((__visibility__("default"))) error_code;
class __attribute__ ((__visibility__("hidden"))) __do_message;
class __attribute__ ((__visibility__("default"))) error_category
{
public:
virtual ~error_category() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_category() throw() {}
private:
error_category(const error_category&);
error_category& operator=(const error_category&);
public:
virtual const char* name() const throw() = 0;
virtual error_condition default_error_condition(int __ev) const throw();
virtual bool equivalent(int __code, const error_condition& __condition) const throw();
virtual bool equivalent(const error_code& __code, int __condition) const throw();
virtual string message(int __ev) const = 0;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const error_category& __rhs) const throw() {return this == &__rhs;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const error_category& __rhs) const throw() {return !(*this == __rhs);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator< (const error_category& __rhs) const throw() {return this < &__rhs;}
friend class __attribute__ ((__visibility__("hidden"))) __do_message;
};
class __attribute__ ((__visibility__("hidden"))) __do_message
: public error_category
{
public:
virtual string message(int ev) const;
};
__attribute__ ((__visibility__("default"))) const error_category& generic_category() throw();
__attribute__ ((__visibility__("default"))) const error_category& system_category() throw();
class __attribute__ ((__visibility__("default"))) error_condition
{
int __val_;
const error_category* __cat_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_condition() throw() : __val_(0), __cat_(&generic_category()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_condition(int __val, const error_category& __cat) throw()
: __val_(__val), __cat_(&__cat) {}
template <class _Ep>
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_condition(_Ep __e,
typename enable_if<is_error_condition_enum<_Ep>::value>::type* = 0
) throw()
{*this = make_error_condition(__e);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void assign(int __val, const error_category& __cat) throw()
{
__val_ = __val;
__cat_ = &__cat;
}
template <class _Ep>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_error_condition_enum<_Ep>::value,
error_condition&
>::type
operator=(_Ep __e) throw()
{*this = make_error_condition(__e); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void clear() throw()
{
__val_ = 0;
__cat_ = &generic_category();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int value() const throw() {return __val_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const error_category& category() const throw() {return *__cat_;}
string message() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const throw() {return __val_ != 0;}
};
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
error_condition
make_error_condition(errc __e) throw()
{
return error_condition(static_cast<int>(__e), generic_category());
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const error_condition& __x, const error_condition& __y) throw()
{
return __x.category() < __y.category()
|| (__x.category() == __y.category() && __x.value() < __y.value());
}
class __attribute__ ((__visibility__("default"))) error_code
{
int __val_;
const error_category* __cat_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_code() throw() : __val_(0), __cat_(&system_category()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_code(int __val, const error_category& __cat) throw()
: __val_(__val), __cat_(&__cat) {}
template <class _Ep>
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_code(_Ep __e,
typename enable_if<is_error_code_enum<_Ep>::value>::type* = 0
) throw()
{*this = make_error_code(__e);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void assign(int __val, const error_category& __cat) throw()
{
__val_ = __val;
__cat_ = &__cat;
}
template <class _Ep>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
is_error_code_enum<_Ep>::value,
error_code&
>::type
operator=(_Ep __e) throw()
{*this = make_error_code(__e); return *this;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void clear() throw()
{
__val_ = 0;
__cat_ = &system_category();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int value() const throw() {return __val_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const error_category& category() const throw() {return *__cat_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
error_condition default_error_condition() const throw()
{return __cat_->default_error_condition(__val_);}
string message() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const throw() {return __val_ != 0;}
};
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
error_code
make_error_code(errc __e) throw()
{
return error_code(static_cast<int>(__e), generic_category());
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator<(const error_code& __x, const error_code& __y) throw()
{
return __x.category() < __y.category()
|| (__x.category() == __y.category() && __x.value() < __y.value());
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const error_code& __x, const error_code& __y) throw()
{
return __x.category() == __y.category() && __x.value() == __y.value();
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const error_code& __x, const error_condition& __y) throw()
{
return __x.category().equivalent(__x.value(), __y)
|| __y.category().equivalent(__x, __y.value());
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const error_condition& __x, const error_code& __y) throw()
{
return __y == __x;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const error_condition& __x, const error_condition& __y) throw()
{
return __x.category() == __y.category() && __x.value() == __y.value();
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const error_code& __x, const error_code& __y) throw()
{return !(__x == __y);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const error_code& __x, const error_condition& __y) throw()
{return !(__x == __y);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const error_condition& __x, const error_code& __y) throw()
{return !(__x == __y);}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const error_condition& __x, const error_condition& __y) throw()
{return !(__x == __y);}
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<error_code>
: public unary_function<error_code, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(const error_code& __ec) const throw()
{
return static_cast<size_t>(__ec.value());
}
};
template <>
struct __attribute__ ((__type_visibility__("default"))) hash<error_condition>
: public unary_function<error_condition, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(const error_condition& __ec) const throw()
{
return static_cast<size_t>(__ec.value());
}
};
class __attribute__ ((__visibility__("default"))) system_error
: public runtime_error
{
error_code __ec_;
public:
system_error(error_code __ec, const string& __what_arg);
system_error(error_code __ec, const char* __what_arg);
system_error(error_code __ec);
system_error(int __ev, const error_category& __ecat, const string& __what_arg);
system_error(int __ev, const error_category& __ecat, const char* __what_arg);
system_error(int __ev, const error_category& __ecat);
~system_error() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
const error_code& code() const throw() {return __ec_;}
private:
static string __init(const error_code&, string);
};
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default")))
void __throw_system_error(int ev, const char* what_arg);
} }
# 17 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 1 3
# 20 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 1 3 4
# 57 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/pthread_impl.h" 1 3 4
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/pthread_impl.h" 3 4
#pragma clang assume_nonnull begin
#pragma clang assume_nonnull end
# 58 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/sched.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/sched.h" 3 4
extern "C" {
struct sched_param { int sched_priority; char __opaque[4]; };
extern int sched_yield(void);
extern int sched_get_priority_min(int);
extern int sched_get_priority_max(int);
}
# 60 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_cond_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_cond_t.h" 3 4
typedef __darwin_pthread_cond_t pthread_cond_t;
# 64 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_condattr_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_condattr_t.h" 3 4
typedef __darwin_pthread_condattr_t pthread_condattr_t;
# 65 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_key_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_key_t.h" 3 4
typedef __darwin_pthread_key_t pthread_key_t;
# 66 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_mutex_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_mutex_t.h" 3 4
typedef __darwin_pthread_mutex_t pthread_mutex_t;
# 67 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_mutexattr_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_mutexattr_t.h" 3 4
typedef __darwin_pthread_mutexattr_t pthread_mutexattr_t;
# 68 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_once_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_once_t.h" 3 4
typedef __darwin_pthread_once_t pthread_once_t;
# 69 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_rwlock_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_rwlock_t.h" 3 4
typedef __darwin_pthread_rwlock_t pthread_rwlock_t;
# 70 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_rwlockattr_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_rwlockattr_t.h" 3 4
typedef __darwin_pthread_rwlockattr_t pthread_rwlockattr_t;
# 71 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_pthread/_pthread_t.h" 3 4
typedef __darwin_pthread_t pthread_t;
# 72 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 1 3 4
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/qos.h" 1 3 4
# 128 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/qos.h" 3 4
enum { QOS_CLASS_USER_INTERACTIVE __attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0))) = 0x21, QOS_CLASS_USER_INITIATED __attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0))) = 0x19, QOS_CLASS_DEFAULT __attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0))) = 0x15, QOS_CLASS_UTILITY __attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0))) = 0x11, QOS_CLASS_BACKGROUND __attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0))) = 0x09, QOS_CLASS_UNSPECIFIED __attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0))) = 0x00, }; typedef unsigned int qos_class_t;
# 157 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/qos.h" 3 4
extern "C" {
# 168 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
qos_class_t
qos_class_self(void);
# 190 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
qos_class_t
qos_class_main(void);
}
# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 2 3 4
#pragma clang assume_nonnull begin
extern "C" {
# 81 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
int
pthread_attr_set_qos_class_np(pthread_attr_t *__attr,
qos_class_t __qos_class, int __relative_priority);
# 112 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
int
pthread_attr_get_qos_class_np(pthread_attr_t * __attr,
qos_class_t * _Nullable __qos_class,
int * _Nullable __relative_priority);
# 153 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
int
pthread_set_qos_class_self_np(qos_class_t __qos_class,
int __relative_priority);
# 184 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
int
pthread_get_qos_class_np(pthread_t __pthread,
qos_class_t * _Nullable __qos_class,
int * _Nullable __relative_priority);
# 211 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
typedef struct pthread_override_s* pthread_override_t;
# 263 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
pthread_override_t
pthread_override_qos_class_start_np(pthread_t __pthread,
qos_class_t __qos_class, int __relative_priority);
# 291 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread/qos.h" 3 4
__attribute__((availability(macos,introduced=10.10))) __attribute__((availability(ios,introduced=8.0)))
int
pthread_override_qos_class_end_np(pthread_override_t __override);
}
#pragma clang assume_nonnull end
# 74 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_mach_port_t.h" 1 3 4
# 50 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_mach_port_t.h" 3 4
typedef __darwin_mach_port_t mach_port_t;
# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 2 3 4
# 106 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 3 4
#pragma clang assume_nonnull begin
extern "C" {
# 221 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/pthread.h" 3 4
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_atfork(void (* _Nullable)(void), void (* _Nullable)(void),
void (* _Nullable)(void));
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_destroy(pthread_attr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getdetachstate(const pthread_attr_t *, int *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getguardsize(const pthread_attr_t * , size_t * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getinheritsched(const pthread_attr_t * , int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getschedparam(const pthread_attr_t * ,
struct sched_param * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getschedpolicy(const pthread_attr_t * , int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getscope(const pthread_attr_t * , int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getstack(const pthread_attr_t * ,
void * _Nullable * _Nonnull , size_t * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getstackaddr(const pthread_attr_t * ,
void * _Nullable * _Nonnull );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_getstacksize(const pthread_attr_t * , size_t * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_init(pthread_attr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setdetachstate(pthread_attr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setguardsize(pthread_attr_t *, size_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setinheritsched(pthread_attr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setschedparam(pthread_attr_t * ,
const struct sched_param * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setschedpolicy(pthread_attr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setscope(pthread_attr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setstack(pthread_attr_t *, void *, size_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setstackaddr(pthread_attr_t *, void *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_attr_setstacksize(pthread_attr_t *, size_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cancel(pthread_t) __asm("_" "pthread_cancel" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_broadcast(pthread_cond_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_destroy(pthread_cond_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_init(
pthread_cond_t * ,
const pthread_condattr_t * _Nullable )
__asm("_" "pthread_cond_init" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_signal(pthread_cond_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_timedwait(
pthread_cond_t * , pthread_mutex_t * ,
const struct timespec * _Nullable )
__asm("_" "pthread_cond_timedwait" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_wait(pthread_cond_t * ,
pthread_mutex_t * ) __asm("_" "pthread_cond_wait" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_condattr_destroy(pthread_condattr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_condattr_init(pthread_condattr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_condattr_getpshared(const pthread_condattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_condattr_setpshared(pthread_condattr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_create(pthread_t _Nullable * _Nonnull ,
const pthread_attr_t * _Nullable ,
void * _Nullable (* _Nonnull)(void * _Nullable),
void * _Nullable );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_detach(pthread_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_equal(pthread_t _Nullable, pthread_t _Nullable);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
void pthread_exit(void * _Nullable) __attribute__((noreturn));
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_getconcurrency(void);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_getschedparam(pthread_t , int * _Nullable ,
struct sched_param * _Nullable );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
void* _Nullable pthread_getspecific(pthread_key_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_join(pthread_t , void * _Nullable * _Nullable)
__asm("_" "pthread_join" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_key_create(pthread_key_t *, void (* _Nullable)(void *));
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_key_delete(pthread_key_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_destroy(pthread_mutex_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_getprioceiling(const pthread_mutex_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_init(pthread_mutex_t * ,
const pthread_mutexattr_t * _Nullable );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_lock(pthread_mutex_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_setprioceiling(pthread_mutex_t * , int,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_trylock(pthread_mutex_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutex_unlock(pthread_mutex_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_destroy(pthread_mutexattr_t *) __asm("_" "pthread_mutexattr_destroy" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_getprioceiling(const pthread_mutexattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_getprotocol(const pthread_mutexattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_getpshared(const pthread_mutexattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_gettype(const pthread_mutexattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.13.4))) __attribute__((availability(ios,introduced=11.3))) __attribute__((availability(watchos,introduced=4.3))) __attribute__((availability(tvos,introduced=11.3)))
int pthread_mutexattr_getpolicy_np(const pthread_mutexattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_init(pthread_mutexattr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_setprotocol(pthread_mutexattr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_setpshared(pthread_mutexattr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_mutexattr_settype(pthread_mutexattr_t *, int);
__attribute__((availability(macos,introduced=10.7))) __attribute__((availability(ios,introduced=5.0)))
int pthread_mutexattr_setpolicy_np(pthread_mutexattr_t *, int);
__attribute__((availability(swift,unavailable,message="Use lazily initialized globals instead")))
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_once(pthread_once_t *, void (* _Nonnull)(void));
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_destroy(pthread_rwlock_t * ) __asm("_" "pthread_rwlock_destroy" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_init(pthread_rwlock_t * ,
const pthread_rwlockattr_t * _Nullable )
__asm("_" "pthread_rwlock_init" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_rdlock(pthread_rwlock_t *) __asm("_" "pthread_rwlock_rdlock" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_tryrdlock(pthread_rwlock_t *) __asm("_" "pthread_rwlock_tryrdlock" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_trywrlock(pthread_rwlock_t *) __asm("_" "pthread_rwlock_trywrlock" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_wrlock(pthread_rwlock_t *) __asm("_" "pthread_rwlock_wrlock" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlock_unlock(pthread_rwlock_t *) __asm("_" "pthread_rwlock_unlock" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlockattr_destroy(pthread_rwlockattr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlockattr_getpshared(const pthread_rwlockattr_t * ,
int * );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlockattr_init(pthread_rwlockattr_t *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_rwlockattr_setpshared(pthread_rwlockattr_t *, int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
pthread_t pthread_self(void);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_setcancelstate(int , int * _Nullable)
__asm("_" "pthread_setcancelstate" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_setcanceltype(int , int * _Nullable)
__asm("_" "pthread_setcanceltype" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_setconcurrency(int);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_setschedparam(pthread_t, int, const struct sched_param *);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_setspecific(pthread_key_t , const void * _Nullable);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
void pthread_testcancel(void) __asm("_" "pthread_testcancel" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_is_threaded_np(void);
__attribute__((availability(macos,introduced=10.6))) __attribute__((availability(ios,introduced=3.2)))
int pthread_threadid_np(pthread_t _Nullable,__uint64_t* _Nullable);
__attribute__((availability(macos,introduced=10.6))) __attribute__((availability(ios,introduced=3.2)))
int pthread_getname_np(pthread_t,char*,size_t);
__attribute__((availability(macos,introduced=10.6))) __attribute__((availability(ios,introduced=3.2)))
int pthread_setname_np(const char*);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_main_np(void);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
mach_port_t pthread_mach_thread_np(pthread_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
size_t pthread_get_stacksize_np(pthread_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
void* pthread_get_stackaddr_np(pthread_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_signal_thread_np(pthread_cond_t *, pthread_t _Nullable);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_cond_timedwait_relative_np(pthread_cond_t *, pthread_mutex_t *,
const struct timespec * _Nullable);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_create_suspended_np(
pthread_t _Nullable * _Nonnull, const pthread_attr_t * _Nullable,
void * _Nullable (* _Nonnull)(void * _Nullable), void * _Nullable);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_kill(pthread_t, int);
__attribute__((availability(macos,introduced=10.5))) __attribute__((availability(ios,introduced=2.0)))
_Nullable pthread_t pthread_from_mach_thread_np(mach_port_t);
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
int pthread_sigmask(int, const sigset_t * _Nullable, sigset_t * _Nullable)
__asm("_" "pthread_sigmask" );
__attribute__((availability(macos,introduced=10.4))) __attribute__((availability(ios,introduced=2.0)))
void pthread_yield_np(void);
}
#pragma clang assume_nonnull end
# 28 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 37 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 2 3
# 52 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 3
namespace std {inline namespace __1 {
typedef pthread_mutex_t __libcpp_mutex_t;
typedef pthread_mutex_t __libcpp_recursive_mutex_t;
typedef pthread_cond_t __libcpp_condvar_t;
typedef pthread_once_t __libcpp_exec_once_flag;
typedef pthread_t __libcpp_thread_id;
typedef pthread_t __libcpp_thread_t;
typedef pthread_key_t __libcpp_tls_key;
# 111 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 3
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_recursive_mutex_init(__libcpp_recursive_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_recursive_mutex_lock(__libcpp_recursive_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool __libcpp_recursive_mutex_trylock(__libcpp_recursive_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_recursive_mutex_unlock(__libcpp_recursive_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_recursive_mutex_destroy(__libcpp_recursive_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_mutex_lock(__libcpp_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool __libcpp_mutex_trylock(__libcpp_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_mutex_unlock(__libcpp_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_mutex_destroy(__libcpp_mutex_t *__m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_condvar_signal(__libcpp_condvar_t* __cv);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_condvar_broadcast(__libcpp_condvar_t* __cv);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_condvar_wait(__libcpp_condvar_t* __cv, __libcpp_mutex_t* __m);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_condvar_timedwait(__libcpp_condvar_t *__cv, __libcpp_mutex_t *__m,
timespec *__ts);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_condvar_destroy(__libcpp_condvar_t* __cv);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_execute_once(__libcpp_exec_once_flag *flag,
void (*init_routine)(void));
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool __libcpp_thread_id_equal(__libcpp_thread_id t1, __libcpp_thread_id t2);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool __libcpp_thread_id_less(__libcpp_thread_id t1, __libcpp_thread_id t2);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool __libcpp_thread_isnull(const __libcpp_thread_t *__t);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_thread_create(__libcpp_thread_t *__t, void *(*__func)(void *),
void *__arg);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__libcpp_thread_id __libcpp_thread_get_current_id();
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__libcpp_thread_id __libcpp_thread_get_id(const __libcpp_thread_t *__t);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_thread_join(__libcpp_thread_t *__t);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_thread_detach(__libcpp_thread_t *__t);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __libcpp_thread_yield();
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __libcpp_thread_sleep_for(const chrono::nanoseconds& __ns);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_tls_create(__libcpp_tls_key* __key,
void(* __at_exit)(void*));
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void *__libcpp_tls_get(__libcpp_tls_key __key);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
int __libcpp_tls_set(__libcpp_tls_key __key, void *__p);
int __libcpp_recursive_mutex_init(__libcpp_recursive_mutex_t *__m)
{
pthread_mutexattr_t attr;
int __ec = pthread_mutexattr_init(&attr);
if (__ec)
return __ec;
__ec = pthread_mutexattr_settype(&attr, 2);
if (__ec) {
pthread_mutexattr_destroy(&attr);
return __ec;
}
__ec = pthread_mutex_init(__m, &attr);
if (__ec) {
pthread_mutexattr_destroy(&attr);
return __ec;
}
__ec = pthread_mutexattr_destroy(&attr);
if (__ec) {
pthread_mutex_destroy(__m);
return __ec;
}
return 0;
}
int __libcpp_recursive_mutex_lock(__libcpp_recursive_mutex_t *__m)
{
return pthread_mutex_lock(__m);
}
bool __libcpp_recursive_mutex_trylock(__libcpp_recursive_mutex_t *__m)
{
return pthread_mutex_trylock(__m) == 0;
}
int __libcpp_recursive_mutex_unlock(__libcpp_mutex_t *__m)
{
return pthread_mutex_unlock(__m);
}
int __libcpp_recursive_mutex_destroy(__libcpp_recursive_mutex_t *__m)
{
return pthread_mutex_destroy(__m);
}
int __libcpp_mutex_lock(__libcpp_mutex_t *__m)
{
return pthread_mutex_lock(__m);
}
bool __libcpp_mutex_trylock(__libcpp_mutex_t *__m)
{
return pthread_mutex_trylock(__m) == 0;
}
int __libcpp_mutex_unlock(__libcpp_mutex_t *__m)
{
return pthread_mutex_unlock(__m);
}
int __libcpp_mutex_destroy(__libcpp_mutex_t *__m)
{
return pthread_mutex_destroy(__m);
}
int __libcpp_condvar_signal(__libcpp_condvar_t *__cv)
{
return pthread_cond_signal(__cv);
}
int __libcpp_condvar_broadcast(__libcpp_condvar_t *__cv)
{
return pthread_cond_broadcast(__cv);
}
int __libcpp_condvar_wait(__libcpp_condvar_t *__cv, __libcpp_mutex_t *__m)
{
return pthread_cond_wait(__cv, __m);
}
int __libcpp_condvar_timedwait(__libcpp_condvar_t *__cv, __libcpp_mutex_t *__m,
timespec *__ts)
{
return pthread_cond_timedwait(__cv, __m, __ts);
}
int __libcpp_condvar_destroy(__libcpp_condvar_t *__cv)
{
return pthread_cond_destroy(__cv);
}
int __libcpp_execute_once(__libcpp_exec_once_flag *flag,
void (*init_routine)(void)) {
return pthread_once(flag, init_routine);
}
bool __libcpp_thread_id_equal(__libcpp_thread_id t1, __libcpp_thread_id t2)
{
return pthread_equal(t1, t2) != 0;
}
bool __libcpp_thread_id_less(__libcpp_thread_id t1, __libcpp_thread_id t2)
{
return t1 < t2;
}
bool __libcpp_thread_isnull(const __libcpp_thread_t *__t) {
return *__t == 0;
}
int __libcpp_thread_create(__libcpp_thread_t *__t, void *(*__func)(void *),
void *__arg)
{
# 336 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 3
return pthread_create(__t, 0, __func, __arg);
}
__libcpp_thread_id __libcpp_thread_get_current_id()
{
return pthread_self();
}
__libcpp_thread_id __libcpp_thread_get_id(const __libcpp_thread_t *__t)
{
return *__t;
}
int __libcpp_thread_join(__libcpp_thread_t *__t)
{
return pthread_join(*__t, 0);
}
int __libcpp_thread_detach(__libcpp_thread_t *__t)
{
return pthread_detach(*__t);
}
void __libcpp_thread_yield()
{
sched_yield();
}
void __libcpp_thread_sleep_for(const chrono::nanoseconds& __ns)
{
using namespace chrono;
seconds __s = duration_cast<seconds>(__ns);
timespec __ts;
typedef __decltype(__ts.tv_sec) ts_sec;
ts_sec __ts_sec_max = numeric_limits<ts_sec>::max();
if (__s.count() < __ts_sec_max)
{
__ts.tv_sec = static_cast<ts_sec>(__s.count());
__ts.tv_nsec = static_cast<__decltype(__ts.tv_nsec)>((__ns - __s).count());
}
else
{
__ts.tv_sec = __ts_sec_max;
__ts.tv_nsec = 999999999;
}
while (nanosleep(&__ts, &__ts) == -1 && (*__error()) == 4);
}
int __libcpp_tls_create(__libcpp_tls_key *__key, void (*__at_exit)(void *))
{
return pthread_key_create(__key, __at_exit);
}
void *__libcpp_tls_get(__libcpp_tls_key __key)
{
return pthread_getspecific(__key);
}
int __libcpp_tls_set(__libcpp_tls_key __key, void *__p)
{
return pthread_setspecific(__key, __p);
}
# 643 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__threading_support" 3
} }
# 18 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 2 3
# 22 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 26 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 2 3
namespace std {inline namespace __1 {
# 40 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 3
class __attribute__ ((__visibility__("default"))) mutex
{
__libcpp_mutex_t __m_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
mutex() throw() {__m_ = (__libcpp_mutex_t){0x32AAABA7, {0}};}
~mutex();
private:
mutex(const mutex&);
mutex& operator=(const mutex&);
public:
void lock() ;
bool try_lock() throw() ;
void unlock() throw() ;
typedef __libcpp_mutex_t* native_handle_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) native_handle_type native_handle() {return &__m_;}
};
_Static_assert(is_nothrow_default_constructible<mutex>::value, "the default constructor for std::mutex must be nothrow");
struct __attribute__ ((__visibility__("default"))) defer_lock_t {};
struct __attribute__ ((__visibility__("default"))) try_to_lock_t {};
struct __attribute__ ((__visibility__("default"))) adopt_lock_t {};
extern const defer_lock_t defer_lock;
extern const try_to_lock_t try_to_lock;
extern const adopt_lock_t adopt_lock;
# 91 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 3
template <class _Mutex>
class __attribute__ ((__type_visibility__("default")))
lock_guard
{
public:
typedef _Mutex mutex_type;
private:
mutex_type& __m_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit lock_guard(mutex_type& __m)
: __m_(__m) {__m_.lock();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
lock_guard(mutex_type& __m, adopt_lock_t)
: __m_(__m) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
~lock_guard() {__m_.unlock();}
private:
lock_guard(lock_guard const&) ;
lock_guard& operator=(lock_guard const&) ;
};
template <class _Mutex>
class __attribute__ ((__type_visibility__("default"))) unique_lock
{
public:
typedef _Mutex mutex_type;
private:
mutex_type* __m_;
bool __owns_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_lock() throw() : __m_(std::__1::__get_nullptr_t()), __owns_(false) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit unique_lock(mutex_type& __m)
: __m_(std::__1::addressof(__m)), __owns_(true) {__m_->lock();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_lock(mutex_type& __m, defer_lock_t) throw()
: __m_(std::__1::addressof(__m)), __owns_(false) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_lock(mutex_type& __m, try_to_lock_t)
: __m_(std::__1::addressof(__m)), __owns_(__m.try_lock()) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_lock(mutex_type& __m, adopt_lock_t)
: __m_(std::__1::addressof(__m)), __owns_(true) {}
template <class _Clock, class _Duration>
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_lock(mutex_type& __m, const chrono::time_point<_Clock, _Duration>& __t)
: __m_(std::__1::addressof(__m)), __owns_(__m.try_lock_until(__t)) {}
template <class _Rep, class _Period>
__attribute__ ((__visibility__("hidden"), __always_inline__))
unique_lock(mutex_type& __m, const chrono::duration<_Rep, _Period>& __d)
: __m_(std::__1::addressof(__m)), __owns_(__m.try_lock_for(__d)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
~unique_lock()
{
if (__owns_)
__m_->unlock();
}
private:
unique_lock(unique_lock const&);
unique_lock& operator=(unique_lock const&);
public:
# 180 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__mutex_base" 3
void lock();
bool try_lock();
template <class _Rep, class _Period>
bool try_lock_for(const chrono::duration<_Rep, _Period>& __d);
template <class _Clock, class _Duration>
bool try_lock_until(const chrono::time_point<_Clock, _Duration>& __t);
void unlock();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(unique_lock& __u) throw()
{
std::__1::swap(__m_, __u.__m_);
std::__1::swap(__owns_, __u.__owns_);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
mutex_type* release() throw()
{
mutex_type* __m = __m_;
__m_ = std::__1::__get_nullptr_t();
__owns_ = false;
return __m;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool owns_lock() const throw() {return __owns_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool () const throw() {return __owns_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
mutex_type* mutex() const throw() {return __m_;}
};
template <class _Mutex>
void
unique_lock<_Mutex>::lock()
{
if (__m_ == std::__1::__get_nullptr_t())
__throw_system_error(1, "unique_lock::lock: references null mutex");
if (__owns_)
__throw_system_error(11, "unique_lock::lock: already locked");
__m_->lock();
__owns_ = true;
}
template <class _Mutex>
bool
unique_lock<_Mutex>::try_lock()
{
if (__m_ == std::__1::__get_nullptr_t())
__throw_system_error(1, "unique_lock::try_lock: references null mutex");
if (__owns_)
__throw_system_error(11, "unique_lock::try_lock: already locked");
__owns_ = __m_->try_lock();
return __owns_;
}
template <class _Mutex>
template <class _Rep, class _Period>
bool
unique_lock<_Mutex>::try_lock_for(const chrono::duration<_Rep, _Period>& __d)
{
if (__m_ == std::__1::__get_nullptr_t())
__throw_system_error(1, "unique_lock::try_lock_for: references null mutex");
if (__owns_)
__throw_system_error(11, "unique_lock::try_lock_for: already locked");
__owns_ = __m_->try_lock_for(__d);
return __owns_;
}
template <class _Mutex>
template <class _Clock, class _Duration>
bool
unique_lock<_Mutex>::try_lock_until(const chrono::time_point<_Clock, _Duration>& __t)
{
if (__m_ == std::__1::__get_nullptr_t())
__throw_system_error(1, "unique_lock::try_lock_until: references null mutex");
if (__owns_)
__throw_system_error(11, "unique_lock::try_lock_until: already locked");
__owns_ = __m_->try_lock_until(__t);
return __owns_;
}
template <class _Mutex>
void
unique_lock<_Mutex>::unlock()
{
if (!__owns_)
__throw_system_error(1, "unique_lock::unlock: not locked");
__m_->unlock();
__owns_ = false;
}
template <class _Mutex>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(unique_lock<_Mutex>& __x, unique_lock<_Mutex>& __y) throw()
{__x.swap(__y);}
struct __attribute__ ((__visibility__("default"))) cv_status { enum __lx
{
no_timeout,
timeout
};
__lx __v_; __attribute__ ((__visibility__("hidden"), __always_inline__)) cv_status(__lx __v) : __v_(__v) {} __attribute__ ((__visibility__("hidden"), __always_inline__)) explicit cv_status(int __v) : __v_(static_cast<__lx>(__v)) {} __attribute__ ((__visibility__("hidden"), __always_inline__)) operator int() const {return __v_;} };
class __attribute__ ((__visibility__("default"))) condition_variable
{
__libcpp_condvar_t __cv_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
condition_variable() throw() {__cv_ = (__libcpp_condvar_t){0x3CB0B1BB, {0}};}
~condition_variable();
private:
condition_variable(const condition_variable&);
condition_variable& operator=(const condition_variable&);
public:
void notify_one() throw();
void notify_all() throw();
void wait(unique_lock<mutex>& __lk) throw();
template <class _Predicate>
inline __attribute__ ((__visibility__("hidden")))
void wait(unique_lock<mutex>& __lk, _Predicate __pred);
template <class _Clock, class _Duration>
inline __attribute__ ((__visibility__("hidden")))
cv_status
wait_until(unique_lock<mutex>& __lk,
const chrono::time_point<_Clock, _Duration>& __t);
template <class _Clock, class _Duration, class _Predicate>
inline __attribute__ ((__visibility__("hidden")))
bool
wait_until(unique_lock<mutex>& __lk,
const chrono::time_point<_Clock, _Duration>& __t,
_Predicate __pred);
template <class _Rep, class _Period>
inline __attribute__ ((__visibility__("hidden")))
cv_status
wait_for(unique_lock<mutex>& __lk,
const chrono::duration<_Rep, _Period>& __d);
template <class _Rep, class _Period, class _Predicate>
bool
__attribute__ ((__visibility__("hidden"), __always_inline__))
wait_for(unique_lock<mutex>& __lk,
const chrono::duration<_Rep, _Period>& __d,
_Predicate __pred);
typedef __libcpp_condvar_t* native_handle_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) native_handle_type native_handle() {return &__cv_;}
private:
void __do_timed_wait(unique_lock<mutex>& __lk,
chrono::time_point<chrono::system_clock, chrono::nanoseconds>) throw();
};
template <class _To, class _Rep, class _Period>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename enable_if
<
chrono::__is_duration<_To>::value,
_To
>::type
__ceil(chrono::duration<_Rep, _Period> __d)
{
using namespace chrono;
_To __r = duration_cast<_To>(__d);
if (__r < __d)
++__r;
return __r;
}
template <class _Predicate>
void
condition_variable::wait(unique_lock<mutex>& __lk, _Predicate __pred)
{
while (!__pred())
wait(__lk);
}
template <class _Clock, class _Duration>
cv_status
condition_variable::wait_until(unique_lock<mutex>& __lk,
const chrono::time_point<_Clock, _Duration>& __t)
{
using namespace chrono;
wait_for(__lk, __t - _Clock::now());
return _Clock::now() < __t ? cv_status::no_timeout : cv_status::timeout;
}
template <class _Clock, class _Duration, class _Predicate>
bool
condition_variable::wait_until(unique_lock<mutex>& __lk,
const chrono::time_point<_Clock, _Duration>& __t,
_Predicate __pred)
{
while (!__pred())
{
if (wait_until(__lk, __t) == cv_status::timeout)
return __pred();
}
return true;
}
template <class _Rep, class _Period>
cv_status
condition_variable::wait_for(unique_lock<mutex>& __lk,
const chrono::duration<_Rep, _Period>& __d)
{
using namespace chrono;
if (__d <= __d.zero())
return cv_status::timeout;
typedef time_point<system_clock, duration<long double, nano> > __sys_tpf;
typedef time_point<system_clock, nanoseconds> __sys_tpi;
__sys_tpf _Max = __sys_tpi::max();
steady_clock::time_point __c_now = steady_clock::now();
system_clock::time_point __s_now = system_clock::now();
if (_Max - __d > __s_now)
__do_timed_wait(__lk, __s_now + __ceil<nanoseconds>(__d));
else
__do_timed_wait(__lk, __sys_tpi::max());
return steady_clock::now() - __c_now < __d ? cv_status::no_timeout :
cv_status::timeout;
}
template <class _Rep, class _Period, class _Predicate>
inline
bool
condition_variable::wait_for(unique_lock<mutex>& __lk,
const chrono::duration<_Rep, _Period>& __d,
_Predicate __pred)
{
return wait_until(__lk, chrono::steady_clock::now() + __d,
std::__1::move(__pred));
}
} }
# 192 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 1 3
# 495 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
namespace std {inline namespace __1 {
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) plus : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x + __y;}
};
# 529 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) minus : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x - __y;}
};
# 556 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) multiplies : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x * __y;}
};
# 583 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) divides : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x / __y;}
};
# 610 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) modulus : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x % __y;}
};
# 637 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) negate : unary_function<_Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x) const
{return -__x;}
};
# 664 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) equal_to : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x == __y;}
};
# 691 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) not_equal_to : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x != __y;}
};
# 718 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) greater : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x > __y;}
};
# 747 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) greater_equal : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x >= __y;}
};
# 774 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) less_equal : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x <= __y;}
};
# 801 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) logical_and : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x && __y;}
};
# 828 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) logical_or : binary_function<_Tp, _Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x, const _Tp& __y) const
{return __x || __y;}
};
# 855 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) logical_not : unary_function<_Tp, bool>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const _Tp& __x) const
{return !__x;}
};
# 882 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) bit_and : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x & __y;}
};
# 909 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) bit_or : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x | __y;}
};
# 936 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Tp>
struct __attribute__ ((__type_visibility__("default"))) bit_xor : binary_function<_Tp, _Tp, _Tp>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp operator()(const _Tp& __x, const _Tp& __y) const
{return __x ^ __y;}
};
# 982 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _Predicate>
class __attribute__ ((__type_visibility__("default"))) unary_negate
: public unary_function<typename _Predicate::argument_type, bool>
{
_Predicate __pred_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit unary_negate(const _Predicate& __pred)
: __pred_(__pred) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const typename _Predicate::argument_type& __x) const
{return !__pred_(__x);}
};
template <class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
unary_negate<_Predicate>
not1(const _Predicate& __pred) {return unary_negate<_Predicate>(__pred);}
template <class _Predicate>
class __attribute__ ((__type_visibility__("default"))) binary_negate
: public binary_function<typename _Predicate::first_argument_type,
typename _Predicate::second_argument_type,
bool>
{
_Predicate __pred_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit
binary_negate(const _Predicate& __pred) : __pred_(__pred) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator()(const typename _Predicate::first_argument_type& __x,
const typename _Predicate::second_argument_type& __y) const
{return !__pred_(__x, __y);}
};
template <class _Predicate>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
binary_negate<_Predicate>
not2(const _Predicate& __pred) {return binary_negate<_Predicate>(__pred);}
template <class __Operation>
class __attribute__ ((__type_visibility__("default"))) binder1st
: public unary_function<typename __Operation::second_argument_type,
typename __Operation::result_type>
{
protected:
__Operation op;
typename __Operation::first_argument_type value;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) binder1st(const __Operation& __x,
const typename __Operation::first_argument_type __y)
: op(__x), value(__y) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) typename __Operation::result_type operator()
(typename __Operation::second_argument_type& __x) const
{return op(value, __x);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) typename __Operation::result_type operator()
(const typename __Operation::second_argument_type& __x) const
{return op(value, __x);}
};
template <class __Operation, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
binder1st<__Operation>
bind1st(const __Operation& __op, const _Tp& __x)
{return binder1st<__Operation>(__op, __x);}
template <class __Operation>
class __attribute__ ((__type_visibility__("default"))) binder2nd
: public unary_function<typename __Operation::first_argument_type,
typename __Operation::result_type>
{
protected:
__Operation op;
typename __Operation::second_argument_type value;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
binder2nd(const __Operation& __x, const typename __Operation::second_argument_type __y)
: op(__x), value(__y) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) typename __Operation::result_type operator()
( typename __Operation::first_argument_type& __x) const
{return op(__x, value);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) typename __Operation::result_type operator()
(const typename __Operation::first_argument_type& __x) const
{return op(__x, value);}
};
template <class __Operation, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
binder2nd<__Operation>
bind2nd(const __Operation& __op, const _Tp& __x)
{return binder2nd<__Operation>(__op, __x);}
template <class _Arg, class _Result>
class __attribute__ ((__type_visibility__("default"))) pointer_to_unary_function
: public unary_function<_Arg, _Result>
{
_Result (*__f_)(_Arg);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit pointer_to_unary_function(_Result (*__f)(_Arg))
: __f_(__f) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Result operator()(_Arg __x) const
{return __f_(__x);}
};
template <class _Arg, class _Result>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pointer_to_unary_function<_Arg,_Result>
ptr_fun(_Result (*__f)(_Arg))
{return pointer_to_unary_function<_Arg,_Result>(__f);}
template <class _Arg1, class _Arg2, class _Result>
class __attribute__ ((__type_visibility__("default"))) pointer_to_binary_function
: public binary_function<_Arg1, _Arg2, _Result>
{
_Result (*__f_)(_Arg1, _Arg2);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit pointer_to_binary_function(_Result (*__f)(_Arg1, _Arg2))
: __f_(__f) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Result operator()(_Arg1 __x, _Arg2 __y) const
{return __f_(__x, __y);}
};
template <class _Arg1, class _Arg2, class _Result>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
pointer_to_binary_function<_Arg1,_Arg2,_Result>
ptr_fun(_Result (*__f)(_Arg1,_Arg2))
{return pointer_to_binary_function<_Arg1,_Arg2,_Result>(__f);}
template<class _Sp, class _Tp>
class __attribute__ ((__type_visibility__("default"))) mem_fun_t : public unary_function<_Tp*, _Sp>
{
_Sp (_Tp::*__p_)();
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit mem_fun_t(_Sp (_Tp::*__p)())
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(_Tp* __p) const
{return (__p->*__p_)();}
};
template<class _Sp, class _Tp, class _Ap>
class __attribute__ ((__type_visibility__("default"))) mem_fun1_t : public binary_function<_Tp*, _Ap, _Sp>
{
_Sp (_Tp::*__p_)(_Ap);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit mem_fun1_t(_Sp (_Tp::*__p)(_Ap))
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(_Tp* __p, _Ap __x) const
{return (__p->*__p_)(__x);}
};
template<class _Sp, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
mem_fun_t<_Sp,_Tp>
mem_fun(_Sp (_Tp::*__f)())
{return mem_fun_t<_Sp,_Tp>(__f);}
template<class _Sp, class _Tp, class _Ap>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
mem_fun1_t<_Sp,_Tp,_Ap>
mem_fun(_Sp (_Tp::*__f)(_Ap))
{return mem_fun1_t<_Sp,_Tp,_Ap>(__f);}
template<class _Sp, class _Tp>
class __attribute__ ((__type_visibility__("default"))) mem_fun_ref_t : public unary_function<_Tp, _Sp>
{
_Sp (_Tp::*__p_)();
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit mem_fun_ref_t(_Sp (_Tp::*__p)())
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(_Tp& __p) const
{return (__p.*__p_)();}
};
template<class _Sp, class _Tp, class _Ap>
class __attribute__ ((__type_visibility__("default"))) mem_fun1_ref_t : public binary_function<_Tp, _Ap, _Sp>
{
_Sp (_Tp::*__p_)(_Ap);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit mem_fun1_ref_t(_Sp (_Tp::*__p)(_Ap))
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(_Tp& __p, _Ap __x) const
{return (__p.*__p_)(__x);}
};
template<class _Sp, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
mem_fun_ref_t<_Sp,_Tp>
mem_fun_ref(_Sp (_Tp::*__f)())
{return mem_fun_ref_t<_Sp,_Tp>(__f);}
template<class _Sp, class _Tp, class _Ap>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
mem_fun1_ref_t<_Sp,_Tp,_Ap>
mem_fun_ref(_Sp (_Tp::*__f)(_Ap))
{return mem_fun1_ref_t<_Sp,_Tp,_Ap>(__f);}
template <class _Sp, class _Tp>
class __attribute__ ((__type_visibility__("default"))) const_mem_fun_t : public unary_function<const _Tp*, _Sp>
{
_Sp (_Tp::*__p_)() const;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit const_mem_fun_t(_Sp (_Tp::*__p)() const)
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(const _Tp* __p) const
{return (__p->*__p_)();}
};
template <class _Sp, class _Tp, class _Ap>
class __attribute__ ((__type_visibility__("default"))) const_mem_fun1_t : public binary_function<const _Tp*, _Ap, _Sp>
{
_Sp (_Tp::*__p_)(_Ap) const;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit const_mem_fun1_t(_Sp (_Tp::*__p)(_Ap) const)
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(const _Tp* __p, _Ap __x) const
{return (__p->*__p_)(__x);}
};
template <class _Sp, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const_mem_fun_t<_Sp,_Tp>
mem_fun(_Sp (_Tp::*__f)() const)
{return const_mem_fun_t<_Sp,_Tp>(__f);}
template <class _Sp, class _Tp, class _Ap>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const_mem_fun1_t<_Sp,_Tp,_Ap>
mem_fun(_Sp (_Tp::*__f)(_Ap) const)
{return const_mem_fun1_t<_Sp,_Tp,_Ap>(__f);}
template <class _Sp, class _Tp>
class __attribute__ ((__type_visibility__("default"))) const_mem_fun_ref_t : public unary_function<_Tp, _Sp>
{
_Sp (_Tp::*__p_)() const;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit const_mem_fun_ref_t(_Sp (_Tp::*__p)() const)
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(const _Tp& __p) const
{return (__p.*__p_)();}
};
template <class _Sp, class _Tp, class _Ap>
class __attribute__ ((__type_visibility__("default"))) const_mem_fun1_ref_t
: public binary_function<_Tp, _Ap, _Sp>
{
_Sp (_Tp::*__p_)(_Ap) const;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit const_mem_fun1_ref_t(_Sp (_Tp::*__p)(_Ap) const)
: __p_(__p) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) _Sp operator()(const _Tp& __p, _Ap __x) const
{return (__p.*__p_)(__x);}
};
template <class _Sp, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const_mem_fun_ref_t<_Sp,_Tp>
mem_fun_ref(_Sp (_Tp::*__f)() const)
{return const_mem_fun_ref_t<_Sp,_Tp>(__f);}
template <class _Sp, class _Tp, class _Ap>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const_mem_fun1_ref_t<_Sp,_Tp,_Ap>
mem_fun_ref(_Sp (_Tp::*__f)(_Ap) const)
{return const_mem_fun1_ref_t<_Sp,_Tp,_Ap>(__f);}
template <class _Tp>
class __mem_fn
: public __weak_result_type<_Tp>
{
public:
typedef _Tp type;
private:
type __f_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __mem_fn(type __f) throw() : __f_(__f) {}
# 1277 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return0<type, _A0>::type
operator() (_A0& __a0) const {
return __invoke(__f_, __a0);
}
template <class _A0>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return0<type, _A0 const>::type
operator() (_A0 const& __a0) const {
return __invoke(__f_, __a0);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0, _A1>::type
operator() (_A0& __a0, _A1& __a1) const {
return __invoke(__f_, __a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0 const, _A1>::type
operator() (_A0 const& __a0, _A1& __a1) const {
return __invoke(__f_, __a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0, _A1 const>::type
operator() (_A0& __a0, _A1 const& __a1) const {
return __invoke(__f_, __a0, __a1);
}
template <class _A0, class _A1>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return1<type, _A0 const, _A1 const>::type
operator() (_A0 const& __a0, _A1 const& __a1) const {
return __invoke(__f_, __a0, __a1);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1, _A2>::type
operator() (_A0& __a0, _A1& __a1, _A2& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1, _A2>::type
operator() (_A0 const& __a0, _A1& __a1, _A2& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1 const, _A2>::type
operator() (_A0& __a0, _A1 const& __a1, _A2& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1, _A2 const>::type
operator() (_A0& __a0, _A1& __a1, _A2 const& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1 const, _A2>::type
operator() (_A0 const& __a0, _A1 const& __a1, _A2& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1, _A2 const>::type
operator() (_A0 const& __a0, _A1& __a1, _A2 const& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0, _A1 const, _A2 const>::type
operator() (_A0& __a0, _A1 const& __a1, _A2 const& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
template <class _A0, class _A1, class _A2>
__attribute__ ((__visibility__("hidden"), __always_inline__))
typename __invoke_return2<type, _A0 const, _A1 const, _A2 const>::type
operator() (_A0 const& __a0, _A1 const& __a1, _A2 const& __a2) const {
return __invoke(__f_, __a0, __a1, __a2);
}
};
template<class _Rp, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__mem_fn<_Rp _Tp::*>
mem_fn(_Rp _Tp::* __pm) throw()
{
return __mem_fn<_Rp _Tp::*>(__pm);
}
class __attribute__ ((__visibility__("default"))) bad_function_call
: public exception
{
};
__attribute__ ((noreturn)) inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void __throw_bad_function_call()
{
throw bad_function_call();
}
template<class _Fp> class __attribute__ ((__type_visibility__("default"))) function;
namespace __function
{
template<class _Rp>
struct __maybe_derive_from_unary_function
{
};
template<class _Rp, class _A1>
struct __maybe_derive_from_unary_function<_Rp(_A1)>
: public unary_function<_A1, _Rp>
{
};
template<class _Rp>
struct __maybe_derive_from_binary_function
{
};
template<class _Rp, class _A1, class _A2>
struct __maybe_derive_from_binary_function<_Rp(_A1, _A2)>
: public binary_function<_A1, _A2, _Rp>
{
};
template <class _Fp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __not_null(_Fp const&) { return true; }
template <class _Fp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __not_null(_Fp* __ptr) { return __ptr; }
template <class _Ret, class _Class>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __not_null(_Ret _Class::*__ptr) { return __ptr; }
template <class _Fp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool __not_null(function<_Fp> const& __f) { return !!__f; }
}
# 1977 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_03" 1 3
# 18 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__functional_03" 3
namespace __function {
template<class _Fp> class __base;
template<class _Rp>
class __base<_Rp()>
{
__base(const __base&);
__base& operator=(const __base&);
public:
__base() {}
virtual ~__base() {}
virtual __base* __clone() const = 0;
virtual void __clone(__base*) const = 0;
virtual void destroy() = 0;
virtual void destroy_deallocate() = 0;
virtual _Rp operator()() = 0;
virtual const void* target(const type_info&) const = 0;
virtual const std::type_info& target_type() const = 0;
};
template<class _Rp, class _A0>
class __base<_Rp(_A0)>
{
__base(const __base&);
__base& operator=(const __base&);
public:
__base() {}
virtual ~__base() {}
virtual __base* __clone() const = 0;
virtual void __clone(__base*) const = 0;
virtual void destroy() = 0;
virtual void destroy_deallocate() = 0;
virtual _Rp operator()(_A0) = 0;
virtual const void* target(const type_info&) const = 0;
virtual const std::type_info& target_type() const = 0;
};
template<class _Rp, class _A0, class _A1>
class __base<_Rp(_A0, _A1)>
{
__base(const __base&);
__base& operator=(const __base&);
public:
__base() {}
virtual ~__base() {}
virtual __base* __clone() const = 0;
virtual void __clone(__base*) const = 0;
virtual void destroy() = 0;
virtual void destroy_deallocate() = 0;
virtual _Rp operator()(_A0, _A1) = 0;
virtual const void* target(const type_info&) const = 0;
virtual const std::type_info& target_type() const = 0;
};
template<class _Rp, class _A0, class _A1, class _A2>
class __base<_Rp(_A0, _A1, _A2)>
{
__base(const __base&);
__base& operator=(const __base&);
public:
__base() {}
virtual ~__base() {}
virtual __base* __clone() const = 0;
virtual void __clone(__base*) const = 0;
virtual void destroy() = 0;
virtual void destroy_deallocate() = 0;
virtual _Rp operator()(_A0, _A1, _A2) = 0;
virtual const void* target(const type_info&) const = 0;
virtual const std::type_info& target_type() const = 0;
};
template<class _FD, class _Alloc, class _FB> class __func;
template<class _Fp, class _Alloc, class _Rp>
class __func<_Fp, _Alloc, _Rp()>
: public __base<_Rp()>
{
__compressed_pair<_Fp, _Alloc> __f_;
public:
explicit __func(_Fp __f) : __f_(std::__1::move(__f)) {}
explicit __func(_Fp __f, _Alloc __a) : __f_(std::__1::move(__f), std::__1::move(__a)) {}
virtual __base<_Rp()>* __clone() const;
virtual void __clone(__base<_Rp()>*) const;
virtual void destroy();
virtual void destroy_deallocate();
virtual _Rp operator()();
virtual const void* target(const type_info&) const;
virtual const std::type_info& target_type() const;
};
template<class _Fp, class _Alloc, class _Rp>
__base<_Rp()>*
__func<_Fp, _Alloc, _Rp()>::__clone() const
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) __func(__f_.first(), _Alloc(__a));
return __hold.release();
}
template<class _Fp, class _Alloc, class _Rp>
void
__func<_Fp, _Alloc, _Rp()>::__clone(__base<_Rp()>* __p) const
{
::new (__p) __func(__f_.first(), __f_.second());
}
template<class _Fp, class _Alloc, class _Rp>
void
__func<_Fp, _Alloc, _Rp()>::destroy()
{
__f_.~__compressed_pair<_Fp, _Alloc>();
}
template<class _Fp, class _Alloc, class _Rp>
void
__func<_Fp, _Alloc, _Rp()>::destroy_deallocate()
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
__f_.~__compressed_pair<_Fp, _Alloc>();
__a.deallocate(this, 1);
}
template<class _Fp, class _Alloc, class _Rp>
_Rp
__func<_Fp, _Alloc, _Rp()>::operator()()
{
typedef __invoke_void_return_wrapper<_Rp> _Invoker;
return _Invoker::__call(__f_.first());
}
template<class _Fp, class _Alloc, class _Rp>
const void*
__func<_Fp, _Alloc, _Rp()>::target(const type_info& __ti) const
{
if (__ti == typeid(_Fp))
return &__f_.first();
return (const void*)0;
}
template<class _Fp, class _Alloc, class _Rp>
const std::type_info&
__func<_Fp, _Alloc, _Rp()>::target_type() const
{
return typeid(_Fp);
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
class __func<_Fp, _Alloc, _Rp(_A0)>
: public __base<_Rp(_A0)>
{
__compressed_pair<_Fp, _Alloc> __f_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __func(_Fp __f) : __f_(std::__1::move(__f)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __func(_Fp __f, _Alloc __a)
: __f_(std::__1::move(__f), std::__1::move(__a)) {}
virtual __base<_Rp(_A0)>* __clone() const;
virtual void __clone(__base<_Rp(_A0)>*) const;
virtual void destroy();
virtual void destroy_deallocate();
virtual _Rp operator()(_A0);
virtual const void* target(const type_info&) const;
virtual const std::type_info& target_type() const;
};
template<class _Fp, class _Alloc, class _Rp, class _A0>
__base<_Rp(_A0)>*
__func<_Fp, _Alloc, _Rp(_A0)>::__clone() const
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) __func(__f_.first(), _Alloc(__a));
return __hold.release();
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
void
__func<_Fp, _Alloc, _Rp(_A0)>::__clone(__base<_Rp(_A0)>* __p) const
{
::new (__p) __func(__f_.first(), __f_.second());
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
void
__func<_Fp, _Alloc, _Rp(_A0)>::destroy()
{
__f_.~__compressed_pair<_Fp, _Alloc>();
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
void
__func<_Fp, _Alloc, _Rp(_A0)>::destroy_deallocate()
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
__f_.~__compressed_pair<_Fp, _Alloc>();
__a.deallocate(this, 1);
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
_Rp
__func<_Fp, _Alloc, _Rp(_A0)>::operator()(_A0 __a0)
{
typedef __invoke_void_return_wrapper<_Rp> _Invoker;
return _Invoker::__call(__f_.first(), __a0);
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
const void*
__func<_Fp, _Alloc, _Rp(_A0)>::target(const type_info& __ti) const
{
if (__ti == typeid(_Fp))
return &__f_.first();
return (const void*)0;
}
template<class _Fp, class _Alloc, class _Rp, class _A0>
const std::type_info&
__func<_Fp, _Alloc, _Rp(_A0)>::target_type() const
{
return typeid(_Fp);
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
class __func<_Fp, _Alloc, _Rp(_A0, _A1)>
: public __base<_Rp(_A0, _A1)>
{
__compressed_pair<_Fp, _Alloc> __f_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __func(_Fp __f) : __f_(std::__1::move(__f)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __func(_Fp __f, _Alloc __a)
: __f_(std::__1::move(__f), std::__1::move(__a)) {}
virtual __base<_Rp(_A0, _A1)>* __clone() const;
virtual void __clone(__base<_Rp(_A0, _A1)>*) const;
virtual void destroy();
virtual void destroy_deallocate();
virtual _Rp operator()(_A0, _A1);
virtual const void* target(const type_info&) const;
virtual const std::type_info& target_type() const;
};
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
__base<_Rp(_A0, _A1)>*
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::__clone() const
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) __func(__f_.first(), _Alloc(__a));
return __hold.release();
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
void
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::__clone(__base<_Rp(_A0, _A1)>* __p) const
{
::new (__p) __func(__f_.first(), __f_.second());
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
void
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::destroy()
{
__f_.~__compressed_pair<_Fp, _Alloc>();
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
void
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::destroy_deallocate()
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
__f_.~__compressed_pair<_Fp, _Alloc>();
__a.deallocate(this, 1);
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
_Rp
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::operator()(_A0 __a0, _A1 __a1)
{
typedef __invoke_void_return_wrapper<_Rp> _Invoker;
return _Invoker::__call(__f_.first(), __a0, __a1);
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
const void*
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::target(const type_info& __ti) const
{
if (__ti == typeid(_Fp))
return &__f_.first();
return (const void*)0;
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1>
const std::type_info&
__func<_Fp, _Alloc, _Rp(_A0, _A1)>::target_type() const
{
return typeid(_Fp);
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
class __func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>
: public __base<_Rp(_A0, _A1, _A2)>
{
__compressed_pair<_Fp, _Alloc> __f_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __func(_Fp __f) : __f_(std::__1::move(__f)) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __func(_Fp __f, _Alloc __a)
: __f_(std::__1::move(__f), std::__1::move(__a)) {}
virtual __base<_Rp(_A0, _A1, _A2)>* __clone() const;
virtual void __clone(__base<_Rp(_A0, _A1, _A2)>*) const;
virtual void destroy();
virtual void destroy_deallocate();
virtual _Rp operator()(_A0, _A1, _A2);
virtual const void* target(const type_info&) const;
virtual const std::type_info& target_type() const;
};
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
__base<_Rp(_A0, _A1, _A2)>*
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::__clone() const
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) __func(__f_.first(), _Alloc(__a));
return __hold.release();
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
void
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::__clone(__base<_Rp(_A0, _A1, _A2)>* __p) const
{
::new (__p) __func(__f_.first(), __f_.second());
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
void
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::destroy()
{
__f_.~__compressed_pair<_Fp, _Alloc>();
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
void
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::destroy_deallocate()
{
typedef allocator_traits<_Alloc> __alloc_traits;
typedef typename __rebind_alloc_helper<__alloc_traits, __func>::type _Ap;
_Ap __a(__f_.second());
__f_.~__compressed_pair<_Fp, _Alloc>();
__a.deallocate(this, 1);
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
_Rp
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::operator()(_A0 __a0, _A1 __a1, _A2 __a2)
{
typedef __invoke_void_return_wrapper<_Rp> _Invoker;
return _Invoker::__call(__f_.first(), __a0, __a1, __a2);
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
const void*
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::target(const type_info& __ti) const
{
if (__ti == typeid(_Fp))
return &__f_.first();
return (const void*)0;
}
template<class _Fp, class _Alloc, class _Rp, class _A0, class _A1, class _A2>
const std::type_info&
__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::target_type() const
{
return typeid(_Fp);
}
}
template<class _Rp>
class __attribute__ ((__type_visibility__("default"))) function<_Rp()>
{
typedef __function::__base<_Rp()> __base;
aligned_storage<3*sizeof(void*)>::type __buf_;
__base* __f_;
public:
typedef _Rp result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit function() : __f_(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) function(nullptr_t) : __f_(0) {}
function(const function&);
template<class _Fp>
function(_Fp,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&) : __f_(0) {}
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {}
template<class _Alloc>
function(allocator_arg_t, const _Alloc&, const function&);
template<class _Fp, class _Alloc>
function(allocator_arg_t, const _Alloc& __a, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
function& operator=(const function&);
function& operator=(nullptr_t);
template<class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function&
>::type
operator=(_Fp);
~function();
void swap(function&);
template<class _Fp, class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void assign(_Fp __f, const _Alloc& __a)
{function(allocator_arg, __a, __f).swap(*this);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator bool() const {return __f_;}
private:
template<class _R2>
bool operator==(const function<_R2()>&) const;
template<class _R2>
bool operator!=(const function<_R2()>&) const;
public:
_Rp operator()() const;
const std::type_info& target_type() const;
template <typename _Tp> _Tp* target();
template <typename _Tp> const _Tp* target() const;
};
template<class _Rp>
function<_Rp()>::function(const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp>
template<class _Alloc>
function<_Rp()>::function(allocator_arg_t, const _Alloc&, const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp>
template <class _Fp>
function<_Rp()>::function(_Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, allocator<_Fp>, _Rp()> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f);
}
else
{
typedef allocator<_FF> _Ap;
_Ap __a;
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, allocator<_Fp>(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp>
template <class _Fp, class _Alloc>
function<_Rp()>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
typedef allocator_traits<_Alloc> __alloc_traits;
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, _Alloc, _Rp()> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f, __a0);
}
else
{
typedef typename __rebind_alloc_helper<__alloc_traits, _FF>::type _Ap;
_Ap __a(__a0);
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, _Alloc(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp>
function<_Rp()>&
function<_Rp()>::operator=(const function& __f)
{
if (__f)
function(__f).swap(*this);
else
*this = std::__1::__get_nullptr_t();
return *this;
}
template<class _Rp>
function<_Rp()>&
function<_Rp()>::operator=(nullptr_t)
{
__base* __t = __f_;
__f_ = 0;
if (__t == (__base*)&__buf_)
__t->destroy();
else if (__t)
__t->destroy_deallocate();
return *this;
}
template<class _Rp>
template <class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function<_Rp()>&
>::type
function<_Rp()>::operator=(_Fp __f)
{
function(std::__1::move(__f)).swap(*this);
return *this;
}
template<class _Rp>
function<_Rp()>::~function()
{
if (__f_ == (__base*)&__buf_)
__f_->destroy();
else if (__f_)
__f_->destroy_deallocate();
}
template<class _Rp>
void
function<_Rp()>::swap(function& __f)
{
if (std::__1::addressof(__f) == this)
return;
if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_)
{
typename aligned_storage<sizeof(__buf_)>::type __tempbuf;
__base* __t = (__base*)&__tempbuf;
__f_->__clone(__t);
__f_->destroy();
__f_ = 0;
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = 0;
__f_ = (__base*)&__buf_;
__t->__clone((__base*)&__f.__buf_);
__t->destroy();
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f_ == (__base*)&__buf_)
{
__f_->__clone((__base*)&__f.__buf_);
__f_->destroy();
__f_ = __f.__f_;
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f.__f_ == (__base*)&__f.__buf_)
{
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = __f_;
__f_ = (__base*)&__buf_;
}
else
std::__1::swap(__f_, __f.__f_);
}
template<class _Rp>
_Rp
function<_Rp()>::operator()() const
{
if (__f_ == 0)
__throw_bad_function_call();
return (*__f_)();
}
template<class _Rp>
const std::type_info&
function<_Rp()>::target_type() const
{
if (__f_ == 0)
return typeid(void);
return __f_->target_type();
}
template<class _Rp>
template <typename _Tp>
_Tp*
function<_Rp()>::target()
{
if (__f_ == 0)
return (_Tp*)0;
return (_Tp*) const_cast<void *>(__f_->target(typeid(_Tp)));
}
template<class _Rp>
template <typename _Tp>
const _Tp*
function<_Rp()>::target() const
{
if (__f_ == 0)
return (const _Tp*)0;
return (const _Tp*)__f_->target(typeid(_Tp));
}
template<class _Rp, class _A0>
class __attribute__ ((__type_visibility__("default"))) function<_Rp(_A0)>
: public unary_function<_A0, _Rp>
{
typedef __function::__base<_Rp(_A0)> __base;
aligned_storage<3*sizeof(void*)>::type __buf_;
__base* __f_;
public:
typedef _Rp result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit function() : __f_(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) function(nullptr_t) : __f_(0) {}
function(const function&);
template<class _Fp>
function(_Fp,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&) : __f_(0) {}
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {}
template<class _Alloc>
function(allocator_arg_t, const _Alloc&, const function&);
template<class _Fp, class _Alloc>
function(allocator_arg_t, const _Alloc& __a, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
function& operator=(const function&);
function& operator=(nullptr_t);
template<class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function&
>::type
operator=(_Fp);
~function();
void swap(function&);
template<class _Fp, class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void assign(_Fp __f, const _Alloc& __a)
{function(allocator_arg, __a, __f).swap(*this);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator bool() const {return __f_;}
private:
template<class _R2, class _B0>
bool operator==(const function<_R2(_B0)>&) const;
template<class _R2, class _B0>
bool operator!=(const function<_R2(_B0)>&) const;
public:
_Rp operator()(_A0) const;
const std::type_info& target_type() const;
template <typename _Tp> _Tp* target();
template <typename _Tp> const _Tp* target() const;
};
template<class _Rp, class _A0>
function<_Rp(_A0)>::function(const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp, class _A0>
template<class _Alloc>
function<_Rp(_A0)>::function(allocator_arg_t, const _Alloc&, const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp, class _A0>
template <class _Fp>
function<_Rp(_A0)>::function(_Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_A0)> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f);
}
else
{
typedef allocator<_FF> _Ap;
_Ap __a;
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, allocator<_Fp>(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp, class _A0>
template <class _Fp, class _Alloc>
function<_Rp(_A0)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
typedef allocator_traits<_Alloc> __alloc_traits;
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, _Alloc, _Rp(_A0)> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f, __a0);
}
else
{
typedef typename __rebind_alloc_helper<__alloc_traits, _FF>::type _Ap;
_Ap __a(__a0);
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, _Alloc(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp, class _A0>
function<_Rp(_A0)>&
function<_Rp(_A0)>::operator=(const function& __f)
{
if (__f)
function(__f).swap(*this);
else
*this = std::__1::__get_nullptr_t();
return *this;
}
template<class _Rp, class _A0>
function<_Rp(_A0)>&
function<_Rp(_A0)>::operator=(nullptr_t)
{
__base* __t = __f_;
__f_ = 0;
if (__t == (__base*)&__buf_)
__t->destroy();
else if (__t)
__t->destroy_deallocate();
return *this;
}
template<class _Rp, class _A0>
template <class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function<_Rp(_A0)>&
>::type
function<_Rp(_A0)>::operator=(_Fp __f)
{
function(std::__1::move(__f)).swap(*this);
return *this;
}
template<class _Rp, class _A0>
function<_Rp(_A0)>::~function()
{
if (__f_ == (__base*)&__buf_)
__f_->destroy();
else if (__f_)
__f_->destroy_deallocate();
}
template<class _Rp, class _A0>
void
function<_Rp(_A0)>::swap(function& __f)
{
if (std::__1::addressof(__f) == this)
return;
if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_)
{
typename aligned_storage<sizeof(__buf_)>::type __tempbuf;
__base* __t = (__base*)&__tempbuf;
__f_->__clone(__t);
__f_->destroy();
__f_ = 0;
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = 0;
__f_ = (__base*)&__buf_;
__t->__clone((__base*)&__f.__buf_);
__t->destroy();
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f_ == (__base*)&__buf_)
{
__f_->__clone((__base*)&__f.__buf_);
__f_->destroy();
__f_ = __f.__f_;
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f.__f_ == (__base*)&__f.__buf_)
{
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = __f_;
__f_ = (__base*)&__buf_;
}
else
std::__1::swap(__f_, __f.__f_);
}
template<class _Rp, class _A0>
_Rp
function<_Rp(_A0)>::operator()(_A0 __a0) const
{
if (__f_ == 0)
__throw_bad_function_call();
return (*__f_)(__a0);
}
template<class _Rp, class _A0>
const std::type_info&
function<_Rp(_A0)>::target_type() const
{
if (__f_ == 0)
return typeid(void);
return __f_->target_type();
}
template<class _Rp, class _A0>
template <typename _Tp>
_Tp*
function<_Rp(_A0)>::target()
{
if (__f_ == 0)
return (_Tp*)0;
return (_Tp*) const_cast<void *>(__f_->target(typeid(_Tp)));
}
template<class _Rp, class _A0>
template <typename _Tp>
const _Tp*
function<_Rp(_A0)>::target() const
{
if (__f_ == 0)
return (const _Tp*)0;
return (const _Tp*)__f_->target(typeid(_Tp));
}
template<class _Rp, class _A0, class _A1>
class __attribute__ ((__type_visibility__("default"))) function<_Rp(_A0, _A1)>
: public binary_function<_A0, _A1, _Rp>
{
typedef __function::__base<_Rp(_A0, _A1)> __base;
aligned_storage<3*sizeof(void*)>::type __buf_;
__base* __f_;
public:
typedef _Rp result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit function() : __f_(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) function(nullptr_t) : __f_(0) {}
function(const function&);
template<class _Fp>
function(_Fp,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&) : __f_(0) {}
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {}
template<class _Alloc>
function(allocator_arg_t, const _Alloc&, const function&);
template<class _Fp, class _Alloc>
function(allocator_arg_t, const _Alloc& __a, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
function& operator=(const function&);
function& operator=(nullptr_t);
template<class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function&
>::type
operator=(_Fp);
~function();
void swap(function&);
template<class _Fp, class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void assign(_Fp __f, const _Alloc& __a)
{function(allocator_arg, __a, __f).swap(*this);}
operator bool() const {return __f_;}
private:
template<class _R2, class _B0, class _B1>
bool operator==(const function<_R2(_B0, _B1)>&) const;
template<class _R2, class _B0, class _B1>
bool operator!=(const function<_R2(_B0, _B1)>&) const;
public:
_Rp operator()(_A0, _A1) const;
const std::type_info& target_type() const;
template <typename _Tp> _Tp* target();
template <typename _Tp> const _Tp* target() const;
};
template<class _Rp, class _A0, class _A1>
function<_Rp(_A0, _A1)>::function(const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp, class _A0, class _A1>
template<class _Alloc>
function<_Rp(_A0, _A1)>::function(allocator_arg_t, const _Alloc&, const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp, class _A0, class _A1>
template <class _Fp>
function<_Rp(_A0, _A1)>::function(_Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_A0, _A1)> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f);
}
else
{
typedef allocator<_FF> _Ap;
_Ap __a;
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, allocator<_Fp>(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp, class _A0, class _A1>
template <class _Fp, class _Alloc>
function<_Rp(_A0, _A1)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
typedef allocator_traits<_Alloc> __alloc_traits;
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, _Alloc, _Rp(_A0, _A1)> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f, __a0);
}
else
{
typedef typename __rebind_alloc_helper<__alloc_traits, _FF>::type _Ap;
_Ap __a(__a0);
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, _Alloc(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp, class _A0, class _A1>
function<_Rp(_A0, _A1)>&
function<_Rp(_A0, _A1)>::operator=(const function& __f)
{
if (__f)
function(__f).swap(*this);
else
*this = std::__1::__get_nullptr_t();
return *this;
}
template<class _Rp, class _A0, class _A1>
function<_Rp(_A0, _A1)>&
function<_Rp(_A0, _A1)>::operator=(nullptr_t)
{
__base* __t = __f_;
__f_ = 0;
if (__t == (__base*)&__buf_)
__t->destroy();
else if (__t)
__t->destroy_deallocate();
return *this;
}
template<class _Rp, class _A0, class _A1>
template <class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function<_Rp(_A0, _A1)>&
>::type
function<_Rp(_A0, _A1)>::operator=(_Fp __f)
{
function(std::__1::move(__f)).swap(*this);
return *this;
}
template<class _Rp, class _A0, class _A1>
function<_Rp(_A0, _A1)>::~function()
{
if (__f_ == (__base*)&__buf_)
__f_->destroy();
else if (__f_)
__f_->destroy_deallocate();
}
template<class _Rp, class _A0, class _A1>
void
function<_Rp(_A0, _A1)>::swap(function& __f)
{
if (std::__1::addressof(__f) == this)
return;
if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_)
{
typename aligned_storage<sizeof(__buf_)>::type __tempbuf;
__base* __t = (__base*)&__tempbuf;
__f_->__clone(__t);
__f_->destroy();
__f_ = 0;
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = 0;
__f_ = (__base*)&__buf_;
__t->__clone((__base*)&__f.__buf_);
__t->destroy();
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f_ == (__base*)&__buf_)
{
__f_->__clone((__base*)&__f.__buf_);
__f_->destroy();
__f_ = __f.__f_;
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f.__f_ == (__base*)&__f.__buf_)
{
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = __f_;
__f_ = (__base*)&__buf_;
}
else
std::__1::swap(__f_, __f.__f_);
}
template<class _Rp, class _A0, class _A1>
_Rp
function<_Rp(_A0, _A1)>::operator()(_A0 __a0, _A1 __a1) const
{
if (__f_ == 0)
__throw_bad_function_call();
return (*__f_)(__a0, __a1);
}
template<class _Rp, class _A0, class _A1>
const std::type_info&
function<_Rp(_A0, _A1)>::target_type() const
{
if (__f_ == 0)
return typeid(void);
return __f_->target_type();
}
template<class _Rp, class _A0, class _A1>
template <typename _Tp>
_Tp*
function<_Rp(_A0, _A1)>::target()
{
if (__f_ == 0)
return (_Tp*)0;
return (_Tp*) const_cast<void *>(__f_->target(typeid(_Tp)));
}
template<class _Rp, class _A0, class _A1>
template <typename _Tp>
const _Tp*
function<_Rp(_A0, _A1)>::target() const
{
if (__f_ == 0)
return (const _Tp*)0;
return (const _Tp*)__f_->target(typeid(_Tp));
}
template<class _Rp, class _A0, class _A1, class _A2>
class __attribute__ ((__type_visibility__("default"))) function<_Rp(_A0, _A1, _A2)>
{
typedef __function::__base<_Rp(_A0, _A1, _A2)> __base;
aligned_storage<3*sizeof(void*)>::type __buf_;
__base* __f_;
public:
typedef _Rp result_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit function() : __f_(0) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) function(nullptr_t) : __f_(0) {}
function(const function&);
template<class _Fp>
function(_Fp,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&) : __f_(0) {}
template<class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {}
template<class _Alloc>
function(allocator_arg_t, const _Alloc&, const function&);
template<class _Fp, class _Alloc>
function(allocator_arg_t, const _Alloc& __a, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type* = 0);
function& operator=(const function&);
function& operator=(nullptr_t);
template<class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function&
>::type
operator=(_Fp);
~function();
void swap(function&);
template<class _Fp, class _Alloc>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void assign(_Fp __f, const _Alloc& __a)
{function(allocator_arg, __a, __f).swap(*this);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator bool() const {return __f_;}
private:
template<class _R2, class _B0, class _B1, class _B2>
bool operator==(const function<_R2(_B0, _B1, _B2)>&) const;
template<class _R2, class _B0, class _B1, class _B2>
bool operator!=(const function<_R2(_B0, _B1, _B2)>&) const;
public:
_Rp operator()(_A0, _A1, _A2) const;
const std::type_info& target_type() const;
template <typename _Tp> _Tp* target();
template <typename _Tp> const _Tp* target() const;
};
template<class _Rp, class _A0, class _A1, class _A2>
function<_Rp(_A0, _A1, _A2)>::function(const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp, class _A0, class _A1, class _A2>
template<class _Alloc>
function<_Rp(_A0, _A1, _A2)>::function(allocator_arg_t, const _Alloc&,
const function& __f)
{
if (__f.__f_ == 0)
__f_ = 0;
else if (__f.__f_ == (const __base*)&__f.__buf_)
{
__f_ = (__base*)&__buf_;
__f.__f_->__clone(__f_);
}
else
__f_ = __f.__f_->__clone();
}
template<class _Rp, class _A0, class _A1, class _A2>
template <class _Fp>
function<_Rp(_A0, _A1, _A2)>::function(_Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_A0, _A1, _A2)> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f);
}
else
{
typedef allocator<_FF> _Ap;
_Ap __a;
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, allocator<_Fp>(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp, class _A0, class _A1, class _A2>
template <class _Fp, class _Alloc>
function<_Rp(_A0, _A1, _A2)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f,
typename enable_if<!is_integral<_Fp>::value>::type*)
: __f_(0)
{
typedef allocator_traits<_Alloc> __alloc_traits;
if (__function::__not_null(__f))
{
typedef __function::__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)> _FF;
if (sizeof(_FF) <= sizeof(__buf_))
{
__f_ = (__base*)&__buf_;
::new (__f_) _FF(__f, __a0);
}
else
{
typedef typename __rebind_alloc_helper<__alloc_traits, _FF>::type _Ap;
_Ap __a(__a0);
typedef __allocator_destructor<_Ap> _Dp;
unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1));
::new (__hold.get()) _FF(__f, _Alloc(__a));
__f_ = __hold.release();
}
}
}
template<class _Rp, class _A0, class _A1, class _A2>
function<_Rp(_A0, _A1, _A2)>&
function<_Rp(_A0, _A1, _A2)>::operator=(const function& __f)
{
if (__f)
function(__f).swap(*this);
else
*this = std::__1::__get_nullptr_t();
return *this;
}
template<class _Rp, class _A0, class _A1, class _A2>
function<_Rp(_A0, _A1, _A2)>&
function<_Rp(_A0, _A1, _A2)>::operator=(nullptr_t)
{
__base* __t = __f_;
__f_ = 0;
if (__t == (__base*)&__buf_)
__t->destroy();
else if (__t)
__t->destroy_deallocate();
return *this;
}
template<class _Rp, class _A0, class _A1, class _A2>
template <class _Fp>
typename enable_if
<
!is_integral<_Fp>::value,
function<_Rp(_A0, _A1, _A2)>&
>::type
function<_Rp(_A0, _A1, _A2)>::operator=(_Fp __f)
{
function(std::__1::move(__f)).swap(*this);
return *this;
}
template<class _Rp, class _A0, class _A1, class _A2>
function<_Rp(_A0, _A1, _A2)>::~function()
{
if (__f_ == (__base*)&__buf_)
__f_->destroy();
else if (__f_)
__f_->destroy_deallocate();
}
template<class _Rp, class _A0, class _A1, class _A2>
void
function<_Rp(_A0, _A1, _A2)>::swap(function& __f)
{
if (std::__1::addressof(__f) == this)
return;
if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_)
{
typename aligned_storage<sizeof(__buf_)>::type __tempbuf;
__base* __t = (__base*)&__tempbuf;
__f_->__clone(__t);
__f_->destroy();
__f_ = 0;
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = 0;
__f_ = (__base*)&__buf_;
__t->__clone((__base*)&__f.__buf_);
__t->destroy();
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f_ == (__base*)&__buf_)
{
__f_->__clone((__base*)&__f.__buf_);
__f_->destroy();
__f_ = __f.__f_;
__f.__f_ = (__base*)&__f.__buf_;
}
else if (__f.__f_ == (__base*)&__f.__buf_)
{
__f.__f_->__clone((__base*)&__buf_);
__f.__f_->destroy();
__f.__f_ = __f_;
__f_ = (__base*)&__buf_;
}
else
std::__1::swap(__f_, __f.__f_);
}
template<class _Rp, class _A0, class _A1, class _A2>
_Rp
function<_Rp(_A0, _A1, _A2)>::operator()(_A0 __a0, _A1 __a1, _A2 __a2) const
{
if (__f_ == 0)
__throw_bad_function_call();
return (*__f_)(__a0, __a1, __a2);
}
template<class _Rp, class _A0, class _A1, class _A2>
const std::type_info&
function<_Rp(_A0, _A1, _A2)>::target_type() const
{
if (__f_ == 0)
return typeid(void);
return __f_->target_type();
}
template<class _Rp, class _A0, class _A1, class _A2>
template <typename _Tp>
_Tp*
function<_Rp(_A0, _A1, _A2)>::target()
{
if (__f_ == 0)
return (_Tp*)0;
return (_Tp*) const_cast<void *>(__f_->target(typeid(_Tp)));
}
template<class _Rp, class _A0, class _A1, class _A2>
template <typename _Tp>
const _Tp*
function<_Rp(_A0, _A1, _A2)>::target() const
{
if (__f_ == 0)
return (const _Tp*)0;
return (const _Tp*)__f_->target(typeid(_Tp));
}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(const function<_Fp>& __f, nullptr_t) {return !__f;}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator==(nullptr_t, const function<_Fp>& __f) {return !__f;}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(const function<_Fp>& __f, nullptr_t) {return (bool)__f;}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
operator!=(nullptr_t, const function<_Fp>& __f) {return (bool)__f;}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(function<_Fp>& __x, function<_Fp>& __y)
{return __x.swap(__y);}
# 1978 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 2 3
template<class _Tp> struct __is_bind_expression : public false_type {};
template<class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_bind_expression
: public __is_bind_expression<typename remove_cv<_Tp>::type> {};
template<class _Tp> struct __is_placeholder : public integral_constant<int, 0> {};
template<class _Tp> struct __attribute__ ((__type_visibility__("default"))) is_placeholder
: public __is_placeholder<typename remove_cv<_Tp>::type> {};
namespace placeholders
{
template <int _Np> struct __ph {};
__attribute__ ((__visibility__("default"))) extern const __ph<1> _1;
__attribute__ ((__visibility__("default"))) extern const __ph<2> _2;
__attribute__ ((__visibility__("default"))) extern const __ph<3> _3;
__attribute__ ((__visibility__("default"))) extern const __ph<4> _4;
__attribute__ ((__visibility__("default"))) extern const __ph<5> _5;
__attribute__ ((__visibility__("default"))) extern const __ph<6> _6;
__attribute__ ((__visibility__("default"))) extern const __ph<7> _7;
__attribute__ ((__visibility__("default"))) extern const __ph<8> _8;
__attribute__ ((__visibility__("default"))) extern const __ph<9> _9;
__attribute__ ((__visibility__("default"))) extern const __ph<10> _10;
# 2032 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
}
template<int _Np>
struct __is_placeholder<placeholders::__ph<_Np> >
: public integral_constant<int, _Np> {};
# 2411 "/Library/Developer/CommandLineTools/usr/include/c++/v1/functional" 3
} }
# 193 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 2 3
# 201 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 205 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 2 3
namespace std {inline namespace __1 {
class __attribute__ ((__visibility__("default"))) recursive_mutex
{
__libcpp_recursive_mutex_t __m_;
public:
recursive_mutex();
~recursive_mutex();
private:
recursive_mutex(const recursive_mutex&);
recursive_mutex& operator=(const recursive_mutex&);
public:
void lock();
bool try_lock() throw();
void unlock() throw();
typedef __libcpp_recursive_mutex_t* native_handle_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
native_handle_type native_handle() {return &__m_;}
};
class __attribute__ ((__visibility__("default"))) timed_mutex
{
mutex __m_;
condition_variable __cv_;
bool __locked_;
public:
timed_mutex();
~timed_mutex();
private:
timed_mutex(const timed_mutex&);
timed_mutex& operator=(const timed_mutex&);
public:
void lock();
bool try_lock() throw();
template <class _Rep, class _Period>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool try_lock_for(const chrono::duration<_Rep, _Period>& __d)
{return try_lock_until(chrono::steady_clock::now() + __d);}
template <class _Clock, class _Duration>
inline __attribute__ ((__visibility__("hidden")))
bool try_lock_until(const chrono::time_point<_Clock, _Duration>& __t);
void unlock() throw();
};
template <class _Clock, class _Duration>
bool
timed_mutex::try_lock_until(const chrono::time_point<_Clock, _Duration>& __t)
{
using namespace chrono;
unique_lock<mutex> __lk(__m_);
bool no_timeout = _Clock::now() < __t;
while (no_timeout && __locked_)
no_timeout = __cv_.wait_until(__lk, __t) == cv_status::no_timeout;
if (!__locked_)
{
__locked_ = true;
return true;
}
return false;
}
class __attribute__ ((__visibility__("default"))) recursive_timed_mutex
{
mutex __m_;
condition_variable __cv_;
size_t __count_;
__libcpp_thread_id __id_;
public:
recursive_timed_mutex();
~recursive_timed_mutex();
private:
recursive_timed_mutex(const recursive_timed_mutex&);
recursive_timed_mutex& operator=(const recursive_timed_mutex&);
public:
void lock();
bool try_lock() throw();
template <class _Rep, class _Period>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool try_lock_for(const chrono::duration<_Rep, _Period>& __d)
{return try_lock_until(chrono::steady_clock::now() + __d);}
template <class _Clock, class _Duration>
inline __attribute__ ((__visibility__("hidden")))
bool try_lock_until(const chrono::time_point<_Clock, _Duration>& __t);
void unlock() throw();
};
template <class _Clock, class _Duration>
bool
recursive_timed_mutex::try_lock_until(const chrono::time_point<_Clock, _Duration>& __t)
{
using namespace chrono;
__libcpp_thread_id __id = __libcpp_thread_get_current_id();
unique_lock<mutex> lk(__m_);
if (__libcpp_thread_id_equal(__id, __id_))
{
if (__count_ == numeric_limits<size_t>::max())
return false;
++__count_;
return true;
}
bool no_timeout = _Clock::now() < __t;
while (no_timeout && __count_ != 0)
no_timeout = __cv_.wait_until(lk, __t) == cv_status::no_timeout;
if (__count_ == 0)
{
__count_ = 1;
__id_ = __id;
return true;
}
return false;
}
template <class _L0, class _L1>
int
try_lock(_L0& __l0, _L1& __l1)
{
unique_lock<_L0> __u0(__l0, try_to_lock);
if (__u0.owns_lock())
{
if (__l1.try_lock())
{
__u0.release();
return -1;
}
else
return 1;
}
return 0;
}
# 369 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
template <class _L0, class _L1>
void
lock(_L0& __l0, _L1& __l1)
{
while (true)
{
{
unique_lock<_L0> __u0(__l0);
if (__l1.try_lock())
{
__u0.release();
break;
}
}
__libcpp_thread_yield();
{
unique_lock<_L1> __u1(__l1);
if (__l0.try_lock())
{
__u1.release();
break;
}
}
__libcpp_thread_yield();
}
}
# 552 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
struct __attribute__ ((__type_visibility__("default"))) once_flag;
# 562 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
template<class _Callable>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void call_once(once_flag&, _Callable&);
template<class _Callable>
__attribute__ ((__visibility__("hidden"), __always_inline__))
void call_once(once_flag&, const _Callable&);
struct __attribute__ ((__type_visibility__("default"))) once_flag
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
once_flag() throw() : __state_(0) {}
private:
once_flag(const once_flag&);
once_flag& operator=(const once_flag&);
unsigned long __state_;
template<class _Callable>
friend
void call_once(once_flag&, _Callable&);
template<class _Callable>
friend
void call_once(once_flag&, const _Callable&);
};
# 627 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
template <class _Fp>
class __call_once_param
{
_Fp& __f_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __call_once_param(_Fp& __f) : __f_(__f) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator()()
{
__f_();
}
};
template <class _Fp>
void
__call_once_proxy(void* __vp)
{
__call_once_param<_Fp>* __p = static_cast<__call_once_param<_Fp>*>(__vp);
(*__p)();
}
__attribute__ ((__visibility__("default"))) void __call_once(volatile unsigned long&, void*, void(*)(void*));
# 672 "/Library/Developer/CommandLineTools/usr/include/c++/v1/mutex" 3
template<class _Callable>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
call_once(once_flag& __flag, _Callable& __func)
{
if (__libcpp_acquire_load(&__flag.__state_) != ~0ul)
{
__call_once_param<_Callable> __p(__func);
__call_once(__flag.__state_, &__p, &__call_once_proxy<_Callable>);
}
}
template<class _Callable>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
call_once(once_flag& __flag, const _Callable& __func)
{
if (__libcpp_acquire_load(&__flag.__state_) != ~0ul)
{
__call_once_param<const _Callable> __p(__func);
__call_once(__flag.__state_, &__p, &__call_once_proxy<const _Callable>);
}
}
} }
# 19 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale.h" 1 3
# 41 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale.h" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/locale.h" 1 3 4
# 40 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/locale.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_locale.h" 1 3 4
# 43 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_locale.h" 3 4
struct lconv {
char *decimal_point;
char *thousands_sep;
char *grouping;
char *int_curr_symbol;
char *currency_symbol;
char *mon_decimal_point;
char *mon_thousands_sep;
char *mon_grouping;
char *positive_sign;
char *negative_sign;
char int_frac_digits;
char frac_digits;
char p_cs_precedes;
char p_sep_by_space;
char n_cs_precedes;
char n_sep_by_space;
char p_sign_posn;
char n_sign_posn;
char int_p_cs_precedes;
char int_n_cs_precedes;
char int_p_sep_by_space;
char int_n_sep_by_space;
char int_p_sign_posn;
char int_n_sign_posn;
};
extern "C" {
struct lconv *localeconv(void);
}
# 41 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/locale.h" 2 3 4
# 52 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/locale.h" 3 4
extern "C" {
char *setlocale(int, const char *);
}
# 44 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale.h" 2 3
# 22 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 2 3
# 39 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 1 3 4
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_xlocale.h" 1 3 4
# 29 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_xlocale.h" 3 4
struct _xlocale;
typedef struct _xlocale * locale_t;
extern "C" {
int ___mb_cur_max(void);
int ___mb_cur_max_l(locale_t);
}
# 35 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 62 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 3 4
extern "C" {
extern const locale_t _c_locale;
locale_t duplocale(locale_t);
int freelocale(locale_t);
struct lconv * localeconv_l(locale_t);
locale_t newlocale(int, const char *, locale_t);
const char * querylocale(int, locale_t);
locale_t uselocale(locale_t);
}
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_ctype.h" 1 3 4
# 37 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_ctype.h" 3 4
extern "C" {
unsigned long ___runetype_l(__darwin_ct_rune_t, locale_t);
__darwin_ct_rune_t ___tolower_l(__darwin_ct_rune_t, locale_t);
__darwin_ct_rune_t ___toupper_l(__darwin_ct_rune_t, locale_t);
}
extern "C" {
int __maskrune_l(__darwin_ct_rune_t, unsigned long, locale_t);
}
inline int
__istype_l(__darwin_ct_rune_t _c, unsigned long _f, locale_t _l)
{
return !!(isascii(_c) ? (_DefaultRuneLocale.__runetype[_c] & _f)
: __maskrune_l(_c, _f, _l));
}
inline __darwin_ct_rune_t
__toupper_l(__darwin_ct_rune_t _c, locale_t _l)
{
return isascii(_c) ? _DefaultRuneLocale.__mapupper[_c]
: ___toupper_l(_c, _l);
}
inline __darwin_ct_rune_t
__tolower_l(__darwin_ct_rune_t _c, locale_t _l)
{
return isascii(_c) ? _DefaultRuneLocale.__maplower[_c]
: ___tolower_l(_c, _l);
}
inline int
__wcwidth_l(__darwin_ct_rune_t _c, locale_t _l)
{
unsigned int _x;
if (_c == 0)
return (0);
_x = (unsigned int)__maskrune_l(_c, 0xe0000000L|0x00040000L, _l);
if ((_x & 0xe0000000L) != 0)
return ((_x & 0xe0000000L) >> 30);
return ((_x & 0x00040000L) != 0 ? 1 : -1);
}
inline int
digittoint_l(int c, locale_t l)
{
return (__maskrune_l(c, 0x0F, l));
}
inline int
isalnum_l(int c, locale_t l)
{
return (__istype_l(c, 0x00000100L|0x00000400L, l));
}
inline int
isalpha_l(int c, locale_t l)
{
return (__istype_l(c, 0x00000100L, l));
}
inline int
isblank_l(int c, locale_t l)
{
return (__istype_l(c, 0x00020000L, l));
}
inline int
iscntrl_l(int c, locale_t l)
{
return (__istype_l(c, 0x00000200L, l));
}
inline int
isdigit_l(int c, locale_t l)
{
return (__istype_l(c, 0x00000400L, l));
}
inline int
isgraph_l(int c, locale_t l)
{
return (__istype_l(c, 0x00000800L, l));
}
inline int
ishexnumber_l(int c, locale_t l)
{
return (__istype_l(c, 0x00010000L, l));
}
inline int
isideogram_l(int c, locale_t l)
{
return (__istype_l(c, 0x00080000L, l));
}
inline int
islower_l(int c, locale_t l)
{
return (__istype_l(c, 0x00001000L, l));
}
inline int
isnumber_l(int c, locale_t l)
{
return (__istype_l(c, 0x00000400L, l));
}
inline int
isphonogram_l(int c, locale_t l)
{
return (__istype_l(c, 0x00200000L, l));
}
inline int
isprint_l(int c, locale_t l)
{
return (__istype_l(c, 0x00040000L, l));
}
inline int
ispunct_l(int c, locale_t l)
{
return (__istype_l(c, 0x00002000L, l));
}
inline int
isrune_l(int c, locale_t l)
{
return (__istype_l(c, 0xFFFFFFF0L, l));
}
inline int
isspace_l(int c, locale_t l)
{
return (__istype_l(c, 0x00004000L, l));
}
inline int
isspecial_l(int c, locale_t l)
{
return (__istype_l(c, 0x00100000L, l));
}
inline int
isupper_l(int c, locale_t l)
{
return (__istype_l(c, 0x00008000L, l));
}
inline int
isxdigit_l(int c, locale_t l)
{
return (__istype_l(c, 0x00010000L, l));
}
inline int
tolower_l(int c, locale_t l)
{
return (__tolower_l(c, l));
}
inline int
toupper_l(int c, locale_t l)
{
return (__toupper_l(c, l));
}
# 75 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/__wctype.h" 1 3 4
# 33 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/__wctype.h" 3 4
inline int
iswalnum_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00000100L|0x00000400L, _l));
}
inline int
iswalpha_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00000100L, _l));
}
inline int
iswcntrl_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00000200L, _l));
}
inline int
iswctype_l(wint_t _wc, wctype_t _charclass, locale_t _l)
{
return (__istype_l(_wc, _charclass, _l));
}
inline int
iswdigit_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00000400L, _l));
}
inline int
iswgraph_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00000800L, _l));
}
inline int
iswlower_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00001000L, _l));
}
inline int
iswprint_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00040000L, _l));
}
inline int
iswpunct_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00002000L, _l));
}
inline int
iswspace_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00004000L, _l));
}
inline int
iswupper_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00008000L, _l));
}
inline int
iswxdigit_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00010000L, _l));
}
inline wint_t
towlower_l(wint_t _wc, locale_t _l)
{
return (__tolower_l(_wc, _l));
}
inline wint_t
towupper_l(wint_t _wc, locale_t _l)
{
return (__toupper_l(_wc, _l));
}
# 138 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/__wctype.h" 3 4
extern "C" {
wctype_t
wctype_l(const char *, locale_t);
}
# 78 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 92 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_stdio.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_stdio.h" 3 4
extern "C" {
int fprintf_l(FILE * , locale_t , const char * , ...)
__attribute__((__format__ (__printf__, 3, 4)));
int fscanf_l(FILE * , locale_t , const char * , ...)
__attribute__((__format__ (__scanf__, 3, 4)));
int printf_l(locale_t , const char * , ...)
__attribute__((__format__ (__printf__, 2, 3)));
int scanf_l(locale_t , const char * , ...)
__attribute__((__format__ (__scanf__, 2, 3)));
int sprintf_l(char * , locale_t , const char * , ...)
__attribute__((__format__ (__printf__, 3, 4))) __attribute__((__availability__(swift, unavailable, message="Use snprintf_l instead.")));
int sscanf_l(const char * , locale_t , const char * , ...)
__attribute__((__format__ (__scanf__, 3, 4)));
int vfprintf_l(FILE * , locale_t , const char * , va_list)
__attribute__((__format__ (__printf__, 3, 0)));
int vprintf_l(locale_t , const char * , va_list)
__attribute__((__format__ (__printf__, 2, 0)));
int vsprintf_l(char * , locale_t , const char * , va_list)
__attribute__((__format__ (__printf__, 3, 0))) __attribute__((__availability__(swift, unavailable, message="Use vsnprintf_l instead.")));
int snprintf_l(char * , size_t, locale_t , const char * , ...)
__attribute__((__format__ (__printf__, 4, 5)));
int vfscanf_l(FILE * , locale_t , const char * , va_list)
__attribute__((__format__ (__scanf__, 3, 0)));
int vscanf_l(locale_t , const char * , va_list)
__attribute__((__format__ (__scanf__, 2, 0)));
int vsnprintf_l(char * , size_t, locale_t , const char * , va_list)
__attribute__((__format__ (__printf__, 4, 0)));
int vsscanf_l(const char * , locale_t , const char * , va_list)
__attribute__((__format__ (__scanf__, 3, 0)));
int dprintf_l(int, locale_t , const char * , ...)
__attribute__((__format__ (__printf__, 3, 4))) __attribute__((availability(macosx,introduced=10.7)));
int vdprintf_l(int, locale_t , const char * , va_list)
__attribute__((__format__ (__printf__, 3, 0))) __attribute__((availability(macosx,introduced=10.7)));
int asprintf_l(char ** , locale_t , const char * , ...)
__attribute__((__format__ (__printf__, 3, 4)));
int vasprintf_l(char ** , locale_t , const char * , va_list)
__attribute__((__format__ (__printf__, 3, 0)));
}
# 93 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_stdlib.h" 1 3 4
# 29 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_stdlib.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_wchar_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_stdlib.h" 2 3 4
extern "C" {
double atof_l(const char *, locale_t);
int atoi_l(const char *, locale_t);
long atol_l(const char *, locale_t);
long long
atoll_l(const char *, locale_t);
int mblen_l(const char *, size_t, locale_t);
size_t mbstowcs_l(wchar_t * , const char * , size_t,
locale_t);
int mbtowc_l(wchar_t * , const char * , size_t,
locale_t);
double strtod_l(const char *, char **, locale_t) __asm("_" "strtod_l" );
float strtof_l(const char *, char **, locale_t) __asm("_" "strtof_l" );
long strtol_l(const char *, char **, int, locale_t);
long double
strtold_l(const char *, char **, locale_t);
long long
strtoll_l(const char *, char **, int, locale_t);
long long
strtoq_l(const char *, char **, int, locale_t);
unsigned long
strtoul_l(const char *, char **, int, locale_t);
unsigned long long
strtoull_l(const char *, char **, int, locale_t);
unsigned long long
strtouq_l(const char *, char **, int, locale_t);
size_t wcstombs_l(char * , const wchar_t * , size_t,
locale_t);
int wctomb_l(char *, wchar_t, locale_t);
}
# 96 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_string.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_string.h" 3 4
extern "C" {
int strcoll_l(const char *, const char *, locale_t);
size_t strxfrm_l(char *, const char *, size_t, locale_t);
int strcasecmp_l(const char *, const char *, locale_t);
char *strcasestr_l(const char *, const char *, locale_t);
int strncasecmp_l(const char *, const char *, size_t, locale_t);
}
# 99 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_time.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_time.h" 3 4
extern "C" {
size_t strftime_l(char * , size_t, const char * ,
const struct tm * , locale_t)
__asm("_" "strftime_l" ) __attribute__((__format__ (__strftime__, 3, 0)));
char *strptime_l(const char * , const char * ,
struct tm * , locale_t)
__asm("_" "strptime_l" ) __attribute__((__format__ (__strftime__, 2, 0)));
}
# 102 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wchar.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wchar.h" 3 4
extern "C" {
wint_t btowc_l(int, locale_t);
wint_t fgetwc_l(FILE *, locale_t);
wchar_t *fgetws_l(wchar_t * , int, FILE * , locale_t);
wint_t fputwc_l(wchar_t, FILE *, locale_t);
int fputws_l(const wchar_t * , FILE * , locale_t);
int fwprintf_l(FILE * , locale_t, const wchar_t * , ...);
int fwscanf_l(FILE * , locale_t, const wchar_t * , ...);
wint_t getwc_l(FILE *, locale_t);
wint_t getwchar_l(locale_t);
size_t mbrlen_l(const char * , size_t, mbstate_t * ,
locale_t);
size_t mbrtowc_l(wchar_t * , const char * , size_t,
mbstate_t * , locale_t);
int mbsinit_l(const mbstate_t *, locale_t);
size_t mbsrtowcs_l(wchar_t * , const char ** , size_t,
mbstate_t * , locale_t);
wint_t putwc_l(wchar_t, FILE *, locale_t);
wint_t putwchar_l(wchar_t, locale_t);
int swprintf_l(wchar_t * , size_t n, locale_t,
const wchar_t * , ...);
int swscanf_l(const wchar_t * , locale_t,
const wchar_t * , ...);
wint_t ungetwc_l(wint_t, FILE *, locale_t);
int vfwprintf_l(FILE * , locale_t, const wchar_t * ,
__darwin_va_list);
int vswprintf_l(wchar_t * , size_t n, locale_t,
const wchar_t * , __darwin_va_list);
int vwprintf_l(locale_t, const wchar_t * , __darwin_va_list);
size_t wcrtomb_l(char * , wchar_t, mbstate_t * ,
locale_t);
int wcscoll_l(const wchar_t *, const wchar_t *, locale_t);
size_t wcsftime_l(wchar_t * , size_t, const wchar_t * ,
const struct tm * , locale_t)
__asm("_" "wcsftime_l" );
size_t wcsrtombs_l(char * , const wchar_t ** , size_t,
mbstate_t * , locale_t);
double wcstod_l(const wchar_t * , wchar_t ** , locale_t);
long wcstol_l(const wchar_t * , wchar_t ** , int,
locale_t);
unsigned long
wcstoul_l(const wchar_t * , wchar_t ** , int,
locale_t);
int wcswidth_l(const wchar_t *, size_t, locale_t);
size_t wcsxfrm_l(wchar_t * , const wchar_t * , size_t,
locale_t);
int wctob_l(wint_t, locale_t);
int wcwidth_l(wchar_t, locale_t);
int wprintf_l(locale_t, const wchar_t * , ...);
int wscanf_l(locale_t, const wchar_t * , ...);
}
# 91 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wchar.h" 3 4
extern "C" {
int vfwscanf_l(FILE * , locale_t, const wchar_t * ,
__darwin_va_list);
int vswscanf_l(const wchar_t * , locale_t,
const wchar_t * , __darwin_va_list);
int vwscanf_l(locale_t, const wchar_t * , __darwin_va_list);
float wcstof_l(const wchar_t * , wchar_t ** , locale_t);
long double
wcstold_l(const wchar_t * , wchar_t ** , locale_t);
long long
wcstoll_l(const wchar_t * , wchar_t ** , int,
locale_t);
unsigned long long
wcstoull_l(const wchar_t * , wchar_t ** , int,
locale_t);
}
# 118 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wchar.h" 3 4
extern "C" {
size_t mbsnrtowcs_l(wchar_t * , const char ** , size_t,
size_t, mbstate_t * , locale_t);
int wcscasecmp_l(const wchar_t *, const wchar_t *, locale_t) __attribute__((availability(macosx,introduced=10.7)));
int wcsncasecmp_l(const wchar_t *, const wchar_t *, size_t n, locale_t) __attribute__((availability(macosx,introduced=10.7)));
size_t wcsnrtombs_l(char * , const wchar_t ** , size_t,
size_t, mbstate_t * , locale_t);
}
extern "C" {
wchar_t *fgetwln_l(FILE * , size_t *, locale_t) __attribute__((availability(macosx,introduced=10.7)));
}
# 105 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wctype.h" 1 3 4
# 34 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wctype.h" 3 4
inline int
iswblank_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00020000L, _l));
}
inline int
iswhexnumber_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00010000L, _l));
}
inline int
iswideogram_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00080000L, _l));
}
inline int
iswnumber_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00000400L, _l));
}
inline int
iswphonogram_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00200000L, _l));
}
inline int
iswrune_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0xFFFFFFF0L, _l));
}
inline int
iswspecial_l(wint_t _wc, locale_t _l)
{
return (__istype_l(_wc, 0x00100000L, _l));
}
# 90 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale/_wctype.h" 3 4
extern "C" {
wint_t nextwctype_l(wint_t, wctype_t, locale_t);
wint_t towctrans_l(wint_t, wctrans_t, locale_t);
wctrans_t
wctrans_l(const char *, locale_t);
}
# 108 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/xlocale.h" 2 3 4
# 40 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 2 3
# 48 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
namespace std {inline namespace __1 {
# 97 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
class __attribute__ ((__visibility__("default"))) locale;
template <class _Facet>
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool
has_facet(const locale&) throw();
template <class _Facet>
__attribute__ ((__visibility__("hidden"), __always_inline__))
const _Facet&
use_facet(const locale&);
class __attribute__ ((__visibility__("default"))) locale
{
public:
class __attribute__ ((__visibility__("default"))) facet;
class __attribute__ ((__visibility__("default"))) id;
typedef int category;
__attribute__((availability(macosx,strict,introduced=10.9))) __attribute__((availability(ios,strict,introduced=7.0)))
static const category
none = 0,
collate = (1 << 0),
ctype = (1 << 1),
monetary = (1 << 3),
numeric = (1 << 4),
time = (1 << 5),
messages = (1 << 2),
all = collate | ctype | monetary | numeric | time | messages;
locale() throw();
locale(const locale&) throw();
explicit locale(const char*);
explicit locale(const string&);
locale(const locale&, const char*, category);
locale(const locale&, const string&, category);
template <class _Facet>
__attribute__ ((__visibility__("hidden"), __always_inline__)) locale(const locale&, _Facet*);
locale(const locale&, const locale&, category);
~locale();
const locale& operator=(const locale&) throw();
template <class _Facet>
inline __attribute__ ((__visibility__("hidden")))
locale combine(const locale&) const;
string name() const;
bool operator==(const locale&) const;
bool operator!=(const locale& __y) const {return !(*this == __y);}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden")))
bool operator()(const basic_string<_CharT, _Traits, _Allocator>&,
const basic_string<_CharT, _Traits, _Allocator>&) const;
static locale global(const locale&);
static const locale& classic();
private:
class __imp;
__imp* __locale_;
void __install_ctor(const locale&, facet*, long);
static locale& __global();
bool has_facet(id&) const;
const facet* use_facet(id&) const;
template <class _Facet> friend bool has_facet(const locale&) throw();
template <class _Facet> friend const _Facet& use_facet(const locale&);
};
class __attribute__ ((__visibility__("default"))) locale::facet
: public __shared_count
{
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit facet(size_t __refs = 0)
: __shared_count(static_cast<long>(__refs)-1) {}
virtual ~facet();
private:
virtual void __on_zero_shared() throw();
};
class __attribute__ ((__visibility__("default"))) locale::id
{
once_flag __flag_;
int32_t __id_;
static int32_t __next_id;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) id() :__id_(0) {}
private:
void __init();
void operator=(const id&);
id(const id&);
public:
long __get();
friend class locale;
friend class locale::__imp;
};
template <class _Facet>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
locale::locale(const locale& __other, _Facet* __f)
{
__install_ctor(__other, __f, __f ? __f->id.__get() : 0);
}
template <class _Facet>
locale
locale::combine(const locale& __other) const
{
if (!std::__1::has_facet<_Facet>(__other))
__throw_runtime_error("locale::combine: locale missing facet");
return locale(*this, &const_cast<_Facet&>(std::__1::use_facet<_Facet>(__other)));
}
template <class _Facet>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
has_facet(const locale& __l) throw()
{
return __l.has_facet(_Facet::id);
}
template <class _Facet>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
const _Facet&
use_facet(const locale& __l)
{
return static_cast<const _Facet&>(*__l.use_facet(_Facet::id));
}
template <class _CharT>
class __attribute__ ((__type_visibility__("default"))) collate
: public locale::facet
{
public:
typedef _CharT char_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit collate(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int compare(const char_type* __lo1, const char_type* __hi1,
const char_type* __lo2, const char_type* __hi2) const
{
return do_compare(__lo1, __hi1, __lo2, __hi2);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
string_type transform(const char_type* __lo, const char_type* __hi) const
{
return do_transform(__lo, __hi);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
long hash(const char_type* __lo, const char_type* __hi) const
{
return do_hash(__lo, __hi);
}
static locale::id id;
protected:
~collate();
virtual int do_compare(const char_type* __lo1, const char_type* __hi1,
const char_type* __lo2, const char_type* __hi2) const;
virtual string_type do_transform(const char_type* __lo, const char_type* __hi) const
{return string_type(__lo, __hi);}
virtual long do_hash(const char_type* __lo, const char_type* __hi) const;
};
template <class _CharT> locale::id collate<_CharT>::id;
template <class _CharT>
collate<_CharT>::~collate()
{
}
template <class _CharT>
int
collate<_CharT>::do_compare(const char_type* __lo1, const char_type* __hi1,
const char_type* __lo2, const char_type* __hi2) const
{
for (; __lo2 != __hi2; ++__lo1, ++__lo2)
{
if (__lo1 == __hi1 || *__lo1 < *__lo2)
return -1;
if (*__lo2 < *__lo1)
return 1;
}
return __lo1 != __hi1;
}
template <class _CharT>
long
collate<_CharT>::do_hash(const char_type* __lo, const char_type* __hi) const
{
size_t __h = 0;
const size_t __sr = 8 * sizeof(size_t) - 8;
const size_t __mask = size_t(0xF) << (__sr + 4);
for(const char_type* __p = __lo; __p != __hi; ++__p)
{
__h = (__h << 4) + static_cast<size_t>(*__p);
size_t __g = __h & __mask;
__h ^= __g | (__g >> __sr);
}
return static_cast<long>(__h);
}
extern template class __attribute__ ((__visibility__("default"))) collate<char>;
extern template class __attribute__ ((__visibility__("default"))) collate<wchar_t>;
template <class _CharT> class __attribute__ ((__type_visibility__("default"))) collate_byname;
template <>
class __attribute__ ((__visibility__("default"))) collate_byname<char>
: public collate<char>
{
locale_t __l;
public:
typedef char char_type;
typedef basic_string<char_type> string_type;
explicit collate_byname(const char* __n, size_t __refs = 0);
explicit collate_byname(const string& __n, size_t __refs = 0);
protected:
~collate_byname();
virtual int do_compare(const char_type* __lo1, const char_type* __hi1,
const char_type* __lo2, const char_type* __hi2) const;
virtual string_type do_transform(const char_type* __lo, const char_type* __hi) const;
};
template <>
class __attribute__ ((__visibility__("default"))) collate_byname<wchar_t>
: public collate<wchar_t>
{
locale_t __l;
public:
typedef wchar_t char_type;
typedef basic_string<char_type> string_type;
explicit collate_byname(const char* __n, size_t __refs = 0);
explicit collate_byname(const string& __n, size_t __refs = 0);
protected:
~collate_byname();
virtual int do_compare(const char_type* __lo1, const char_type* __hi1,
const char_type* __lo2, const char_type* __hi2) const;
virtual string_type do_transform(const char_type* __lo, const char_type* __hi) const;
};
template <class _CharT, class _Traits, class _Allocator>
bool
locale::operator()(const basic_string<_CharT, _Traits, _Allocator>& __x,
const basic_string<_CharT, _Traits, _Allocator>& __y) const
{
return std::__1::use_facet<std::__1::collate<_CharT> >(*this).compare(
__x.data(), __x.data() + __x.size(),
__y.data(), __y.data() + __y.size()) < 0;
}
class __attribute__ ((__visibility__("default"))) ctype_base
{
public:
# 411 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
typedef __uint32_t mask;
static const mask space = 0x00004000L;
static const mask print = 0x00040000L;
static const mask cntrl = 0x00000200L;
static const mask upper = 0x00008000L;
static const mask lower = 0x00001000L;
static const mask alpha = 0x00000100L;
static const mask digit = 0x00000400L;
static const mask punct = 0x00002000L;
static const mask xdigit = 0x00010000L;
static const mask blank = 0x00020000L;
# 473 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
static const mask alnum = alpha | digit;
static const mask graph = alnum | punct;
__attribute__ ((__visibility__("hidden"), __always_inline__)) ctype_base() {}
};
template <class _CharT> class __attribute__ ((__type_visibility__("default"))) ctype;
template <>
class __attribute__ ((__visibility__("default"))) ctype<wchar_t>
: public locale::facet,
public ctype_base
{
public:
typedef wchar_t char_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit ctype(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool is(mask __m, char_type __c) const
{
return do_is(__m, __c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* is(const char_type* __low, const char_type* __high, mask* __vec) const
{
return do_is(__low, __high, __vec);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* scan_is(mask __m, const char_type* __low, const char_type* __high) const
{
return do_scan_is(__m, __low, __high);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* scan_not(mask __m, const char_type* __low, const char_type* __high) const
{
return do_scan_not(__m, __low, __high);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type toupper(char_type __c) const
{
return do_toupper(__c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* toupper(char_type* __low, const char_type* __high) const
{
return do_toupper(__low, __high);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type tolower(char_type __c) const
{
return do_tolower(__c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* tolower(char_type* __low, const char_type* __high) const
{
return do_tolower(__low, __high);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type widen(char __c) const
{
return do_widen(__c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char* widen(const char* __low, const char* __high, char_type* __to) const
{
return do_widen(__low, __high, __to);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char narrow(char_type __c, char __dfault) const
{
return do_narrow(__c, __dfault);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* narrow(const char_type* __low, const char_type* __high, char __dfault, char* __to) const
{
return do_narrow(__low, __high, __dfault, __to);
}
static locale::id id;
protected:
~ctype();
virtual bool do_is(mask __m, char_type __c) const;
virtual const char_type* do_is(const char_type* __low, const char_type* __high, mask* __vec) const;
virtual const char_type* do_scan_is(mask __m, const char_type* __low, const char_type* __high) const;
virtual const char_type* do_scan_not(mask __m, const char_type* __low, const char_type* __high) const;
virtual char_type do_toupper(char_type) const;
virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const;
virtual char_type do_tolower(char_type) const;
virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const;
virtual char_type do_widen(char) const;
virtual const char* do_widen(const char* __low, const char* __high, char_type* __dest) const;
virtual char do_narrow(char_type, char __dfault) const;
virtual const char_type* do_narrow(const char_type* __low, const char_type* __high, char __dfault, char* __dest) const;
};
template <>
class __attribute__ ((__visibility__("default"))) ctype<char>
: public locale::facet, public ctype_base
{
const mask* __tab_;
bool __del_;
public:
typedef char char_type;
explicit ctype(const mask* __tab = 0, bool __del = false, size_t __refs = 0);
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool is(mask __m, char_type __c) const
{
return isascii(__c) ? (__tab_[static_cast<int>(__c)] & __m) !=0 : false;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* is(const char_type* __low, const char_type* __high, mask* __vec) const
{
for (; __low != __high; ++__low, ++__vec)
*__vec = isascii(*__low) ? __tab_[static_cast<int>(*__low)] : 0;
return __low;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* scan_is (mask __m, const char_type* __low, const char_type* __high) const
{
for (; __low != __high; ++__low)
if (isascii(*__low) && (__tab_[static_cast<int>(*__low)] & __m))
break;
return __low;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* scan_not(mask __m, const char_type* __low, const char_type* __high) const
{
for (; __low != __high; ++__low)
if (!(isascii(*__low) && (__tab_[static_cast<int>(*__low)] & __m)))
break;
return __low;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type toupper(char_type __c) const
{
return do_toupper(__c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* toupper(char_type* __low, const char_type* __high) const
{
return do_toupper(__low, __high);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type tolower(char_type __c) const
{
return do_tolower(__c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char_type* tolower(char_type* __low, const char_type* __high) const
{
return do_tolower(__low, __high);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type widen(char __c) const
{
return do_widen(__c);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char* widen(const char* __low, const char* __high, char_type* __to) const
{
return do_widen(__low, __high, __to);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
char narrow(char_type __c, char __dfault) const
{
return do_narrow(__c, __dfault);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
const char* narrow(const char_type* __low, const char_type* __high, char __dfault, char* __to) const
{
return do_narrow(__low, __high, __dfault, __to);
}
static locale::id id;
static const size_t table_size = (1 <<8 );
__attribute__ ((__visibility__("hidden"), __always_inline__)) const mask* table() const throw() {return __tab_;}
static const mask* classic_table() throw();
# 692 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__locale" 3
protected:
~ctype();
virtual char_type do_toupper(char_type __c) const;
virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const;
virtual char_type do_tolower(char_type __c) const;
virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const;
virtual char_type do_widen(char __c) const;
virtual const char* do_widen(const char* __low, const char* __high, char_type* __to) const;
virtual char do_narrow(char_type __c, char __dfault) const;
virtual const char* do_narrow(const char_type* __low, const char_type* __high, char __dfault, char* __to) const;
};
template <class _CharT> class __attribute__ ((__type_visibility__("default"))) ctype_byname;
template <>
class __attribute__ ((__visibility__("default"))) ctype_byname<char>
: public ctype<char>
{
locale_t __l;
public:
explicit ctype_byname(const char*, size_t = 0);
explicit ctype_byname(const string&, size_t = 0);
protected:
~ctype_byname();
virtual char_type do_toupper(char_type) const;
virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const;
virtual char_type do_tolower(char_type) const;
virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const;
};
template <>
class __attribute__ ((__visibility__("default"))) ctype_byname<wchar_t>
: public ctype<wchar_t>
{
locale_t __l;
public:
explicit ctype_byname(const char*, size_t = 0);
explicit ctype_byname(const string&, size_t = 0);
protected:
~ctype_byname();
virtual bool do_is(mask __m, char_type __c) const;
virtual const char_type* do_is(const char_type* __low, const char_type* __high, mask* __vec) const;
virtual const char_type* do_scan_is(mask __m, const char_type* __low, const char_type* __high) const;
virtual const char_type* do_scan_not(mask __m, const char_type* __low, const char_type* __high) const;
virtual char_type do_toupper(char_type) const;
virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const;
virtual char_type do_tolower(char_type) const;
virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const;
virtual char_type do_widen(char) const;
virtual const char* do_widen(const char* __low, const char* __high, char_type* __dest) const;
virtual char do_narrow(char_type, char __dfault) const;
virtual const char_type* do_narrow(const char_type* __low, const char_type* __high, char __dfault, char* __dest) const;
};
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isspace(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::space, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isprint(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::print, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
iscntrl(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::cntrl, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isupper(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::upper, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
islower(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::lower, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isalpha(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::alpha, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isdigit(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::digit, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
ispunct(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::punct, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isxdigit(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::xdigit, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isalnum(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::alnum, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
isgraph(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).is(ctype_base::graph, __c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_CharT
toupper(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).toupper(__c);
}
template <class _CharT>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_CharT
tolower(_CharT __c, const locale& __loc)
{
return use_facet<ctype<_CharT> >(__loc).tolower(__c);
}
class __attribute__ ((__visibility__("default"))) codecvt_base
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) codecvt_base() {}
enum result {ok, partial, error, noconv};
};
template <class _InternT, class _ExternT, class _StateT> class __attribute__ ((__type_visibility__("default"))) codecvt;
template <>
class __attribute__ ((__visibility__("default"))) codecvt<char, char, mbstate_t>
: public locale::facet,
public codecvt_base
{
public:
typedef char intern_type;
typedef char extern_type;
typedef mbstate_t state_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_unshift(__st, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const
{
return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int encoding() const throw()
{
return do_encoding();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool always_noconv() const throw()
{
return do_always_noconv();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const
{
return do_length(__st, __frm, __end, __mx);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int max_length() const throw()
{
return do_max_length();
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt(const char*, size_t __refs = 0)
: locale::facet(__refs) {}
~codecvt();
virtual result do_out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual result do_in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const;
virtual result do_unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual int do_encoding() const throw();
virtual bool do_always_noconv() const throw();
virtual int do_length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const;
virtual int do_max_length() const throw();
};
template <>
class __attribute__ ((__visibility__("default"))) codecvt<wchar_t, char, mbstate_t>
: public locale::facet,
public codecvt_base
{
locale_t __l;
public:
typedef wchar_t intern_type;
typedef char extern_type;
typedef mbstate_t state_type;
explicit codecvt(size_t __refs = 0);
__attribute__ ((__visibility__("hidden"), __always_inline__))
result out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_unshift(__st, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const
{
return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int encoding() const throw()
{
return do_encoding();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool always_noconv() const throw()
{
return do_always_noconv();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const
{
return do_length(__st, __frm, __end, __mx);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int max_length() const throw()
{
return do_max_length();
}
static locale::id id;
protected:
explicit codecvt(const char*, size_t __refs = 0);
~codecvt();
virtual result do_out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual result do_in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const;
virtual result do_unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual int do_encoding() const throw();
virtual bool do_always_noconv() const throw();
virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, size_t __mx) const;
virtual int do_max_length() const throw();
};
template <>
class __attribute__ ((__visibility__("default"))) codecvt<char16_t, char, mbstate_t>
: public locale::facet,
public codecvt_base
{
public:
typedef char16_t intern_type;
typedef char extern_type;
typedef mbstate_t state_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_unshift(__st, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const
{
return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int encoding() const throw()
{
return do_encoding();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool always_noconv() const throw()
{
return do_always_noconv();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const
{
return do_length(__st, __frm, __end, __mx);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int max_length() const throw()
{
return do_max_length();
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt(const char*, size_t __refs = 0)
: locale::facet(__refs) {}
~codecvt();
virtual result do_out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual result do_in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const;
virtual result do_unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual int do_encoding() const throw();
virtual bool do_always_noconv() const throw();
virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, size_t __mx) const;
virtual int do_max_length() const throw();
};
template <>
class __attribute__ ((__visibility__("default"))) codecvt<char32_t, char, mbstate_t>
: public locale::facet,
public codecvt_base
{
public:
typedef char32_t intern_type;
typedef char extern_type;
typedef mbstate_t state_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const
{
return do_unshift(__st, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
result in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const
{
return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int encoding() const throw()
{
return do_encoding();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool always_noconv() const throw()
{
return do_always_noconv();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const
{
return do_length(__st, __frm, __end, __mx);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
int max_length() const throw()
{
return do_max_length();
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt(const char*, size_t __refs = 0)
: locale::facet(__refs) {}
~codecvt();
virtual result do_out(state_type& __st,
const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual result do_in(state_type& __st,
const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt,
intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const;
virtual result do_unshift(state_type& __st,
extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const;
virtual int do_encoding() const throw();
virtual bool do_always_noconv() const throw();
virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, size_t __mx) const;
virtual int do_max_length() const throw();
};
template <class _InternT, class _ExternT, class _StateT>
class __attribute__ ((__type_visibility__("default"))) codecvt_byname
: public codecvt<_InternT, _ExternT, _StateT>
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt_byname(const char* __nm, size_t __refs = 0)
: codecvt<_InternT, _ExternT, _StateT>(__nm, __refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit codecvt_byname(const string& __nm, size_t __refs = 0)
: codecvt<_InternT, _ExternT, _StateT>(__nm.c_str(), __refs) {}
protected:
~codecvt_byname();
};
template <class _InternT, class _ExternT, class _StateT>
codecvt_byname<_InternT, _ExternT, _StateT>::~codecvt_byname()
{
}
extern template class __attribute__ ((__visibility__("default"))) codecvt_byname<char, char, mbstate_t>;
extern template class __attribute__ ((__visibility__("default"))) codecvt_byname<wchar_t, char, mbstate_t>;
extern template class __attribute__ ((__visibility__("default"))) codecvt_byname<char16_t, char, mbstate_t>;
extern template class __attribute__ ((__visibility__("default"))) codecvt_byname<char32_t, char, mbstate_t>;
__attribute__ ((noreturn)) __attribute__ ((__visibility__("default"))) void __throw_runtime_error(const char*);
template <size_t _Np>
struct __narrow_to_utf8
{
template <class _OutputIterator, class _CharT>
_OutputIterator
operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const;
};
template <>
struct __narrow_to_utf8<8>
{
template <class _OutputIterator, class _CharT>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const
{
for (; __wb < __we; ++__wb, ++__s)
*__s = *__wb;
return __s;
}
};
template <>
struct __narrow_to_utf8<16>
: public codecvt<char16_t, char, mbstate_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
__narrow_to_utf8() : codecvt<char16_t, char, mbstate_t>(1) {}
~__narrow_to_utf8();
template <class _OutputIterator, class _CharT>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const
{
result __r = ok;
mbstate_t __mb;
while (__wb < __we && __r != error)
{
const int __sz = 32;
char __buf[__sz];
char* __bn;
const char16_t* __wn = (const char16_t*)__wb;
__r = do_out(__mb, (const char16_t*)__wb, (const char16_t*)__we, __wn,
__buf, __buf+__sz, __bn);
if (__r == codecvt_base::error || __wn == (const char16_t*)__wb)
__throw_runtime_error("locale not supported");
for (const char* __p = __buf; __p < __bn; ++__p, ++__s)
*__s = *__p;
__wb = (const _CharT*)__wn;
}
return __s;
}
};
template <>
struct __narrow_to_utf8<32>
: public codecvt<char32_t, char, mbstate_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
__narrow_to_utf8() : codecvt<char32_t, char, mbstate_t>(1) {}
~__narrow_to_utf8();
template <class _OutputIterator, class _CharT>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const
{
result __r = ok;
mbstate_t __mb;
while (__wb < __we && __r != error)
{
const int __sz = 32;
char __buf[__sz];
char* __bn;
const char32_t* __wn = (const char32_t*)__wb;
__r = do_out(__mb, (const char32_t*)__wb, (const char32_t*)__we, __wn,
__buf, __buf+__sz, __bn);
if (__r == codecvt_base::error || __wn == (const char32_t*)__wb)
__throw_runtime_error("locale not supported");
for (const char* __p = __buf; __p < __bn; ++__p, ++__s)
*__s = *__p;
__wb = (const _CharT*)__wn;
}
return __s;
}
};
template <size_t _Np>
struct __widen_from_utf8
{
template <class _OutputIterator>
_OutputIterator
operator()(_OutputIterator __s, const char* __nb, const char* __ne) const;
};
template <>
struct __widen_from_utf8<8>
{
template <class _OutputIterator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
operator()(_OutputIterator __s, const char* __nb, const char* __ne) const
{
for (; __nb < __ne; ++__nb, ++__s)
*__s = *__nb;
return __s;
}
};
template <>
struct __widen_from_utf8<16>
: public codecvt<char16_t, char, mbstate_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
__widen_from_utf8() : codecvt<char16_t, char, mbstate_t>(1) {}
~__widen_from_utf8();
template <class _OutputIterator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
operator()(_OutputIterator __s, const char* __nb, const char* __ne) const
{
result __r = ok;
mbstate_t __mb;
while (__nb < __ne && __r != error)
{
const int __sz = 32;
char16_t __buf[__sz];
char16_t* __bn;
const char* __nn = __nb;
__r = do_in(__mb, __nb, __ne - __nb > __sz ? __nb+__sz : __ne, __nn,
__buf, __buf+__sz, __bn);
if (__r == codecvt_base::error || __nn == __nb)
__throw_runtime_error("locale not supported");
for (const char16_t* __p = __buf; __p < __bn; ++__p, ++__s)
*__s = (wchar_t)*__p;
__nb = __nn;
}
return __s;
}
};
template <>
struct __widen_from_utf8<32>
: public codecvt<char32_t, char, mbstate_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
__widen_from_utf8() : codecvt<char32_t, char, mbstate_t>(1) {}
~__widen_from_utf8();
template <class _OutputIterator>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_OutputIterator
operator()(_OutputIterator __s, const char* __nb, const char* __ne) const
{
result __r = ok;
mbstate_t __mb;
while (__nb < __ne && __r != error)
{
const int __sz = 32;
char32_t __buf[__sz];
char32_t* __bn;
const char* __nn = __nb;
__r = do_in(__mb, __nb, __ne - __nb > __sz ? __nb+__sz : __ne, __nn,
__buf, __buf+__sz, __bn);
if (__r == codecvt_base::error || __nn == __nb)
__throw_runtime_error("locale not supported");
for (const char32_t* __p = __buf; __p < __bn; ++__p, ++__s)
*__s = (wchar_t)*__p;
__nb = __nn;
}
return __s;
}
};
template <class _CharT> class __attribute__ ((__type_visibility__("default"))) numpunct;
template <>
class __attribute__ ((__visibility__("default"))) numpunct<char>
: public locale::facet
{
public:
typedef char char_type;
typedef basic_string<char_type> string_type;
explicit numpunct(size_t __refs = 0);
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type decimal_point() const {return do_decimal_point();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type thousands_sep() const {return do_thousands_sep();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string grouping() const {return do_grouping();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type truename() const {return do_truename();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type falsename() const {return do_falsename();}
static locale::id id;
protected:
~numpunct();
virtual char_type do_decimal_point() const;
virtual char_type do_thousands_sep() const;
virtual string do_grouping() const;
virtual string_type do_truename() const;
virtual string_type do_falsename() const;
char_type __decimal_point_;
char_type __thousands_sep_;
string __grouping_;
};
template <>
class __attribute__ ((__visibility__("default"))) numpunct<wchar_t>
: public locale::facet
{
public:
typedef wchar_t char_type;
typedef basic_string<char_type> string_type;
explicit numpunct(size_t __refs = 0);
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type decimal_point() const {return do_decimal_point();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type thousands_sep() const {return do_thousands_sep();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string grouping() const {return do_grouping();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type truename() const {return do_truename();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type falsename() const {return do_falsename();}
static locale::id id;
protected:
~numpunct();
virtual char_type do_decimal_point() const;
virtual char_type do_thousands_sep() const;
virtual string do_grouping() const;
virtual string_type do_truename() const;
virtual string_type do_falsename() const;
char_type __decimal_point_;
char_type __thousands_sep_;
string __grouping_;
};
template <class _CharT> class __attribute__ ((__type_visibility__("default"))) numpunct_byname;
template <>
class __attribute__ ((__visibility__("default"))) numpunct_byname<char>
: public numpunct<char>
{
public:
typedef char char_type;
typedef basic_string<char_type> string_type;
explicit numpunct_byname(const char* __nm, size_t __refs = 0);
explicit numpunct_byname(const string& __nm, size_t __refs = 0);
protected:
~numpunct_byname();
private:
void __init(const char*);
};
template <>
class __attribute__ ((__visibility__("default"))) numpunct_byname<wchar_t>
: public numpunct<wchar_t>
{
public:
typedef wchar_t char_type;
typedef basic_string<char_type> string_type;
explicit numpunct_byname(const char* __nm, size_t __refs = 0);
explicit numpunct_byname(const string& __nm, size_t __refs = 0);
protected:
~numpunct_byname();
private:
void __init(const char*);
};
} }
# 217 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ios" 2 3
# 225 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ios" 3
namespace std {inline namespace __1 {
typedef ptrdiff_t streamsize;
class __attribute__ ((__visibility__("default"))) ios_base
{
public:
class __attribute__ ((__visibility__("default"))) failure;
typedef unsigned int fmtflags;
static const fmtflags boolalpha = 0x0001;
static const fmtflags dec = 0x0002;
static const fmtflags fixed = 0x0004;
static const fmtflags hex = 0x0008;
static const fmtflags internal = 0x0010;
static const fmtflags left = 0x0020;
static const fmtflags oct = 0x0040;
static const fmtflags right = 0x0080;
static const fmtflags scientific = 0x0100;
static const fmtflags showbase = 0x0200;
static const fmtflags showpoint = 0x0400;
static const fmtflags showpos = 0x0800;
static const fmtflags skipws = 0x1000;
static const fmtflags unitbuf = 0x2000;
static const fmtflags uppercase = 0x4000;
static const fmtflags adjustfield = left | right | internal;
static const fmtflags basefield = dec | oct | hex;
static const fmtflags floatfield = scientific | fixed;
typedef unsigned int iostate;
static const iostate badbit = 0x1;
static const iostate eofbit = 0x2;
static const iostate failbit = 0x4;
static const iostate goodbit = 0x0;
typedef unsigned int openmode;
static const openmode app = 0x01;
static const openmode ate = 0x02;
static const openmode binary = 0x04;
static const openmode in = 0x08;
static const openmode out = 0x10;
static const openmode trunc = 0x20;
enum seekdir {beg, cur, end};
typedef iostate io_state;
typedef openmode open_mode;
typedef seekdir seek_dir;
typedef std::__1::streamoff streamoff;
typedef std::__1::streampos streampos;
class __attribute__ ((__visibility__("default"))) Init;
__attribute__ ((__visibility__("hidden"), __always_inline__)) fmtflags flags() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) fmtflags flags(fmtflags __fmtfl);
__attribute__ ((__visibility__("hidden"), __always_inline__)) fmtflags setf(fmtflags __fmtfl);
__attribute__ ((__visibility__("hidden"), __always_inline__)) fmtflags setf(fmtflags __fmtfl, fmtflags __mask);
__attribute__ ((__visibility__("hidden"), __always_inline__)) void unsetf(fmtflags __mask);
__attribute__ ((__visibility__("hidden"), __always_inline__)) streamsize precision() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) streamsize precision(streamsize __prec);
__attribute__ ((__visibility__("hidden"), __always_inline__)) streamsize width() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) streamsize width(streamsize __wide);
locale imbue(const locale& __loc);
locale getloc() const;
static int xalloc();
long& iword(int __index);
void*& pword(int __index);
virtual ~ios_base();
enum event { erase_event, imbue_event, copyfmt_event };
typedef void (*event_callback)(event, ios_base&, int __index);
void register_callback(event_callback __fn, int __index);
private:
ios_base(const ios_base&);
ios_base& operator=(const ios_base&);
public:
static bool sync_with_stdio(bool __sync = true);
__attribute__ ((__visibility__("hidden"), __always_inline__)) iostate rdstate() const;
void clear(iostate __state = goodbit);
__attribute__ ((__visibility__("hidden"), __always_inline__)) void setstate(iostate __state);
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool good() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool eof() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool fail() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool bad() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) iostate exceptions() const;
__attribute__ ((__visibility__("hidden"), __always_inline__)) void exceptions(iostate __iostate);
void __set_badbit_and_consider_rethrow();
void __set_failbit_and_consider_rethrow();
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base() {
}
void init(void* __sb);
__attribute__ ((__visibility__("hidden"), __always_inline__)) void* rdbuf() const {return __rdbuf_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void rdbuf(void* __sb)
{
__rdbuf_ = __sb;
clear();
}
void __call_callbacks(event);
void copyfmt(const ios_base&);
void move(ios_base&);
void swap(ios_base&) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void set_rdbuf(void* __sb)
{
__rdbuf_ = __sb;
}
private:
fmtflags __fmtflags_;
streamsize __precision_;
streamsize __width_;
iostate __rdstate_;
iostate __exceptions_;
void* __rdbuf_;
void* __loc_;
event_callback* __fn_;
int* __index_;
size_t __event_size_;
size_t __event_cap_;
static atomic<int> __xindex_;
long* __iarray_;
size_t __iarray_size_;
size_t __iarray_cap_;
void** __parray_;
size_t __parray_size_;
size_t __parray_cap_;
};
struct __attribute__ ((__visibility__("default"))) io_errc { enum __lx
{
stream = 1
};
__lx __v_; __attribute__ ((__visibility__("hidden"), __always_inline__)) io_errc(__lx __v) : __v_(__v) {} __attribute__ ((__visibility__("hidden"), __always_inline__)) explicit io_errc(int __v) : __v_(static_cast<__lx>(__v)) {} __attribute__ ((__visibility__("hidden"), __always_inline__)) operator int() const {return __v_;} };
template <>
struct __attribute__ ((__type_visibility__("default"))) is_error_code_enum<io_errc> : public true_type { };
template <>
struct __attribute__ ((__type_visibility__("default"))) is_error_code_enum<io_errc::__lx> : public true_type { };
__attribute__ ((__visibility__("default")))
const error_category& iostream_category() throw();
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
error_code
make_error_code(io_errc __e) throw()
{
return error_code(static_cast<int>(__e), iostream_category());
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
error_condition
make_error_condition(io_errc __e) throw()
{
return error_condition(static_cast<int>(__e), iostream_category());
}
class __attribute__ ((__visibility__("default"))) ios_base::failure
: public system_error
{
public:
explicit failure(const string& __msg, const error_code& __ec = io_errc::stream);
explicit failure(const char* __msg, const error_code& __ec = io_errc::stream);
virtual ~failure() throw();
};
class __attribute__ ((__visibility__("default"))) ios_base::Init
{
public:
Init();
~Init();
};
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base::fmtflags
ios_base::flags() const
{
return __fmtflags_;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base::fmtflags
ios_base::flags(fmtflags __fmtfl)
{
fmtflags __r = __fmtflags_;
__fmtflags_ = __fmtfl;
return __r;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base::fmtflags
ios_base::setf(fmtflags __fmtfl)
{
fmtflags __r = __fmtflags_;
__fmtflags_ |= __fmtfl;
return __r;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
ios_base::unsetf(fmtflags __mask)
{
__fmtflags_ &= ~__mask;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base::fmtflags
ios_base::setf(fmtflags __fmtfl, fmtflags __mask)
{
fmtflags __r = __fmtflags_;
unsetf(__mask);
__fmtflags_ |= __fmtfl & __mask;
return __r;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
streamsize
ios_base::precision() const
{
return __precision_;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
streamsize
ios_base::precision(streamsize __prec)
{
streamsize __r = __precision_;
__precision_ = __prec;
return __r;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
streamsize
ios_base::width() const
{
return __width_;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
streamsize
ios_base::width(streamsize __wide)
{
streamsize __r = __width_;
__width_ = __wide;
return __r;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base::iostate
ios_base::rdstate() const
{
return __rdstate_;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
ios_base::setstate(iostate __state)
{
clear(__rdstate_ | __state);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
ios_base::good() const
{
return __rdstate_ == 0;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
ios_base::eof() const
{
return (__rdstate_ & eofbit) != 0;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
ios_base::fail() const
{
return (__rdstate_ & (failbit | badbit)) != 0;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
ios_base::bad() const
{
return (__rdstate_ & badbit) != 0;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base::iostate
ios_base::exceptions() const
{
return __exceptions_;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
ios_base::exceptions(iostate __iostate)
{
__exceptions_ = __iostate;
clear(__rdstate_);
}
struct __attribute__ ((__visibility__("default"))) __cxx03_bool {
typedef void (__cxx03_bool::*__bool_type)();
void __true_value() {}
};
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_ios
: public ios_base
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator __cxx03_bool::__bool_type() const {
return !fail() ? &__cxx03_bool::__true_value : std::__1::__get_nullptr_t();
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator!() const {return fail();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iostate rdstate() const {return ios_base::rdstate();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void clear(iostate __state = goodbit) {ios_base::clear(__state);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void setstate(iostate __state) {ios_base::setstate(__state);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool good() const {return ios_base::good();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool eof() const {return ios_base::eof();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool fail() const {return ios_base::fail();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool bad() const {return ios_base::bad();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iostate exceptions() const {return ios_base::exceptions();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void exceptions(iostate __iostate) {ios_base::exceptions(__iostate);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_ios(basic_streambuf<char_type,traits_type>* __sb);
virtual ~basic_ios();
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<char_type, traits_type>* tie() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<char_type, traits_type>* tie(basic_ostream<char_type, traits_type>* __tiestr);
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_streambuf<char_type, traits_type>* rdbuf() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_streambuf<char_type, traits_type>* rdbuf(basic_streambuf<char_type, traits_type>* __sb);
basic_ios& copyfmt(const basic_ios& __rhs);
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type fill() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type fill(char_type __ch);
__attribute__ ((__visibility__("hidden"), __always_inline__))
locale imbue(const locale& __loc);
__attribute__ ((__visibility__("hidden"), __always_inline__))
char narrow(char_type __c, char __dfault) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
char_type widen(char __c) const;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ios() {
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void init(basic_streambuf<char_type, traits_type>* __sb);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void move(basic_ios& __rhs);
__attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(basic_ios& __rhs) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void set_rdbuf(basic_streambuf<char_type, traits_type>* __sb);
private:
basic_ostream<char_type, traits_type>* __tie_;
mutable int_type __fill_;
};
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ios<_CharT, _Traits>::basic_ios(basic_streambuf<char_type,traits_type>* __sb)
{
init(__sb);
}
template <class _CharT, class _Traits>
basic_ios<_CharT, _Traits>::~basic_ios()
{
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_ios<_CharT, _Traits>::init(basic_streambuf<char_type, traits_type>* __sb)
{
ios_base::init(__sb);
__tie_ = 0;
__fill_ = traits_type::eof();
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>*
basic_ios<_CharT, _Traits>::tie() const
{
return __tie_;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>*
basic_ios<_CharT, _Traits>::tie(basic_ostream<char_type, traits_type>* __tiestr)
{
basic_ostream<char_type, traits_type>* __r = __tie_;
__tie_ = __tiestr;
return __r;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_streambuf<_CharT, _Traits>*
basic_ios<_CharT, _Traits>::rdbuf() const
{
return static_cast<basic_streambuf<char_type, traits_type>*>(ios_base::rdbuf());
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_streambuf<_CharT, _Traits>*
basic_ios<_CharT, _Traits>::rdbuf(basic_streambuf<char_type, traits_type>* __sb)
{
basic_streambuf<char_type, traits_type>* __r = rdbuf();
ios_base::rdbuf(__sb);
return __r;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
locale
basic_ios<_CharT, _Traits>::imbue(const locale& __loc)
{
locale __r = getloc();
ios_base::imbue(__loc);
if (rdbuf())
rdbuf()->pubimbue(__loc);
return __r;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
char
basic_ios<_CharT, _Traits>::narrow(char_type __c, char __dfault) const
{
return use_facet<ctype<char_type> >(getloc()).narrow(__c, __dfault);
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_CharT
basic_ios<_CharT, _Traits>::widen(char __c) const
{
return use_facet<ctype<char_type> >(getloc()).widen(__c);
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_CharT
basic_ios<_CharT, _Traits>::fill() const
{
if (traits_type::eq_int_type(traits_type::eof(), __fill_))
__fill_ = widen(' ');
return __fill_;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
_CharT
basic_ios<_CharT, _Traits>::fill(char_type __ch)
{
char_type __r = __fill_;
__fill_ = __ch;
return __r;
}
template <class _CharT, class _Traits>
basic_ios<_CharT, _Traits>&
basic_ios<_CharT, _Traits>::copyfmt(const basic_ios& __rhs)
{
if (this != &__rhs)
{
__call_callbacks(erase_event);
ios_base::copyfmt(__rhs);
__tie_ = __rhs.__tie_;
__fill_ = __rhs.__fill_;
__call_callbacks(copyfmt_event);
exceptions(__rhs.exceptions());
}
return *this;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_ios<_CharT, _Traits>::move(basic_ios& __rhs)
{
ios_base::move(__rhs);
__tie_ = __rhs.__tie_;
__rhs.__tie_ = 0;
__fill_ = __rhs.__fill_;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_ios<_CharT, _Traits>::swap(basic_ios& __rhs) throw()
{
ios_base::swap(__rhs);
std::__1::swap(__tie_, __rhs.__tie_);
std::__1::swap(__fill_, __rhs.__fill_);
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
basic_ios<_CharT, _Traits>::set_rdbuf(basic_streambuf<char_type, traits_type>* __sb)
{
ios_base::set_rdbuf(__sb);
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
boolalpha(ios_base& __str)
{
__str.setf(ios_base::boolalpha);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
noboolalpha(ios_base& __str)
{
__str.unsetf(ios_base::boolalpha);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
showbase(ios_base& __str)
{
__str.setf(ios_base::showbase);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
noshowbase(ios_base& __str)
{
__str.unsetf(ios_base::showbase);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
showpoint(ios_base& __str)
{
__str.setf(ios_base::showpoint);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
noshowpoint(ios_base& __str)
{
__str.unsetf(ios_base::showpoint);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
showpos(ios_base& __str)
{
__str.setf(ios_base::showpos);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
noshowpos(ios_base& __str)
{
__str.unsetf(ios_base::showpos);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
skipws(ios_base& __str)
{
__str.setf(ios_base::skipws);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
noskipws(ios_base& __str)
{
__str.unsetf(ios_base::skipws);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
uppercase(ios_base& __str)
{
__str.setf(ios_base::uppercase);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
nouppercase(ios_base& __str)
{
__str.unsetf(ios_base::uppercase);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
unitbuf(ios_base& __str)
{
__str.setf(ios_base::unitbuf);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
nounitbuf(ios_base& __str)
{
__str.unsetf(ios_base::unitbuf);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
internal(ios_base& __str)
{
__str.setf(ios_base::internal, ios_base::adjustfield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
left(ios_base& __str)
{
__str.setf(ios_base::left, ios_base::adjustfield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
right(ios_base& __str)
{
__str.setf(ios_base::right, ios_base::adjustfield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
dec(ios_base& __str)
{
__str.setf(ios_base::dec, ios_base::basefield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
hex(ios_base& __str)
{
__str.setf(ios_base::hex, ios_base::basefield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
oct(ios_base& __str)
{
__str.setf(ios_base::oct, ios_base::basefield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
fixed(ios_base& __str)
{
__str.setf(ios_base::fixed, ios_base::floatfield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
scientific(ios_base& __str)
{
__str.setf(ios_base::scientific, ios_base::floatfield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
hexfloat(ios_base& __str)
{
__str.setf(ios_base::fixed | ios_base::scientific, ios_base::floatfield);
return __str;
}
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
ios_base&
defaultfloat(ios_base& __str)
{
__str.unsetf(ios_base::floatfield);
return __str;
}
template <class _CharT, class _Traits>
class __save_flags
{
typedef basic_ios<_CharT, _Traits> __stream_type;
typedef typename __stream_type::fmtflags fmtflags;
__stream_type& __stream_;
fmtflags __fmtflags_;
_CharT __fill_;
__save_flags(const __save_flags&);
__save_flags& operator=(const __save_flags&);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __save_flags(__stream_type& __stream)
: __stream_(__stream),
__fmtflags_(__stream.flags()),
__fill_(__stream.fill())
{}
__attribute__ ((__visibility__("hidden"), __always_inline__))
~__save_flags()
{
__stream_.flags(__fmtflags_);
__stream_.fill(__fill_);
}
};
} }
# 139 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/streambuf" 1 3
# 117 "/Library/Developer/CommandLineTools/usr/include/c++/v1/streambuf" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 121 "/Library/Developer/CommandLineTools/usr/include/c++/v1/streambuf" 2 3
namespace std {inline namespace __1 {
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_streambuf
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
virtual ~basic_streambuf();
inline __attribute__((__visibility__("default"), __always_inline__))
locale pubimbue(const locale& __loc) {
imbue(__loc);
locale __r = __loc_;
__loc_ = __loc;
return __r;
}
inline __attribute__((__visibility__("default"), __always_inline__))
locale getloc() const { return __loc_; }
inline __attribute__((__visibility__("default"), __always_inline__))
basic_streambuf* pubsetbuf(char_type* __s, streamsize __n)
{ return setbuf(__s, __n); }
inline __attribute__((__visibility__("default"), __always_inline__))
pos_type pubseekoff(off_type __off, ios_base::seekdir __way,
ios_base::openmode __which = ios_base::in | ios_base::out)
{ return seekoff(__off, __way, __which); }
inline __attribute__((__visibility__("default"), __always_inline__))
pos_type pubseekpos(pos_type __sp,
ios_base::openmode __which = ios_base::in | ios_base::out)
{ return seekpos(__sp, __which); }
inline __attribute__((__visibility__("default"), __always_inline__))
int pubsync() { return sync(); }
inline __attribute__((__visibility__("default"), __always_inline__))
streamsize in_avail() {
if (__ninp_ < __einp_)
return static_cast<streamsize>(__einp_ - __ninp_);
return showmanyc();
}
inline __attribute__((__visibility__("default"), __always_inline__))
int_type snextc() {
if (sbumpc() == traits_type::eof())
return traits_type::eof();
return sgetc();
}
inline __attribute__((__visibility__("default"), __always_inline__))
int_type sbumpc() {
if (__ninp_ == __einp_)
return uflow();
return traits_type::to_int_type(*__ninp_++);
}
inline __attribute__((__visibility__("default"), __always_inline__))
int_type sgetc() {
if (__ninp_ == __einp_)
return underflow();
return traits_type::to_int_type(*__ninp_);
}
inline __attribute__((__visibility__("default"), __always_inline__))
streamsize sgetn(char_type* __s, streamsize __n)
{ return xsgetn(__s, __n); }
inline __attribute__((__visibility__("default"), __always_inline__))
int_type sputbackc(char_type __c) {
if (__binp_ == __ninp_ || !traits_type::eq(__c, __ninp_[-1]))
return pbackfail(traits_type::to_int_type(__c));
return traits_type::to_int_type(*--__ninp_);
}
inline __attribute__((__visibility__("default"), __always_inline__))
int_type sungetc() {
if (__binp_ == __ninp_)
return pbackfail();
return traits_type::to_int_type(*--__ninp_);
}
inline __attribute__((__visibility__("default"), __always_inline__))
int_type sputc(char_type __c) {
if (__nout_ == __eout_)
return overflow(traits_type::to_int_type(__c));
*__nout_++ = __c;
return traits_type::to_int_type(__c);
}
inline __attribute__((__visibility__("default"), __always_inline__))
streamsize sputn(const char_type* __s, streamsize __n)
{ return xsputn(__s, __n); }
protected:
basic_streambuf();
basic_streambuf(const basic_streambuf& __rhs);
basic_streambuf& operator=(const basic_streambuf& __rhs);
void swap(basic_streambuf& __rhs);
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type* eback() const {return __binp_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type* gptr() const {return __ninp_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type* egptr() const {return __einp_;}
inline __attribute__((__visibility__("default"), __always_inline__))
void gbump(int __n) { __ninp_ += __n; }
inline __attribute__((__visibility__("default"), __always_inline__))
void setg(char_type* __gbeg, char_type* __gnext, char_type* __gend) {
__binp_ = __gbeg;
__ninp_ = __gnext;
__einp_ = __gend;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type* pbase() const {return __bout_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type* pptr() const {return __nout_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type* epptr() const {return __eout_;}
inline __attribute__((__visibility__("default"), __always_inline__))
void pbump(int __n) { __nout_ += __n; }
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __pbump(streamsize __n) { __nout_ += __n; }
inline __attribute__((__visibility__("default"), __always_inline__))
void setp(char_type* __pbeg, char_type* __pend) {
__bout_ = __nout_ = __pbeg;
__eout_ = __pend;
}
virtual void imbue(const locale& __loc);
virtual basic_streambuf* setbuf(char_type* __s, streamsize __n);
virtual pos_type seekoff(off_type __off, ios_base::seekdir __way,
ios_base::openmode __which = ios_base::in | ios_base::out);
virtual pos_type seekpos(pos_type __sp,
ios_base::openmode __which = ios_base::in | ios_base::out);
virtual int sync();
virtual streamsize showmanyc();
virtual streamsize xsgetn(char_type* __s, streamsize __n);
virtual int_type underflow();
virtual int_type uflow();
virtual int_type pbackfail(int_type __c = traits_type::eof());
virtual streamsize xsputn(const char_type* __s, streamsize __n);
virtual int_type overflow(int_type __c = traits_type::eof());
private:
locale __loc_;
char_type* __binp_;
char_type* __ninp_;
char_type* __einp_;
char_type* __bout_;
char_type* __nout_;
char_type* __eout_;
};
template <class _CharT, class _Traits>
basic_streambuf<_CharT, _Traits>::~basic_streambuf()
{
}
template <class _CharT, class _Traits>
basic_streambuf<_CharT, _Traits>::basic_streambuf()
: __binp_(0),
__ninp_(0),
__einp_(0),
__bout_(0),
__nout_(0),
__eout_(0)
{
}
template <class _CharT, class _Traits>
basic_streambuf<_CharT, _Traits>::basic_streambuf(const basic_streambuf& __sb)
: __loc_(__sb.__loc_),
__binp_(__sb.__binp_),
__ninp_(__sb.__ninp_),
__einp_(__sb.__einp_),
__bout_(__sb.__bout_),
__nout_(__sb.__nout_),
__eout_(__sb.__eout_)
{
}
template <class _CharT, class _Traits>
basic_streambuf<_CharT, _Traits>&
basic_streambuf<_CharT, _Traits>::operator=(const basic_streambuf& __sb)
{
__loc_ = __sb.__loc_;
__binp_ = __sb.__binp_;
__ninp_ = __sb.__ninp_;
__einp_ = __sb.__einp_;
__bout_ = __sb.__bout_;
__nout_ = __sb.__nout_;
__eout_ = __sb.__eout_;
return *this;
}
template <class _CharT, class _Traits>
void
basic_streambuf<_CharT, _Traits>::swap(basic_streambuf& __sb)
{
std::__1::swap(__loc_, __sb.__loc_);
std::__1::swap(__binp_, __sb.__binp_);
std::__1::swap(__ninp_, __sb.__ninp_);
std::__1::swap(__einp_, __sb.__einp_);
std::__1::swap(__bout_, __sb.__bout_);
std::__1::swap(__nout_, __sb.__nout_);
std::__1::swap(__eout_, __sb.__eout_);
}
template <class _CharT, class _Traits>
void
basic_streambuf<_CharT, _Traits>::imbue(const locale&)
{
}
template <class _CharT, class _Traits>
basic_streambuf<_CharT, _Traits>*
basic_streambuf<_CharT, _Traits>::setbuf(char_type*, streamsize)
{
return this;
}
template <class _CharT, class _Traits>
typename basic_streambuf<_CharT, _Traits>::pos_type
basic_streambuf<_CharT, _Traits>::seekoff(off_type, ios_base::seekdir,
ios_base::openmode)
{
return pos_type(off_type(-1));
}
template <class _CharT, class _Traits>
typename basic_streambuf<_CharT, _Traits>::pos_type
basic_streambuf<_CharT, _Traits>::seekpos(pos_type, ios_base::openmode)
{
return pos_type(off_type(-1));
}
template <class _CharT, class _Traits>
int
basic_streambuf<_CharT, _Traits>::sync()
{
return 0;
}
template <class _CharT, class _Traits>
streamsize
basic_streambuf<_CharT, _Traits>::showmanyc()
{
return 0;
}
template <class _CharT, class _Traits>
streamsize
basic_streambuf<_CharT, _Traits>::xsgetn(char_type* __s, streamsize __n)
{
const int_type __eof = traits_type::eof();
int_type __c;
streamsize __i = 0;
while(__i < __n)
{
if (__ninp_ < __einp_)
{
const streamsize __len = std::__1::min(static_cast<streamsize>(2147483647),
std::__1::min(__einp_ - __ninp_, __n - __i));
traits_type::copy(__s, __ninp_, __len);
__s += __len;
__i += __len;
this->gbump(__len);
}
else if ((__c = uflow()) != __eof)
{
*__s = traits_type::to_char_type(__c);
++__s;
++__i;
}
else
break;
}
return __i;
}
template <class _CharT, class _Traits>
typename basic_streambuf<_CharT, _Traits>::int_type
basic_streambuf<_CharT, _Traits>::underflow()
{
return traits_type::eof();
}
template <class _CharT, class _Traits>
typename basic_streambuf<_CharT, _Traits>::int_type
basic_streambuf<_CharT, _Traits>::uflow()
{
if (underflow() == traits_type::eof())
return traits_type::eof();
return traits_type::to_int_type(*__ninp_++);
}
template <class _CharT, class _Traits>
typename basic_streambuf<_CharT, _Traits>::int_type
basic_streambuf<_CharT, _Traits>::pbackfail(int_type)
{
return traits_type::eof();
}
template <class _CharT, class _Traits>
streamsize
basic_streambuf<_CharT, _Traits>::xsputn(const char_type* __s, streamsize __n)
{
streamsize __i = 0;
int_type __eof = traits_type::eof();
while( __i < __n)
{
if (__nout_ >= __eout_)
{
if (overflow(traits_type::to_int_type(*__s)) == __eof)
break;
++__s;
++__i;
}
else
{
streamsize __chunk_size = std::__1::min(__eout_ - __nout_, __n - __i);
traits_type::copy(__nout_, __s, __chunk_size);
__nout_ += __chunk_size;
__s += __chunk_size;
__i += __chunk_size;
}
}
return __i;
}
template <class _CharT, class _Traits>
typename basic_streambuf<_CharT, _Traits>::int_type
basic_streambuf<_CharT, _Traits>::overflow(int_type)
{
return traits_type::eof();
}
extern template class __attribute__ ((__visibility__("default"))) basic_streambuf<char>;
extern template class __attribute__ ((__visibility__("default"))) basic_streambuf<wchar_t>;
extern template class __attribute__ ((__visibility__("default"))) basic_ios<char>;
extern template class __attribute__ ((__visibility__("default"))) basic_ios<wchar_t>;
} }
# 140 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 1 3
# 197 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 3
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/nl_types.h" 1 3 4
# 45 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/nl_types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 1 3 4
# 84 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_char.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_char.h" 3 4
typedef unsigned char u_char;
# 85 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_short.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_short.h" 3 4
typedef unsigned short u_short;
# 86 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_u_int.h" 3 4
typedef unsigned int u_int;
# 87 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
typedef unsigned long u_long;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef u_int64_t u_quad_t;
typedef int64_t quad_t;
typedef quad_t * qaddr_t;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_caddr_t.h" 1 3 4
# 30 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_caddr_t.h" 3 4
typedef char * caddr_t;
# 100 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
typedef int32_t daddr_t;
typedef u_int32_t fixpt_t;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_blkcnt_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_blkcnt_t.h" 3 4
typedef __darwin_blkcnt_t blkcnt_t;
# 108 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_blksize_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_blksize_t.h" 3 4
typedef __darwin_blksize_t blksize_t;
# 109 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_gid_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_gid_t.h" 3 4
typedef __darwin_gid_t gid_t;
# 110 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_in_addr_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_in_addr_t.h" 3 4
typedef __uint32_t in_addr_t;
# 111 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_in_port_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_in_port_t.h" 3 4
typedef __uint16_t in_port_t;
# 112 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ino_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ino_t.h" 3 4
typedef __darwin_ino_t ino_t;
# 113 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ino64_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_ino64_t.h" 3 4
typedef __darwin_ino64_t ino64_t;
# 116 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_key_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_key_t.h" 3 4
typedef __int32_t key_t;
# 119 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_nlink_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_nlink_t.h" 3 4
typedef __uint16_t nlink_t;
# 121 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
typedef int32_t segsz_t;
typedef int32_t swblk_t;
# 138 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 3 4
static inline __int32_t major(__uint32_t _x)
{
return (__int32_t)(((__uint32_t)_x >> 24) & 0xff);
}
static inline __int32_t minor(__uint32_t _x)
{
return (__int32_t)((_x) & 0xffffff);
}
static inline dev_t makedev(__uint32_t _major, __uint32_t _minor)
{
return (dev_t)(((_major) << 24) | (_minor));
}
# 167 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_useconds_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_useconds_t.h" 3 4
typedef __darwin_useconds_t useconds_t;
# 168 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_suseconds_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_suseconds_t.h" 3 4
typedef __darwin_suseconds_t suseconds_t;
# 169 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 181 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_def.h" 1 3 4
# 48 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_def.h" 3 4
extern "C" {
typedef struct fd_set {
__int32_t fds_bits[((((1024) % ((sizeof(__int32_t) * 8))) == 0) ? ((1024) / ((sizeof(__int32_t) * 8))) : (((1024) / ((sizeof(__int32_t) * 8))) + 1))];
} fd_set;
}
static inline int
__darwin_fd_isset(int _n, const struct fd_set *_p)
{
return (_p->fds_bits[(unsigned long)_n/(sizeof(__int32_t) * 8)] & ((__int32_t)(((unsigned long)1)<<((unsigned long)_n % (sizeof(__int32_t) * 8)))));
}
# 182 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
typedef __int32_t fd_mask;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_setsize.h" 1 3 4
# 195 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_set.h" 1 3 4
# 196 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_clr.h" 1 3 4
# 197 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_zero.h" 1 3 4
# 198 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_isset.h" 1 3 4
# 199 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fd_copy.h" 1 3 4
# 202 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 229 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fsblkcnt_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fsblkcnt_t.h" 3 4
typedef __darwin_fsblkcnt_t fsblkcnt_t;
# 230 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fsfilcnt_t.h" 1 3 4
# 31 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/_types/_fsfilcnt_t.h" 3 4
typedef __darwin_fsfilcnt_t fsfilcnt_t;
# 231 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/types.h" 2 3 4
# 46 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/nl_types.h" 2 3 4
# 89 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/nl_types.h" 3 4
typedef struct __nl_cat_d {
void *__data;
int __size;
} *nl_catd;
# 1 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_nl_item.h" 1 3 4
# 32 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/_types/_nl_item.h" 3 4
typedef __darwin_nl_item nl_item;
# 95 "/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/nl_types.h" 2 3 4
extern "C" {
nl_catd catopen(const char *, int);
char *catgets(nl_catd, int, int, const char *)
__attribute__((__format_arg__(4)));
int catclose(nl_catd);
}
# 198 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__bsd_locale_defaults.h" 1 3
# 20 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__bsd_locale_defaults.h" 3
# 206 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 2 3
# 212 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 216 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 2 3
namespace std {inline namespace __1 {
# 249 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 3
template <class _InputIterator, class _ForwardIterator, class _Ctype>
__attribute__ ((__visibility__("hidden")))
_ForwardIterator
__scan_keyword(_InputIterator& __b, _InputIterator __e,
_ForwardIterator __kb, _ForwardIterator __ke,
const _Ctype& __ct, ios_base::iostate& __err,
bool __case_sensitive = true)
{
typedef typename iterator_traits<_InputIterator>::value_type _CharT;
size_t __nkw = static_cast<size_t>(std::__1::distance(__kb, __ke));
const unsigned char __doesnt_match = '\0';
const unsigned char __might_match = '\1';
const unsigned char __does_match = '\2';
unsigned char __statbuf[100];
unsigned char* __status = __statbuf;
unique_ptr<unsigned char, void(*)(void*)> __stat_hold(0, free);
if (__nkw > sizeof(__statbuf))
{
__status = (unsigned char*)malloc(__nkw);
if (__status == 0)
__throw_bad_alloc();
__stat_hold.reset(__status);
}
size_t __n_might_match = __nkw;
size_t __n_does_match = 0;
unsigned char* __st = __status;
for (_ForwardIterator __ky = __kb; __ky != __ke; ++__ky, (void) ++__st)
{
if (!__ky->empty())
*__st = __might_match;
else
{
*__st = __does_match;
--__n_might_match;
++__n_does_match;
}
}
for (size_t __indx = 0; __b != __e && __n_might_match > 0; ++__indx)
{
_CharT __c = *__b;
if (!__case_sensitive)
__c = __ct.toupper(__c);
bool __consume = false;
__st = __status;
for (_ForwardIterator __ky = __kb; __ky != __ke; ++__ky, (void) ++__st)
{
if (*__st == __might_match)
{
_CharT __kc = (*__ky)[__indx];
if (!__case_sensitive)
__kc = __ct.toupper(__kc);
if (__c == __kc)
{
__consume = true;
if (__ky->size() == __indx+1)
{
*__st = __does_match;
--__n_might_match;
++__n_does_match;
}
}
else
{
*__st = __doesnt_match;
--__n_might_match;
}
}
}
if (__consume)
{
++__b;
if (__n_might_match + __n_does_match > 1)
{
__st = __status;
for (_ForwardIterator __ky = __kb; __ky != __ke; ++__ky, (void) ++__st)
{
if (*__st == __does_match && __ky->size() != __indx+1)
{
*__st = __doesnt_match;
--__n_does_match;
}
}
}
}
}
if (__b == __e)
__err |= ios_base::eofbit;
for (__st = __status; __kb != __ke; ++__kb, (void) ++__st)
if (*__st == __does_match)
break;
if (__kb == __ke)
__err |= ios_base::failbit;
return __kb;
}
struct __attribute__ ((__visibility__("default"))) __num_get_base
{
static const int __num_get_buf_sz = 40;
static int __get_base(ios_base&);
static const char __src[33];
};
__attribute__ ((__visibility__("default")))
void __check_grouping(const string& __grouping, unsigned* __g, unsigned* __g_end,
ios_base::iostate& __err);
template <class _CharT>
struct __num_get
: protected __num_get_base
{
static string __stage2_float_prep(ios_base& __iob, _CharT* __atoms, _CharT& __decimal_point,
_CharT& __thousands_sep);
static int __stage2_float_loop(_CharT __ct, bool& __in_units, char& __exp,
char* __a, char*& __a_end,
_CharT __decimal_point, _CharT __thousands_sep,
const string& __grouping, unsigned* __g,
unsigned*& __g_end, unsigned& __dc, _CharT* __atoms);
static string __stage2_int_prep(ios_base& __iob, _CharT* __atoms, _CharT& __thousands_sep);
static int __stage2_int_loop(_CharT __ct, int __base, char* __a, char*& __a_end,
unsigned& __dc, _CharT __thousands_sep, const string& __grouping,
unsigned* __g, unsigned*& __g_end, _CharT* __atoms);
# 423 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 3
};
template <class _CharT>
string
__num_get<_CharT>::__stage2_int_prep(ios_base& __iob, _CharT* __atoms, _CharT& __thousands_sep)
{
locale __loc = __iob.getloc();
use_facet<ctype<_CharT> >(__loc).widen(__src, __src + 26, __atoms);
const numpunct<_CharT>& __np = use_facet<numpunct<_CharT> >(__loc);
__thousands_sep = __np.thousands_sep();
return __np.grouping();
}
template <class _CharT>
string
__num_get<_CharT>::__stage2_float_prep(ios_base& __iob, _CharT* __atoms, _CharT& __decimal_point,
_CharT& __thousands_sep)
{
locale __loc = __iob.getloc();
use_facet<ctype<_CharT> >(__loc).widen(__src, __src + 32, __atoms);
const numpunct<_CharT>& __np = use_facet<numpunct<_CharT> >(__loc);
__decimal_point = __np.decimal_point();
__thousands_sep = __np.thousands_sep();
return __np.grouping();
}
template <class _CharT>
int
__num_get<_CharT>::__stage2_int_loop(_CharT __ct, int __base, char* __a, char*& __a_end,
unsigned& __dc, _CharT __thousands_sep, const string& __grouping,
unsigned* __g, unsigned*& __g_end, _CharT* __atoms)
{
if (__a_end == __a && (__ct == __atoms[24] || __ct == __atoms[25]))
{
*__a_end++ = __ct == __atoms[24] ? '+' : '-';
__dc = 0;
return 0;
}
if (__grouping.size() != 0 && __ct == __thousands_sep)
{
if (__g_end-__g < __num_get_buf_sz)
{
*__g_end++ = __dc;
__dc = 0;
}
return 0;
}
ptrdiff_t __f = find(__atoms, __atoms + 26, __ct) - __atoms;
if (__f >= 24)
return -1;
switch (__base)
{
case 8:
case 10:
if (__f >= __base)
return -1;
break;
case 16:
if (__f < 22)
break;
if (__a_end != __a && __a_end - __a <= 2 && __a_end[-1] == '0')
{
__dc = 0;
*__a_end++ = __src[__f];
return 0;
}
return -1;
}
*__a_end++ = __src[__f];
++__dc;
return 0;
}
template <class _CharT>
int
__num_get<_CharT>::__stage2_float_loop(_CharT __ct, bool& __in_units, char& __exp, char* __a, char*& __a_end,
_CharT __decimal_point, _CharT __thousands_sep, const string& __grouping,
unsigned* __g, unsigned*& __g_end, unsigned& __dc, _CharT* __atoms)
{
if (__ct == __decimal_point)
{
if (!__in_units)
return -1;
__in_units = false;
*__a_end++ = '.';
if (__grouping.size() != 0 && __g_end-__g < __num_get_buf_sz)
*__g_end++ = __dc;
return 0;
}
if (__ct == __thousands_sep && __grouping.size() != 0)
{
if (!__in_units)
return -1;
if (__g_end-__g < __num_get_buf_sz)
{
*__g_end++ = __dc;
__dc = 0;
}
return 0;
}
ptrdiff_t __f = find(__atoms, __atoms + 32, __ct) - __atoms;
if (__f >= 32)
return -1;
char __x = __src[__f];
if (__x == '-' || __x == '+')
{
if (__a_end == __a || (__a_end[-1] & 0x5F) == (__exp & 0x7F))
{
*__a_end++ = __x;
return 0;
}
return -1;
}
if (__x == 'x' || __x == 'X')
__exp = 'P';
else if ((__x & 0x5F) == __exp)
{
__exp |= 0x80;
if (__in_units)
{
__in_units = false;
if (__grouping.size() != 0 && __g_end-__g < __num_get_buf_sz)
*__g_end++ = __dc;
}
}
*__a_end++ = __x;
if (__f >= 22)
return 0;
++__dc;
return 0;
}
extern template struct __attribute__ ((__visibility__("default"))) __num_get<char>;
extern template struct __attribute__ ((__visibility__("default"))) __num_get<wchar_t>;
template <class _CharT, class _InputIterator = istreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) num_get
: public locale::facet,
private __num_get<_CharT>
{
public:
typedef _CharT char_type;
typedef _InputIterator iter_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit num_get(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, bool& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, long& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, long long& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned short& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned int& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned long& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned long long& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, float& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, double& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, long double& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, void*& __v) const
{
return do_get(__b, __e, __iob, __err, __v);
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~num_get() {}
template <class _Fp>
inline __attribute__ ((__visibility__("hidden")))
iter_type __do_get_floating_point
(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, _Fp& __v) const;
template <class _Signed>
inline __attribute__ ((__visibility__("hidden")))
iter_type __do_get_signed
(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, _Signed& __v) const;
template <class _Unsigned>
inline __attribute__ ((__visibility__("hidden")))
iter_type __do_get_unsigned
(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, _Unsigned& __v) const;
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, bool& __v) const;
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, long& __v) const
{ return this->__do_get_signed ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, long long& __v) const
{ return this->__do_get_signed ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned short& __v) const
{ return this->__do_get_unsigned ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned int& __v) const
{ return this->__do_get_unsigned ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned long& __v) const
{ return this->__do_get_unsigned ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, unsigned long long& __v) const
{ return this->__do_get_unsigned ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, float& __v) const
{ return this->__do_get_floating_point ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, double& __v) const
{ return this->__do_get_floating_point ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, long double& __v) const
{ return this->__do_get_floating_point ( __b, __e, __iob, __err, __v ); }
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, void*& __v) const;
};
template <class _CharT, class _InputIterator>
locale::id
num_get<_CharT, _InputIterator>::id;
template <class _Tp>
_Tp
__num_get_signed_integral(const char* __a, const char* __a_end,
ios_base::iostate& __err, int __base)
{
if (__a != __a_end)
{
typename remove_reference<__decltype((*__error()))>::type __save_errno = (*__error());
(*__error()) = 0;
char *__p2;
long long __ll = strtoll_l(__a, &__p2, __base, 0);
typename remove_reference<__decltype((*__error()))>::type __current_errno = (*__error());
if (__current_errno == 0)
(*__error()) = __save_errno;
if (__p2 != __a_end)
{
__err = ios_base::failbit;
return 0;
}
else if (__current_errno == 34 ||
__ll < numeric_limits<_Tp>::min() ||
numeric_limits<_Tp>::max() < __ll)
{
__err = ios_base::failbit;
if (__ll > 0)
return numeric_limits<_Tp>::max();
else
return numeric_limits<_Tp>::min();
}
return static_cast<_Tp>(__ll);
}
__err = ios_base::failbit;
return 0;
}
template <class _Tp>
_Tp
__num_get_unsigned_integral(const char* __a, const char* __a_end,
ios_base::iostate& __err, int __base)
{
if (__a != __a_end)
{
if (*__a == '-')
{
__err = ios_base::failbit;
return 0;
}
typename remove_reference<__decltype((*__error()))>::type __save_errno = (*__error());
(*__error()) = 0;
char *__p2;
unsigned long long __ll = strtoull_l(__a, &__p2, __base, 0);
typename remove_reference<__decltype((*__error()))>::type __current_errno = (*__error());
if (__current_errno == 0)
(*__error()) = __save_errno;
if (__p2 != __a_end)
{
__err = ios_base::failbit;
return 0;
}
else if (__current_errno == 34 ||
numeric_limits<_Tp>::max() < __ll)
{
__err = ios_base::failbit;
return numeric_limits<_Tp>::max();
}
return static_cast<_Tp>(__ll);
}
__err = ios_base::failbit;
return 0;
}
template <class _Tp>
__attribute__ ((__visibility__("hidden"), __always_inline__))
_Tp __do_strtod(const char* __a, char** __p2);
template <>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
float __do_strtod<float>(const char* __a, char** __p2) {
return strtof_l(__a, __p2, 0);
}
template <>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
double __do_strtod<double>(const char* __a, char** __p2) {
return strtod_l(__a, __p2, 0);
}
template <>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
long double __do_strtod<long double>(const char* __a, char** __p2) {
return strtold_l(__a, __p2, 0);
}
template <class _Tp>
__attribute__ ((__visibility__("hidden")))
_Tp
__num_get_float(const char* __a, const char* __a_end, ios_base::iostate& __err)
{
if (__a != __a_end)
{
typename remove_reference<__decltype((*__error()))>::type __save_errno = (*__error());
(*__error()) = 0;
char *__p2;
_Tp __ld = __do_strtod<_Tp>(__a, &__p2);
typename remove_reference<__decltype((*__error()))>::type __current_errno = (*__error());
if (__current_errno == 0)
(*__error()) = __save_errno;
if (__p2 != __a_end)
{
__err = ios_base::failbit;
return 0;
}
else if (__current_errno == 34)
__err = ios_base::failbit;
return __ld;
}
__err = ios_base::failbit;
return 0;
}
template <class _CharT, class _InputIterator>
_InputIterator
num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
bool& __v) const
{
if ((__iob.flags() & ios_base::boolalpha) == 0)
{
long __lv = -1;
__b = do_get(__b, __e, __iob, __err, __lv);
switch (__lv)
{
case 0:
__v = false;
break;
case 1:
__v = true;
break;
default:
__v = true;
__err = ios_base::failbit;
break;
}
return __b;
}
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__iob.getloc());
const numpunct<_CharT>& __np = use_facet<numpunct<_CharT> >(__iob.getloc());
typedef typename numpunct<_CharT>::string_type string_type;
const string_type __names[2] = {__np.truename(), __np.falsename()};
const string_type* __i = __scan_keyword(__b, __e, __names, __names+2,
__ct, __err);
__v = __i == __names;
return __b;
}
template <class _CharT, class _InputIterator>
template <class _Signed>
_InputIterator
num_get<_CharT, _InputIterator>::__do_get_signed(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
_Signed& __v) const
{
int __base = this->__get_base(__iob);
char_type __thousands_sep;
const int __atoms_size = 26;
char_type __atoms[__atoms_size];
string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep);
string __buf;
__buf.resize(__buf.capacity());
char* __a = &__buf[0];
char* __a_end = __a;
unsigned __g[__num_get_base::__num_get_buf_sz];
unsigned* __g_end = __g;
unsigned __dc = 0;
for (; __b != __e; ++__b)
{
if (__a_end == __a + __buf.size())
{
size_t __tmp = __buf.size();
__buf.resize(2*__buf.size());
__buf.resize(__buf.capacity());
__a = &__buf[0];
__a_end = __a + __tmp;
}
if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc,
__thousands_sep, __grouping, __g, __g_end,
__atoms))
break;
}
if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz)
*__g_end++ = __dc;
__v = __num_get_signed_integral<_Signed>(__a, __a_end, __err, __base);
__check_grouping(__grouping, __g, __g_end, __err);
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
template <class _CharT, class _InputIterator>
template <class _Unsigned>
_InputIterator
num_get<_CharT, _InputIterator>::__do_get_unsigned(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
_Unsigned& __v) const
{
int __base = this->__get_base(__iob);
char_type __thousands_sep;
const int __atoms_size = 26;
char_type __atoms[__atoms_size];
string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep);
string __buf;
__buf.resize(__buf.capacity());
char* __a = &__buf[0];
char* __a_end = __a;
unsigned __g[__num_get_base::__num_get_buf_sz];
unsigned* __g_end = __g;
unsigned __dc = 0;
for (; __b != __e; ++__b)
{
if (__a_end == __a + __buf.size())
{
size_t __tmp = __buf.size();
__buf.resize(2*__buf.size());
__buf.resize(__buf.capacity());
__a = &__buf[0];
__a_end = __a + __tmp;
}
if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc,
__thousands_sep, __grouping, __g, __g_end,
__atoms))
break;
}
if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz)
*__g_end++ = __dc;
__v = __num_get_unsigned_integral<_Unsigned>(__a, __a_end, __err, __base);
__check_grouping(__grouping, __g, __g_end, __err);
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
template <class _CharT, class _InputIterator>
template <class _Fp>
_InputIterator
num_get<_CharT, _InputIterator>::__do_get_floating_point(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
_Fp& __v) const
{
char_type __atoms[32];
char_type __decimal_point;
char_type __thousands_sep;
string __grouping = this->__stage2_float_prep(__iob, __atoms,
__decimal_point,
__thousands_sep);
string __buf;
__buf.resize(__buf.capacity());
char* __a = &__buf[0];
char* __a_end = __a;
unsigned __g[__num_get_base::__num_get_buf_sz];
unsigned* __g_end = __g;
unsigned __dc = 0;
bool __in_units = true;
char __exp = 'E';
for (; __b != __e; ++__b)
{
if (__a_end == __a + __buf.size())
{
size_t __tmp = __buf.size();
__buf.resize(2*__buf.size());
__buf.resize(__buf.capacity());
__a = &__buf[0];
__a_end = __a + __tmp;
}
if (this->__stage2_float_loop(*__b, __in_units, __exp, __a, __a_end,
__decimal_point, __thousands_sep,
__grouping, __g, __g_end,
__dc, __atoms))
break;
}
if (__grouping.size() != 0 && __in_units && __g_end-__g < __num_get_base::__num_get_buf_sz)
*__g_end++ = __dc;
__v = __num_get_float<_Fp>(__a, __a_end, __err);
__check_grouping(__grouping, __g, __g_end, __err);
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
template <class _CharT, class _InputIterator>
_InputIterator
num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
void*& __v) const
{
int __base = 16;
char_type __atoms[26];
char_type __thousands_sep = 0;
string __grouping;
use_facet<ctype<_CharT> >(__iob.getloc()).widen(__num_get_base::__src,
__num_get_base::__src + 26, __atoms);
string __buf;
__buf.resize(__buf.capacity());
char* __a = &__buf[0];
char* __a_end = __a;
unsigned __g[__num_get_base::__num_get_buf_sz];
unsigned* __g_end = __g;
unsigned __dc = 0;
for (; __b != __e; ++__b)
{
if (__a_end == __a + __buf.size())
{
size_t __tmp = __buf.size();
__buf.resize(2*__buf.size());
__buf.resize(__buf.capacity());
__a = &__buf[0];
__a_end = __a + __tmp;
}
if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc,
__thousands_sep, __grouping,
__g, __g_end, __atoms))
break;
}
__buf.resize(__a_end - __a);
if (sscanf_l(__buf.c_str(), 0, "%p", &__v) != 1)
__err = ios_base::failbit;
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
extern template class __attribute__ ((__visibility__("default"))) num_get<char>;
extern template class __attribute__ ((__visibility__("default"))) num_get<wchar_t>;
struct __attribute__ ((__visibility__("default"))) __num_put_base
{
protected:
static void __format_int(char* __fmt, const char* __len, bool __signd,
ios_base::fmtflags __flags);
static bool __format_float(char* __fmt, const char* __len,
ios_base::fmtflags __flags);
static char* __identify_padding(char* __nb, char* __ne,
const ios_base& __iob);
};
template <class _CharT>
struct __num_put
: protected __num_put_base
{
static void __widen_and_group_int(char* __nb, char* __np, char* __ne,
_CharT* __ob, _CharT*& __op, _CharT*& __oe,
const locale& __loc);
static void __widen_and_group_float(char* __nb, char* __np, char* __ne,
_CharT* __ob, _CharT*& __op, _CharT*& __oe,
const locale& __loc);
};
template <class _CharT>
void
__num_put<_CharT>::__widen_and_group_int(char* __nb, char* __np, char* __ne,
_CharT* __ob, _CharT*& __op, _CharT*& __oe,
const locale& __loc)
{
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> > (__loc);
const numpunct<_CharT>& __npt = use_facet<numpunct<_CharT> >(__loc);
string __grouping = __npt.grouping();
if (__grouping.empty())
{
__ct.widen(__nb, __ne, __ob);
__oe = __ob + (__ne - __nb);
}
else
{
__oe = __ob;
char* __nf = __nb;
if (*__nf == '-' || *__nf == '+')
*__oe++ = __ct.widen(*__nf++);
if (__ne - __nf >= 2 && __nf[0] == '0' && (__nf[1] == 'x' ||
__nf[1] == 'X'))
{
*__oe++ = __ct.widen(*__nf++);
*__oe++ = __ct.widen(*__nf++);
}
reverse(__nf, __ne);
_CharT __thousands_sep = __npt.thousands_sep();
unsigned __dc = 0;
unsigned __dg = 0;
for (char* __p = __nf; __p < __ne; ++__p)
{
if (static_cast<unsigned>(__grouping[__dg]) > 0 &&
__dc == static_cast<unsigned>(__grouping[__dg]))
{
*__oe++ = __thousands_sep;
__dc = 0;
if (__dg < __grouping.size()-1)
++__dg;
}
*__oe++ = __ct.widen(*__p);
++__dc;
}
reverse(__ob + (__nf - __nb), __oe);
}
if (__np == __ne)
__op = __oe;
else
__op = __ob + (__np - __nb);
}
template <class _CharT>
void
__num_put<_CharT>::__widen_and_group_float(char* __nb, char* __np, char* __ne,
_CharT* __ob, _CharT*& __op, _CharT*& __oe,
const locale& __loc)
{
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> > (__loc);
const numpunct<_CharT>& __npt = use_facet<numpunct<_CharT> >(__loc);
string __grouping = __npt.grouping();
__oe = __ob;
char* __nf = __nb;
if (*__nf == '-' || *__nf == '+')
*__oe++ = __ct.widen(*__nf++);
char* __ns;
if (__ne - __nf >= 2 && __nf[0] == '0' && (__nf[1] == 'x' ||
__nf[1] == 'X'))
{
*__oe++ = __ct.widen(*__nf++);
*__oe++ = __ct.widen(*__nf++);
for (__ns = __nf; __ns < __ne; ++__ns)
if (!isxdigit_l(*__ns, 0))
break;
}
else
{
for (__ns = __nf; __ns < __ne; ++__ns)
if (!isdigit_l(*__ns, 0))
break;
}
if (__grouping.empty())
{
__ct.widen(__nf, __ns, __oe);
__oe += __ns - __nf;
}
else
{
reverse(__nf, __ns);
_CharT __thousands_sep = __npt.thousands_sep();
unsigned __dc = 0;
unsigned __dg = 0;
for (char* __p = __nf; __p < __ns; ++__p)
{
if (__grouping[__dg] > 0 && __dc == static_cast<unsigned>(__grouping[__dg]))
{
*__oe++ = __thousands_sep;
__dc = 0;
if (__dg < __grouping.size()-1)
++__dg;
}
*__oe++ = __ct.widen(*__p);
++__dc;
}
reverse(__ob + (__nf - __nb), __oe);
}
for (__nf = __ns; __nf < __ne; ++__nf)
{
if (*__nf == '.')
{
*__oe++ = __npt.decimal_point();
++__nf;
break;
}
else
*__oe++ = __ct.widen(*__nf);
}
__ct.widen(__nf, __ne, __oe);
__oe += __ne - __nf;
if (__np == __ne)
__op = __oe;
else
__op = __ob + (__np - __nb);
}
extern template struct __attribute__ ((__visibility__("default"))) __num_put<char>;
extern template struct __attribute__ ((__visibility__("default"))) __num_put<wchar_t>;
template <class _CharT, class _OutputIterator = ostreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) num_put
: public locale::facet,
private __num_put<_CharT>
{
public:
typedef _CharT char_type;
typedef _OutputIterator iter_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit num_put(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
bool __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
long __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
long long __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
unsigned long __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
unsigned long long __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
double __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
long double __v) const
{
return do_put(__s, __iob, __fl, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
const void* __v) const
{
return do_put(__s, __iob, __fl, __v);
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~num_put() {}
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
bool __v) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
long __v) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
long long __v) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
unsigned long) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
unsigned long long) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
double __v) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
long double __v) const;
virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl,
const void* __v) const;
};
template <class _CharT, class _OutputIterator>
locale::id
num_put<_CharT, _OutputIterator>::id;
template <class _CharT, class _OutputIterator>
__attribute__ ((__visibility__("hidden")))
_OutputIterator
__pad_and_output(_OutputIterator __s,
const _CharT* __ob, const _CharT* __op, const _CharT* __oe,
ios_base& __iob, _CharT __fl)
{
streamsize __sz = __oe - __ob;
streamsize __ns = __iob.width();
if (__ns > __sz)
__ns -= __sz;
else
__ns = 0;
for (;__ob < __op; ++__ob, ++__s)
*__s = *__ob;
for (; __ns; --__ns, ++__s)
*__s = __fl;
for (; __ob < __oe; ++__ob, ++__s)
*__s = *__ob;
__iob.width(0);
return __s;
}
template <class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden")))
ostreambuf_iterator<_CharT, _Traits>
__pad_and_output(ostreambuf_iterator<_CharT, _Traits> __s,
const _CharT* __ob, const _CharT* __op, const _CharT* __oe,
ios_base& __iob, _CharT __fl)
{
if (__s.__sbuf_ == std::__1::__get_nullptr_t())
return __s;
streamsize __sz = __oe - __ob;
streamsize __ns = __iob.width();
if (__ns > __sz)
__ns -= __sz;
else
__ns = 0;
streamsize __np = __op - __ob;
if (__np > 0)
{
if (__s.__sbuf_->sputn(__ob, __np) != __np)
{
__s.__sbuf_ = std::__1::__get_nullptr_t();
return __s;
}
}
if (__ns > 0)
{
basic_string<_CharT, _Traits> __sp(__ns, __fl);
if (__s.__sbuf_->sputn(__sp.data(), __ns) != __ns)
{
__s.__sbuf_ = std::__1::__get_nullptr_t();
return __s;
}
}
__np = __oe - __op;
if (__np > 0)
{
if (__s.__sbuf_->sputn(__op, __np) != __np)
{
__s.__sbuf_ = std::__1::__get_nullptr_t();
return __s;
}
}
__iob.width(0);
return __s;
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, bool __v) const
{
if ((__iob.flags() & ios_base::boolalpha) == 0)
return do_put(__s, __iob, __fl, (unsigned long)__v);
const numpunct<char_type>& __np = use_facet<numpunct<char_type> >(__iob.getloc());
typedef typename numpunct<char_type>::string_type string_type;
string_type __nm = __v ? __np.truename() : __np.falsename();
for (typename string_type::iterator __i = __nm.begin(); __i != __nm.end(); ++__i, ++__s)
*__s = *__i;
return __s;
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, long __v) const
{
char __fmt[6] = {'%', 0};
const char* __len = "l";
this->__format_int(__fmt+1, __len, true, __iob.flags());
const unsigned __nbuf = (numeric_limits<long>::digits / 3)
+ ((numeric_limits<long>::digits % 3) != 0)
+ ((__iob.flags() & ios_base::showbase) != 0)
+ 2;
char __nar[__nbuf];
int __nc = snprintf_l(__nar, sizeof(__nar), 0, __fmt, __v);
char* __ne = __nar + __nc;
char* __np = this->__identify_padding(__nar, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __op;
char_type* __oe;
this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc());
return __pad_and_output(__s, __o, __op, __oe, __iob, __fl);
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, long long __v) const
{
char __fmt[8] = {'%', 0};
const char* __len = "ll";
this->__format_int(__fmt+1, __len, true, __iob.flags());
const unsigned __nbuf = (numeric_limits<long long>::digits / 3)
+ ((numeric_limits<long long>::digits % 3) != 0)
+ ((__iob.flags() & ios_base::showbase) != 0)
+ 2;
char __nar[__nbuf];
int __nc = snprintf_l(__nar, sizeof(__nar), 0, __fmt, __v);
char* __ne = __nar + __nc;
char* __np = this->__identify_padding(__nar, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __op;
char_type* __oe;
this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc());
return __pad_and_output(__s, __o, __op, __oe, __iob, __fl);
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, unsigned long __v) const
{
char __fmt[6] = {'%', 0};
const char* __len = "l";
this->__format_int(__fmt+1, __len, false, __iob.flags());
const unsigned __nbuf = (numeric_limits<unsigned long>::digits / 3)
+ ((numeric_limits<unsigned long>::digits % 3) != 0)
+ ((__iob.flags() & ios_base::showbase) != 0)
+ 1;
char __nar[__nbuf];
int __nc = snprintf_l(__nar, sizeof(__nar), 0, __fmt, __v);
char* __ne = __nar + __nc;
char* __np = this->__identify_padding(__nar, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __op;
char_type* __oe;
this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc());
return __pad_and_output(__s, __o, __op, __oe, __iob, __fl);
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, unsigned long long __v) const
{
char __fmt[8] = {'%', 0};
const char* __len = "ll";
this->__format_int(__fmt+1, __len, false, __iob.flags());
const unsigned __nbuf = (numeric_limits<unsigned long long>::digits / 3)
+ ((numeric_limits<unsigned long long>::digits % 3) != 0)
+ ((__iob.flags() & ios_base::showbase) != 0)
+ 1;
char __nar[__nbuf];
int __nc = snprintf_l(__nar, sizeof(__nar), 0, __fmt, __v);
char* __ne = __nar + __nc;
char* __np = this->__identify_padding(__nar, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __op;
char_type* __oe;
this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc());
return __pad_and_output(__s, __o, __op, __oe, __iob, __fl);
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, double __v) const
{
char __fmt[8] = {'%', 0};
const char* __len = "";
bool __specify_precision = this->__format_float(__fmt+1, __len, __iob.flags());
const unsigned __nbuf = 30;
char __nar[__nbuf];
char* __nb = __nar;
int __nc;
if (__specify_precision)
__nc = snprintf_l(__nb, __nbuf, 0, __fmt, (int)__iob.precision(), __v);
else
__nc = snprintf_l(__nb, __nbuf, 0, __fmt, __v);
unique_ptr<char, void(*)(void*)> __nbh(0, free);
if (__nc > static_cast<int>(__nbuf-1))
{
if (__specify_precision)
__nc = asprintf_l(&__nb, 0, __fmt, (int)__iob.precision(), __v);
else
__nc = asprintf_l(&__nb, 0, __fmt, __v);
if (__nb == 0)
__throw_bad_alloc();
__nbh.reset(__nb);
}
char* __ne = __nb + __nc;
char* __np = this->__identify_padding(__nb, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __ob = __o;
unique_ptr<char_type, void(*)(void*)> __obh(0, free);
if (__nb != __nar)
{
__ob = (char_type*)malloc(2*static_cast<size_t>(__nc)*sizeof(char_type));
if (__ob == 0)
__throw_bad_alloc();
__obh.reset(__ob);
}
char_type* __op;
char_type* __oe;
this->__widen_and_group_float(__nb, __np, __ne, __ob, __op, __oe, __iob.getloc());
__s = __pad_and_output(__s, __ob, __op, __oe, __iob, __fl);
return __s;
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, long double __v) const
{
char __fmt[8] = {'%', 0};
const char* __len = "L";
bool __specify_precision = this->__format_float(__fmt+1, __len, __iob.flags());
const unsigned __nbuf = 30;
char __nar[__nbuf];
char* __nb = __nar;
int __nc;
if (__specify_precision)
__nc = snprintf_l(__nb, __nbuf, 0, __fmt, (int)__iob.precision(), __v);
else
__nc = snprintf_l(__nb, __nbuf, 0, __fmt, __v);
unique_ptr<char, void(*)(void*)> __nbh(0, free);
if (__nc > static_cast<int>(__nbuf-1))
{
if (__specify_precision)
__nc = asprintf_l(&__nb, 0, __fmt, (int)__iob.precision(), __v);
else
__nc = asprintf_l(&__nb, 0, __fmt, __v);
if (__nb == 0)
__throw_bad_alloc();
__nbh.reset(__nb);
}
char* __ne = __nb + __nc;
char* __np = this->__identify_padding(__nb, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __ob = __o;
unique_ptr<char_type, void(*)(void*)> __obh(0, free);
if (__nb != __nar)
{
__ob = (char_type*)malloc(2*static_cast<size_t>(__nc)*sizeof(char_type));
if (__ob == 0)
__throw_bad_alloc();
__obh.reset(__ob);
}
char_type* __op;
char_type* __oe;
this->__widen_and_group_float(__nb, __np, __ne, __ob, __op, __oe, __iob.getloc());
__s = __pad_and_output(__s, __ob, __op, __oe, __iob, __fl);
return __s;
}
template <class _CharT, class _OutputIterator>
_OutputIterator
num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob,
char_type __fl, const void* __v) const
{
char __fmt[6] = "%p";
const unsigned __nbuf = 20;
char __nar[__nbuf];
int __nc = snprintf_l(__nar, sizeof(__nar), 0, __fmt, __v);
char* __ne = __nar + __nc;
char* __np = this->__identify_padding(__nar, __ne, __iob);
char_type __o[2*(__nbuf-1) - 1];
char_type* __op;
char_type* __oe;
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
__ct.widen(__nar, __ne, __o);
__oe = __o + (__ne - __nar);
if (__np == __ne)
__op = __oe;
else
__op = __o + (__np - __nar);
return __pad_and_output(__s, __o, __op, __oe, __iob, __fl);
}
extern template class __attribute__ ((__visibility__("default"))) num_put<char>;
extern template class __attribute__ ((__visibility__("default"))) num_put<wchar_t>;
template <class _CharT, class _InputIterator>
__attribute__ ((__visibility__("hidden")))
int
__get_up_to_n_digits(_InputIterator& __b, _InputIterator __e,
ios_base::iostate& __err, const ctype<_CharT>& __ct, int __n)
{
if (__b == __e)
{
__err |= ios_base::eofbit | ios_base::failbit;
return 0;
}
_CharT __c = *__b;
if (!__ct.is(ctype_base::digit, __c))
{
__err |= ios_base::failbit;
return 0;
}
int __r = __ct.narrow(__c, 0) - '0';
for (++__b, (void) --__n; __b != __e && __n > 0; ++__b, (void) --__n)
{
__c = *__b;
if (!__ct.is(ctype_base::digit, __c))
return __r;
__r = __r * 10 + __ct.narrow(__c, 0) - '0';
}
if (__b == __e)
__err |= ios_base::eofbit;
return __r;
}
class __attribute__ ((__visibility__("default"))) time_base
{
public:
enum dateorder {no_order, dmy, mdy, ymd, ydm};
};
template <class _CharT>
class __attribute__ ((__type_visibility__("default"))) __time_get_c_storage
{
protected:
typedef basic_string<_CharT> string_type;
virtual const string_type* __weeks() const;
virtual const string_type* __months() const;
virtual const string_type* __am_pm() const;
virtual const string_type& __c() const;
virtual const string_type& __r() const;
virtual const string_type& __x() const;
virtual const string_type& __X() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
~__time_get_c_storage() {}
};
template <> __attribute__ ((__visibility__("default"))) const string* __time_get_c_storage<char>::__weeks() const;
template <> __attribute__ ((__visibility__("default"))) const string* __time_get_c_storage<char>::__months() const;
template <> __attribute__ ((__visibility__("default"))) const string* __time_get_c_storage<char>::__am_pm() const;
template <> __attribute__ ((__visibility__("default"))) const string& __time_get_c_storage<char>::__c() const;
template <> __attribute__ ((__visibility__("default"))) const string& __time_get_c_storage<char>::__r() const;
template <> __attribute__ ((__visibility__("default"))) const string& __time_get_c_storage<char>::__x() const;
template <> __attribute__ ((__visibility__("default"))) const string& __time_get_c_storage<char>::__X() const;
template <> __attribute__ ((__visibility__("default"))) const wstring* __time_get_c_storage<wchar_t>::__weeks() const;
template <> __attribute__ ((__visibility__("default"))) const wstring* __time_get_c_storage<wchar_t>::__months() const;
template <> __attribute__ ((__visibility__("default"))) const wstring* __time_get_c_storage<wchar_t>::__am_pm() const;
template <> __attribute__ ((__visibility__("default"))) const wstring& __time_get_c_storage<wchar_t>::__c() const;
template <> __attribute__ ((__visibility__("default"))) const wstring& __time_get_c_storage<wchar_t>::__r() const;
template <> __attribute__ ((__visibility__("default"))) const wstring& __time_get_c_storage<wchar_t>::__x() const;
template <> __attribute__ ((__visibility__("default"))) const wstring& __time_get_c_storage<wchar_t>::__X() const;
template <class _CharT, class _InputIterator = istreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) time_get
: public locale::facet,
public time_base,
private __time_get_c_storage<_CharT>
{
public:
typedef _CharT char_type;
typedef _InputIterator iter_type;
typedef time_base::dateorder dateorder;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_get(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
dateorder date_order() const
{
return this->do_date_order();
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get_time(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const
{
return do_get_time(__b, __e, __iob, __err, __tm);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get_date(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const
{
return do_get_date(__b, __e, __iob, __err, __tm);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get_weekday(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const
{
return do_get_weekday(__b, __e, __iob, __err, __tm);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get_monthname(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const
{
return do_get_monthname(__b, __e, __iob, __err, __tm);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get_year(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const
{
return do_get_year(__b, __e, __iob, __err, __tm);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm *__tm,
char __fmt, char __mod = 0) const
{
return do_get(__b, __e, __iob, __err, __tm, __fmt, __mod);
}
iter_type get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm,
const char_type* __fmtb, const char_type* __fmte) const;
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~time_get() {}
virtual dateorder do_date_order() const;
virtual iter_type do_get_time(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const;
virtual iter_type do_get_date(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const;
virtual iter_type do_get_weekday(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const;
virtual iter_type do_get_monthname(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const;
virtual iter_type do_get_year(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm) const;
virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob,
ios_base::iostate& __err, tm* __tm,
char __fmt, char __mod) const;
private:
void __get_white_space(iter_type& __b, iter_type __e,
ios_base::iostate& __err, const ctype<char_type>& __ct) const;
void __get_percent(iter_type& __b, iter_type __e, ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_weekdayname(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_monthname(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_day(int& __d,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_month(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_year(int& __y,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_year4(int& __y,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_hour(int& __d,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_12_hour(int& __h,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_am_pm(int& __h,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_minute(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_second(int& __s,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_weekday(int& __w,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
void __get_day_year_num(int& __w,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const;
};
template <class _CharT, class _InputIterator>
locale::id
time_get<_CharT, _InputIterator>::id;
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_weekdayname(int& __w,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
const string_type* __wk = this->__weeks();
ptrdiff_t __i = __scan_keyword(__b, __e, __wk, __wk+14, __ct, __err, false) - __wk;
if (__i < 14)
__w = __i % 7;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_monthname(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
const string_type* __month = this->__months();
ptrdiff_t __i = __scan_keyword(__b, __e, __month, __month+24, __ct, __err, false) - __month;
if (__i < 24)
__m = __i % 12;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_day(int& __d,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2);
if (!(__err & ios_base::failbit) && 1 <= __t && __t <= 31)
__d = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_month(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2) - 1;
if (!(__err & ios_base::failbit) && __t <= 11)
__m = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_year(int& __y,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 4);
if (!(__err & ios_base::failbit))
{
if (__t < 69)
__t += 2000;
else if (69 <= __t && __t <= 99)
__t += 1900;
__y = __t - 1900;
}
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_year4(int& __y,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 4);
if (!(__err & ios_base::failbit))
__y = __t - 1900;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_hour(int& __h,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2);
if (!(__err & ios_base::failbit) && __t <= 23)
__h = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_12_hour(int& __h,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2);
if (!(__err & ios_base::failbit) && 1 <= __t && __t <= 12)
__h = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_minute(int& __m,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2);
if (!(__err & ios_base::failbit) && __t <= 59)
__m = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_second(int& __s,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2);
if (!(__err & ios_base::failbit) && __t <= 60)
__s = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_weekday(int& __w,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 1);
if (!(__err & ios_base::failbit) && __t <= 6)
__w = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_day_year_num(int& __d,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 3);
if (!(__err & ios_base::failbit) && __t <= 365)
__d = __t;
else
__err |= ios_base::failbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_white_space(iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
for (; __b != __e && __ct.is(ctype_base::space, *__b); ++__b)
;
if (__b == __e)
__err |= ios_base::eofbit;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_am_pm(int& __h,
iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
const string_type* __ap = this->__am_pm();
if (__ap[0].size() + __ap[1].size() == 0)
{
__err |= ios_base::failbit;
return;
}
ptrdiff_t __i = __scan_keyword(__b, __e, __ap, __ap+2, __ct, __err, false) - __ap;
if (__i == 0 && __h == 12)
__h = 0;
else if (__i == 1 && __h < 12)
__h += 12;
}
template <class _CharT, class _InputIterator>
void
time_get<_CharT, _InputIterator>::__get_percent(iter_type& __b, iter_type __e,
ios_base::iostate& __err,
const ctype<char_type>& __ct) const
{
if (__b == __e)
{
__err |= ios_base::eofbit | ios_base::failbit;
return;
}
if (__ct.narrow(*__b, 0) != '%')
__err |= ios_base::failbit;
else if(++__b == __e)
__err |= ios_base::eofbit;
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::get(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err, tm* __tm,
const char_type* __fmtb, const char_type* __fmte) const
{
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
__err = ios_base::goodbit;
while (__fmtb != __fmte && __err == ios_base::goodbit)
{
if (__b == __e)
{
__err = ios_base::failbit;
break;
}
if (__ct.narrow(*__fmtb, 0) == '%')
{
if (++__fmtb == __fmte)
{
__err = ios_base::failbit;
break;
}
char __cmd = __ct.narrow(*__fmtb, 0);
char __opt = '\0';
if (__cmd == 'E' || __cmd == '0')
{
if (++__fmtb == __fmte)
{
__err = ios_base::failbit;
break;
}
__opt = __cmd;
__cmd = __ct.narrow(*__fmtb, 0);
}
__b = do_get(__b, __e, __iob, __err, __tm, __cmd, __opt);
++__fmtb;
}
else if (__ct.is(ctype_base::space, *__fmtb))
{
for (++__fmtb; __fmtb != __fmte && __ct.is(ctype_base::space, *__fmtb); ++__fmtb)
;
for ( ; __b != __e && __ct.is(ctype_base::space, *__b); ++__b)
;
}
else if (__ct.toupper(*__b) == __ct.toupper(*__fmtb))
{
++__b;
++__fmtb;
}
else
__err = ios_base::failbit;
}
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
template <class _CharT, class _InputIterator>
typename time_get<_CharT, _InputIterator>::dateorder
time_get<_CharT, _InputIterator>::do_date_order() const
{
return mdy;
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::do_get_time(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
tm* __tm) const
{
const char_type __fmt[] = {'%', 'H', ':', '%', 'M', ':', '%', 'S'};
return get(__b, __e, __iob, __err, __tm, __fmt, __fmt + sizeof(__fmt)/sizeof(__fmt[0]));
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::do_get_date(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
tm* __tm) const
{
const string_type& __fmt = this->__x();
return get(__b, __e, __iob, __err, __tm, __fmt.data(), __fmt.data() + __fmt.size());
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::do_get_weekday(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
tm* __tm) const
{
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
__get_weekdayname(__tm->tm_wday, __b, __e, __err, __ct);
return __b;
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::do_get_monthname(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
tm* __tm) const
{
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
__get_monthname(__tm->tm_mon, __b, __e, __err, __ct);
return __b;
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::do_get_year(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err,
tm* __tm) const
{
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
__get_year(__tm->tm_year, __b, __e, __err, __ct);
return __b;
}
template <class _CharT, class _InputIterator>
_InputIterator
time_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e,
ios_base& __iob,
ios_base::iostate& __err, tm* __tm,
char __fmt, char) const
{
__err = ios_base::goodbit;
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
switch (__fmt)
{
case 'a':
case 'A':
__get_weekdayname(__tm->tm_wday, __b, __e, __err, __ct);
break;
case 'b':
case 'B':
case 'h':
__get_monthname(__tm->tm_mon, __b, __e, __err, __ct);
break;
case 'c':
{
const string_type& __fm = this->__c();
__b = get(__b, __e, __iob, __err, __tm, __fm.data(), __fm.data() + __fm.size());
}
break;
case 'd':
case 'e':
__get_day(__tm->tm_mday, __b, __e, __err, __ct);
break;
case 'D':
{
const char_type __fm[] = {'%', 'm', '/', '%', 'd', '/', '%', 'y'};
__b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0]));
}
break;
case 'F':
{
const char_type __fm[] = {'%', 'Y', '-', '%', 'm', '-', '%', 'd'};
__b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0]));
}
break;
case 'H':
__get_hour(__tm->tm_hour, __b, __e, __err, __ct);
break;
case 'I':
__get_12_hour(__tm->tm_hour, __b, __e, __err, __ct);
break;
case 'j':
__get_day_year_num(__tm->tm_yday, __b, __e, __err, __ct);
break;
case 'm':
__get_month(__tm->tm_mon, __b, __e, __err, __ct);
break;
case 'M':
__get_minute(__tm->tm_min, __b, __e, __err, __ct);
break;
case 'n':
case 't':
__get_white_space(__b, __e, __err, __ct);
break;
case 'p':
__get_am_pm(__tm->tm_hour, __b, __e, __err, __ct);
break;
case 'r':
{
const char_type __fm[] = {'%', 'I', ':', '%', 'M', ':', '%', 'S', ' ', '%', 'p'};
__b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0]));
}
break;
case 'R':
{
const char_type __fm[] = {'%', 'H', ':', '%', 'M'};
__b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0]));
}
break;
case 'S':
__get_second(__tm->tm_sec, __b, __e, __err, __ct);
break;
case 'T':
{
const char_type __fm[] = {'%', 'H', ':', '%', 'M', ':', '%', 'S'};
__b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0]));
}
break;
case 'w':
__get_weekday(__tm->tm_wday, __b, __e, __err, __ct);
break;
case 'x':
return do_get_date(__b, __e, __iob, __err, __tm);
case 'X':
{
const string_type& __fm = this->__X();
__b = get(__b, __e, __iob, __err, __tm, __fm.data(), __fm.data() + __fm.size());
}
break;
case 'y':
__get_year(__tm->tm_year, __b, __e, __err, __ct);
break;
case 'Y':
__get_year4(__tm->tm_year, __b, __e, __err, __ct);
break;
case '%':
__get_percent(__b, __e, __err, __ct);
break;
default:
__err |= ios_base::failbit;
}
return __b;
}
extern template class __attribute__ ((__visibility__("default"))) time_get<char>;
extern template class __attribute__ ((__visibility__("default"))) time_get<wchar_t>;
class __attribute__ ((__visibility__("default"))) __time_get
{
protected:
locale_t __loc_;
__time_get(const char* __nm);
__time_get(const string& __nm);
~__time_get();
};
template <class _CharT>
class __attribute__ ((__type_visibility__("default"))) __time_get_storage
: public __time_get
{
protected:
typedef basic_string<_CharT> string_type;
string_type __weeks_[14];
string_type __months_[24];
string_type __am_pm_[2];
string_type __c_;
string_type __r_;
string_type __x_;
string_type __X_;
explicit __time_get_storage(const char* __nm);
explicit __time_get_storage(const string& __nm);
__attribute__ ((__visibility__("hidden"), __always_inline__)) ~__time_get_storage() {}
time_base::dateorder __do_date_order() const;
private:
void init(const ctype<_CharT>&);
string_type __analyze(char __fmt, const ctype<_CharT>&);
};
template <class _CharT, class _InputIterator = istreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) time_get_byname
: public time_get<_CharT, _InputIterator>,
private __time_get_storage<_CharT>
{
public:
typedef time_base::dateorder dateorder;
typedef _InputIterator iter_type;
typedef _CharT char_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_get_byname(const char* __nm, size_t __refs = 0)
: time_get<_CharT, _InputIterator>(__refs),
__time_get_storage<_CharT>(__nm) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_get_byname(const string& __nm, size_t __refs = 0)
: time_get<_CharT, _InputIterator>(__refs),
__time_get_storage<_CharT>(__nm) {}
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~time_get_byname() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual dateorder do_date_order() const {return this->__do_date_order();}
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type* __weeks() const {return this->__weeks_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type* __months() const {return this->__months_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type* __am_pm() const {return this->__am_pm_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type& __c() const {return this->__c_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type& __r() const {return this->__r_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type& __x() const {return this->__x_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
virtual const string_type& __X() const {return this->__X_;}
};
extern template class __attribute__ ((__visibility__("default"))) time_get_byname<char>;
extern template class __attribute__ ((__visibility__("default"))) time_get_byname<wchar_t>;
class __attribute__ ((__visibility__("default"))) __time_put
{
locale_t __loc_;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __time_put() : __loc_(0) {}
__time_put(const char* __nm);
__time_put(const string& __nm);
~__time_put();
void __do_put(char* __nb, char*& __ne, const tm* __tm,
char __fmt, char __mod) const;
void __do_put(wchar_t* __wb, wchar_t*& __we, const tm* __tm,
char __fmt, char __mod) const;
};
template <class _CharT, class _OutputIterator = ostreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) time_put
: public locale::facet,
private __time_put
{
public:
typedef _CharT char_type;
typedef _OutputIterator iter_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_put(size_t __refs = 0)
: locale::facet(__refs) {}
iter_type put(iter_type __s, ios_base& __iob, char_type __fl, const tm* __tm,
const char_type* __pb, const char_type* __pe) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, ios_base& __iob, char_type __fl,
const tm* __tm, char __fmt, char __mod = 0) const
{
return do_put(__s, __iob, __fl, __tm, __fmt, __mod);
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~time_put() {}
virtual iter_type do_put(iter_type __s, ios_base&, char_type, const tm* __tm,
char __fmt, char __mod) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_put(const char* __nm, size_t __refs)
: locale::facet(__refs),
__time_put(__nm) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_put(const string& __nm, size_t __refs)
: locale::facet(__refs),
__time_put(__nm) {}
};
template <class _CharT, class _OutputIterator>
locale::id
time_put<_CharT, _OutputIterator>::id;
template <class _CharT, class _OutputIterator>
_OutputIterator
time_put<_CharT, _OutputIterator>::put(iter_type __s, ios_base& __iob,
char_type __fl, const tm* __tm,
const char_type* __pb,
const char_type* __pe) const
{
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__iob.getloc());
for (; __pb != __pe; ++__pb)
{
if (__ct.narrow(*__pb, 0) == '%')
{
if (++__pb == __pe)
{
*__s++ = __pb[-1];
break;
}
char __mod = 0;
char __fmt = __ct.narrow(*__pb, 0);
if (__fmt == 'E' || __fmt == 'O')
{
if (++__pb == __pe)
{
*__s++ = __pb[-2];
*__s++ = __pb[-1];
break;
}
__mod = __fmt;
__fmt = __ct.narrow(*__pb, 0);
}
__s = do_put(__s, __iob, __fl, __tm, __fmt, __mod);
}
else
*__s++ = *__pb;
}
return __s;
}
template <class _CharT, class _OutputIterator>
_OutputIterator
time_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base&,
char_type, const tm* __tm,
char __fmt, char __mod) const
{
char_type __nar[100];
char_type* __nb = __nar;
char_type* __ne = __nb + 100;
__do_put(__nb, __ne, __tm, __fmt, __mod);
return std::__1::copy(__nb, __ne, __s);
}
extern template class __attribute__ ((__visibility__("default"))) time_put<char>;
extern template class __attribute__ ((__visibility__("default"))) time_put<wchar_t>;
template <class _CharT, class _OutputIterator = ostreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) time_put_byname
: public time_put<_CharT, _OutputIterator>
{
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_put_byname(const char* __nm, size_t __refs = 0)
: time_put<_CharT, _OutputIterator>(__nm, __refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit time_put_byname(const string& __nm, size_t __refs = 0)
: time_put<_CharT, _OutputIterator>(__nm, __refs) {}
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~time_put_byname() {}
};
extern template class __attribute__ ((__visibility__("default"))) time_put_byname<char>;
extern template class __attribute__ ((__visibility__("default"))) time_put_byname<wchar_t>;
class __attribute__ ((__visibility__("default"))) money_base
{
public:
enum part {none, space, symbol, sign, value};
struct pattern {char field[4];};
__attribute__ ((__visibility__("hidden"), __always_inline__)) money_base() {}
};
template <class _CharT, bool _International = false>
class __attribute__ ((__type_visibility__("default"))) moneypunct
: public locale::facet,
public money_base
{
public:
typedef _CharT char_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit moneypunct(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type decimal_point() const {return do_decimal_point();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) char_type thousands_sep() const {return do_thousands_sep();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string grouping() const {return do_grouping();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type curr_symbol() const {return do_curr_symbol();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type positive_sign() const {return do_positive_sign();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) string_type negative_sign() const {return do_negative_sign();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) int frac_digits() const {return do_frac_digits();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) pattern pos_format() const {return do_pos_format();}
__attribute__ ((__visibility__("hidden"), __always_inline__)) pattern neg_format() const {return do_neg_format();}
static locale::id id;
static const bool intl = _International;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~moneypunct() {}
virtual char_type do_decimal_point() const {return numeric_limits<char_type>::max();}
virtual char_type do_thousands_sep() const {return numeric_limits<char_type>::max();}
virtual string do_grouping() const {return string();}
virtual string_type do_curr_symbol() const {return string_type();}
virtual string_type do_positive_sign() const {return string_type();}
virtual string_type do_negative_sign() const {return string_type(1, '-');}
virtual int do_frac_digits() const {return 0;}
virtual pattern do_pos_format() const
{pattern __p = {{symbol, sign, none, value}}; return __p;}
virtual pattern do_neg_format() const
{pattern __p = {{symbol, sign, none, value}}; return __p;}
};
template <class _CharT, bool _International>
locale::id
moneypunct<_CharT, _International>::id;
template <class _CharT, bool _International>
const bool
moneypunct<_CharT, _International>::intl;
extern template class __attribute__ ((__visibility__("default"))) moneypunct<char, false>;
extern template class __attribute__ ((__visibility__("default"))) moneypunct<char, true>;
extern template class __attribute__ ((__visibility__("default"))) moneypunct<wchar_t, false>;
extern template class __attribute__ ((__visibility__("default"))) moneypunct<wchar_t, true>;
template <class _CharT, bool _International = false>
class __attribute__ ((__type_visibility__("default"))) moneypunct_byname
: public moneypunct<_CharT, _International>
{
public:
typedef money_base::pattern pattern;
typedef _CharT char_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit moneypunct_byname(const char* __nm, size_t __refs = 0)
: moneypunct<_CharT, _International>(__refs) {init(__nm);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit moneypunct_byname(const string& __nm, size_t __refs = 0)
: moneypunct<_CharT, _International>(__refs) {init(__nm.c_str());}
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~moneypunct_byname() {}
virtual char_type do_decimal_point() const {return __decimal_point_;}
virtual char_type do_thousands_sep() const {return __thousands_sep_;}
virtual string do_grouping() const {return __grouping_;}
virtual string_type do_curr_symbol() const {return __curr_symbol_;}
virtual string_type do_positive_sign() const {return __positive_sign_;}
virtual string_type do_negative_sign() const {return __negative_sign_;}
virtual int do_frac_digits() const {return __frac_digits_;}
virtual pattern do_pos_format() const {return __pos_format_;}
virtual pattern do_neg_format() const {return __neg_format_;}
private:
char_type __decimal_point_;
char_type __thousands_sep_;
string __grouping_;
string_type __curr_symbol_;
string_type __positive_sign_;
string_type __negative_sign_;
int __frac_digits_;
pattern __pos_format_;
pattern __neg_format_;
void init(const char*);
};
template<> __attribute__ ((__visibility__("default"))) void moneypunct_byname<char, false>::init(const char*);
template<> __attribute__ ((__visibility__("default"))) void moneypunct_byname<char, true>::init(const char*);
template<> __attribute__ ((__visibility__("default"))) void moneypunct_byname<wchar_t, false>::init(const char*);
template<> __attribute__ ((__visibility__("default"))) void moneypunct_byname<wchar_t, true>::init(const char*);
extern template class __attribute__ ((__visibility__("default"))) moneypunct_byname<char, false>;
extern template class __attribute__ ((__visibility__("default"))) moneypunct_byname<char, true>;
extern template class __attribute__ ((__visibility__("default"))) moneypunct_byname<wchar_t, false>;
extern template class __attribute__ ((__visibility__("default"))) moneypunct_byname<wchar_t, true>;
template <class _CharT>
class __money_get
{
protected:
typedef _CharT char_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) __money_get() {}
static void __gather_info(bool __intl, const locale& __loc,
money_base::pattern& __pat, char_type& __dp,
char_type& __ts, string& __grp,
string_type& __sym, string_type& __psn,
string_type& __nsn, int& __fd);
};
template <class _CharT>
void
__money_get<_CharT>::__gather_info(bool __intl, const locale& __loc,
money_base::pattern& __pat, char_type& __dp,
char_type& __ts, string& __grp,
string_type& __sym, string_type& __psn,
string_type& __nsn, int& __fd)
{
if (__intl)
{
const moneypunct<char_type, true>& __mp =
use_facet<moneypunct<char_type, true> >(__loc);
__pat = __mp.neg_format();
__nsn = __mp.negative_sign();
__psn = __mp.positive_sign();
__dp = __mp.decimal_point();
__ts = __mp.thousands_sep();
__grp = __mp.grouping();
__sym = __mp.curr_symbol();
__fd = __mp.frac_digits();
}
else
{
const moneypunct<char_type, false>& __mp =
use_facet<moneypunct<char_type, false> >(__loc);
__pat = __mp.neg_format();
__nsn = __mp.negative_sign();
__psn = __mp.positive_sign();
__dp = __mp.decimal_point();
__ts = __mp.thousands_sep();
__grp = __mp.grouping();
__sym = __mp.curr_symbol();
__fd = __mp.frac_digits();
}
}
extern template class __attribute__ ((__visibility__("default"))) __money_get<char>;
extern template class __attribute__ ((__visibility__("default"))) __money_get<wchar_t>;
template <class _CharT, class _InputIterator = istreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) money_get
: public locale::facet,
private __money_get<_CharT>
{
public:
typedef _CharT char_type;
typedef _InputIterator iter_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit money_get(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, bool __intl, ios_base& __iob,
ios_base::iostate& __err, long double& __v) const
{
return do_get(__b, __e, __intl, __iob, __err, __v);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type get(iter_type __b, iter_type __e, bool __intl, ios_base& __iob,
ios_base::iostate& __err, string_type& __v) const
{
return do_get(__b, __e, __intl, __iob, __err, __v);
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~money_get() {}
virtual iter_type do_get(iter_type __b, iter_type __e, bool __intl,
ios_base& __iob, ios_base::iostate& __err,
long double& __v) const;
virtual iter_type do_get(iter_type __b, iter_type __e, bool __intl,
ios_base& __iob, ios_base::iostate& __err,
string_type& __v) const;
private:
static bool __do_get(iter_type& __b, iter_type __e,
bool __intl, const locale& __loc,
ios_base::fmtflags __flags, ios_base::iostate& __err,
bool& __neg, const ctype<char_type>& __ct,
unique_ptr<char_type, void(*)(void*)>& __wb,
char_type*& __wn, char_type* __we);
};
template <class _CharT, class _InputIterator>
locale::id
money_get<_CharT, _InputIterator>::id;
__attribute__ ((__visibility__("default"))) void __do_nothing(void*);
template <class _Tp>
__attribute__ ((__visibility__("hidden")))
void
__double_or_nothing(unique_ptr<_Tp, void(*)(void*)>& __b, _Tp*& __n, _Tp*& __e)
{
bool __owns = __b.get_deleter() != __do_nothing;
size_t __cur_cap = static_cast<size_t>(__e-__b.get()) * sizeof(_Tp);
size_t __new_cap = __cur_cap < numeric_limits<size_t>::max() / 2 ?
2 * __cur_cap : numeric_limits<size_t>::max();
if (__new_cap == 0)
__new_cap = sizeof(_Tp);
size_t __n_off = static_cast<size_t>(__n - __b.get());
_Tp* __t = (_Tp*)realloc(__owns ? __b.get() : 0, __new_cap);
if (__t == 0)
__throw_bad_alloc();
if (__owns)
__b.release();
__b = unique_ptr<_Tp, void(*)(void*)>(__t, free);
__new_cap /= sizeof(_Tp);
__n = __b.get() + __n_off;
__e = __b.get() + __new_cap;
}
template <class _CharT, class _InputIterator>
bool
money_get<_CharT, _InputIterator>::__do_get(iter_type& __b, iter_type __e,
bool __intl, const locale& __loc,
ios_base::fmtflags __flags,
ios_base::iostate& __err,
bool& __neg,
const ctype<char_type>& __ct,
unique_ptr<char_type, void(*)(void*)>& __wb,
char_type*& __wn, char_type* __we)
{
const unsigned __bz = 100;
unsigned __gbuf[__bz];
unique_ptr<unsigned, void(*)(void*)> __gb(__gbuf, __do_nothing);
unsigned* __gn = __gb.get();
unsigned* __ge = __gn + __bz;
money_base::pattern __pat;
char_type __dp;
char_type __ts;
string __grp;
string_type __sym;
string_type __psn;
string_type __nsn;
string_type __spaces;
int __fd;
__money_get<_CharT>::__gather_info(__intl, __loc, __pat, __dp, __ts, __grp,
__sym, __psn, __nsn, __fd);
const string_type* __trailing_sign = 0;
__wn = __wb.get();
for (unsigned __p = 0; __p < 4 && __b != __e; ++__p)
{
switch (__pat.field[__p])
{
case money_base::space:
if (__p != 3)
{
if (__ct.is(ctype_base::space, *__b))
__spaces.push_back(*__b++);
else
{
__err |= ios_base::failbit;
return false;
}
}
((void)0);
case money_base::none:
if (__p != 3)
{
while (__b != __e && __ct.is(ctype_base::space, *__b))
__spaces.push_back(*__b++);
}
break;
case money_base::sign:
if (__psn.size() + __nsn.size() > 0)
{
if (__psn.size() == 0 || __nsn.size() == 0)
{
if (__psn.size() > 0)
{
if (*__b == __psn[0])
{
++__b;
if (__psn.size() > 1)
__trailing_sign = &__psn;
}
else
__neg = true;
}
else if (*__b == __nsn[0])
{
++__b;
__neg = true;
if (__nsn.size() > 1)
__trailing_sign = &__nsn;
}
}
else
{
if (*__b == __psn[0])
{
++__b;
if (__psn.size() > 1)
__trailing_sign = &__psn;
}
else if (*__b == __nsn[0])
{
++__b;
__neg = true;
if (__nsn.size() > 1)
__trailing_sign = &__nsn;
}
else
{
__err |= ios_base::failbit;
return false;
}
}
}
break;
case money_base::symbol:
{
bool __more_needed = __trailing_sign ||
(__p < 2) ||
(__p == 2 && __pat.field[3] != static_cast<char>(money_base::none));
bool __sb = (__flags & ios_base::showbase) != 0;
if (__sb || __more_needed)
{
typename string_type::const_iterator __sym_space_end = __sym.begin();
if (__p > 0 && (__pat.field[__p - 1] == money_base::none ||
__pat.field[__p - 1] == money_base::space)) {
while (__sym_space_end != __sym.end() &&
__ct.is(ctype_base::space, *__sym_space_end))
++__sym_space_end;
const size_t __num_spaces = __sym_space_end - __sym.begin();
if (__num_spaces > __spaces.size() ||
!equal(__spaces.end() - __num_spaces, __spaces.end(),
__sym.begin())) {
__sym_space_end = __sym.begin();
}
}
typename string_type::const_iterator __sym_curr_char = __sym_space_end;
while (__sym_curr_char != __sym.end() && __b != __e &&
*__b == *__sym_curr_char) {
++__b;
++__sym_curr_char;
}
if (__sb && __sym_curr_char != __sym.end())
{
__err |= ios_base::failbit;
return false;
}
}
}
break;
case money_base::value:
{
unsigned __ng = 0;
for (; __b != __e; ++__b)
{
char_type __c = *__b;
if (__ct.is(ctype_base::digit, __c))
{
if (__wn == __we)
__double_or_nothing(__wb, __wn, __we);
*__wn++ = __c;
++__ng;
}
else if (__grp.size() > 0 && __ng > 0 && __c == __ts)
{
if (__gn == __ge)
__double_or_nothing(__gb, __gn, __ge);
*__gn++ = __ng;
__ng = 0;
}
else
break;
}
if (__gb.get() != __gn && __ng > 0)
{
if (__gn == __ge)
__double_or_nothing(__gb, __gn, __ge);
*__gn++ = __ng;
}
if (__fd > 0)
{
if (__b == __e || *__b != __dp)
{
__err |= ios_base::failbit;
return false;
}
for (++__b; __fd > 0; --__fd, ++__b)
{
if (__b == __e || !__ct.is(ctype_base::digit, *__b))
{
__err |= ios_base::failbit;
return false;
}
if (__wn == __we)
__double_or_nothing(__wb, __wn, __we);
*__wn++ = *__b;
}
}
if (__wn == __wb.get())
{
__err |= ios_base::failbit;
return false;
}
}
break;
}
}
if (__trailing_sign)
{
for (unsigned __i = 1; __i < __trailing_sign->size(); ++__i, ++__b)
{
if (__b == __e || *__b != (*__trailing_sign)[__i])
{
__err |= ios_base::failbit;
return false;
}
}
}
if (__gb.get() != __gn)
{
ios_base::iostate __et = ios_base::goodbit;
__check_grouping(__grp, __gb.get(), __gn, __et);
if (__et)
{
__err |= ios_base::failbit;
return false;
}
}
return true;
}
template <class _CharT, class _InputIterator>
_InputIterator
money_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e,
bool __intl, ios_base& __iob,
ios_base::iostate& __err,
long double& __v) const
{
const int __bz = 100;
char_type __wbuf[__bz];
unique_ptr<char_type, void(*)(void*)> __wb(__wbuf, __do_nothing);
char_type* __wn;
char_type* __we = __wbuf + __bz;
locale __loc = __iob.getloc();
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__loc);
bool __neg = false;
if (__do_get(__b, __e, __intl, __loc, __iob.flags(), __err, __neg, __ct,
__wb, __wn, __we))
{
const char __src[] = "0123456789";
char_type __atoms[sizeof(__src)-1];
__ct.widen(__src, __src + (sizeof(__src)-1), __atoms);
char __nbuf[__bz];
char* __nc = __nbuf;
unique_ptr<char, void(*)(void*)> __h(0, free);
if (__wn - __wb.get() > __bz-2)
{
__h.reset((char*)malloc(static_cast<size_t>(__wn - __wb.get() + 2)));
if (__h.get() == 0)
__throw_bad_alloc();
__nc = __h.get();
}
if (__neg)
*__nc++ = '-';
for (const char_type* __w = __wb.get(); __w < __wn; ++__w, ++__nc)
*__nc = __src[find(__atoms, std::__1::end(__atoms), *__w) - __atoms];
*__nc = char();
if (sscanf(__nbuf, "%Lf", &__v) != 1)
__throw_runtime_error("money_get error");
}
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
template <class _CharT, class _InputIterator>
_InputIterator
money_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e,
bool __intl, ios_base& __iob,
ios_base::iostate& __err,
string_type& __v) const
{
const int __bz = 100;
char_type __wbuf[__bz];
unique_ptr<char_type, void(*)(void*)> __wb(__wbuf, __do_nothing);
char_type* __wn;
char_type* __we = __wbuf + __bz;
locale __loc = __iob.getloc();
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__loc);
bool __neg = false;
if (__do_get(__b, __e, __intl, __loc, __iob.flags(), __err, __neg, __ct,
__wb, __wn, __we))
{
__v.clear();
if (__neg)
__v.push_back(__ct.widen('-'));
char_type __z = __ct.widen('0');
char_type* __w;
for (__w = __wb.get(); __w < __wn-1; ++__w)
if (*__w != __z)
break;
__v.append(__w, __wn);
}
if (__b == __e)
__err |= ios_base::eofbit;
return __b;
}
extern template class __attribute__ ((__visibility__("default"))) money_get<char>;
extern template class __attribute__ ((__visibility__("default"))) money_get<wchar_t>;
template <class _CharT>
class __money_put
{
protected:
typedef _CharT char_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__)) __money_put() {}
static void __gather_info(bool __intl, bool __neg, const locale& __loc,
money_base::pattern& __pat, char_type& __dp,
char_type& __ts, string& __grp,
string_type& __sym, string_type& __sn,
int& __fd);
static void __format(char_type* __mb, char_type*& __mi, char_type*& __me,
ios_base::fmtflags __flags,
const char_type* __db, const char_type* __de,
const ctype<char_type>& __ct, bool __neg,
const money_base::pattern& __pat, char_type __dp,
char_type __ts, const string& __grp,
const string_type& __sym, const string_type& __sn,
int __fd);
};
template <class _CharT>
void
__money_put<_CharT>::__gather_info(bool __intl, bool __neg, const locale& __loc,
money_base::pattern& __pat, char_type& __dp,
char_type& __ts, string& __grp,
string_type& __sym, string_type& __sn,
int& __fd)
{
if (__intl)
{
const moneypunct<char_type, true>& __mp =
use_facet<moneypunct<char_type, true> >(__loc);
if (__neg)
{
__pat = __mp.neg_format();
__sn = __mp.negative_sign();
}
else
{
__pat = __mp.pos_format();
__sn = __mp.positive_sign();
}
__dp = __mp.decimal_point();
__ts = __mp.thousands_sep();
__grp = __mp.grouping();
__sym = __mp.curr_symbol();
__fd = __mp.frac_digits();
}
else
{
const moneypunct<char_type, false>& __mp =
use_facet<moneypunct<char_type, false> >(__loc);
if (__neg)
{
__pat = __mp.neg_format();
__sn = __mp.negative_sign();
}
else
{
__pat = __mp.pos_format();
__sn = __mp.positive_sign();
}
__dp = __mp.decimal_point();
__ts = __mp.thousands_sep();
__grp = __mp.grouping();
__sym = __mp.curr_symbol();
__fd = __mp.frac_digits();
}
}
template <class _CharT>
void
__money_put<_CharT>::__format(char_type* __mb, char_type*& __mi, char_type*& __me,
ios_base::fmtflags __flags,
const char_type* __db, const char_type* __de,
const ctype<char_type>& __ct, bool __neg,
const money_base::pattern& __pat, char_type __dp,
char_type __ts, const string& __grp,
const string_type& __sym, const string_type& __sn,
int __fd)
{
__me = __mb;
for (unsigned __p = 0; __p < 4; ++__p)
{
switch (__pat.field[__p])
{
case money_base::none:
__mi = __me;
break;
case money_base::space:
__mi = __me;
*__me++ = __ct.widen(' ');
break;
case money_base::sign:
if (!__sn.empty())
*__me++ = __sn[0];
break;
case money_base::symbol:
if (!__sym.empty() && (__flags & ios_base::showbase))
__me = std::__1::copy(__sym.begin(), __sym.end(), __me);
break;
case money_base::value:
{
char_type* __t = __me;
if (__neg)
++__db;
const char_type* __d;
for (__d = __db; __d < __de; ++__d)
if (!__ct.is(ctype_base::digit, *__d))
break;
if (__fd > 0)
{
int __f;
for (__f = __fd; __d > __db && __f > 0; --__f)
*__me++ = *--__d;
char_type __z = __f > 0 ? __ct.widen('0') : char_type();
for (; __f > 0; --__f)
*__me++ = __z;
*__me++ = __dp;
}
if (__d == __db)
{
*__me++ = __ct.widen('0');
}
else
{
unsigned __ng = 0;
unsigned __ig = 0;
unsigned __gl = __grp.empty() ? numeric_limits<unsigned>::max()
: static_cast<unsigned>(__grp[__ig]);
while (__d != __db)
{
if (__ng == __gl)
{
*__me++ = __ts;
__ng = 0;
if (++__ig < __grp.size())
__gl = __grp[__ig] == numeric_limits<char>::max() ?
numeric_limits<unsigned>::max() :
static_cast<unsigned>(__grp[__ig]);
}
*__me++ = *--__d;
++__ng;
}
}
reverse(__t, __me);
}
break;
}
}
if (__sn.size() > 1)
__me = std::__1::copy(__sn.begin()+1, __sn.end(), __me);
if ((__flags & ios_base::adjustfield) == ios_base::left)
__mi = __me;
else if ((__flags & ios_base::adjustfield) != ios_base::internal)
__mi = __mb;
}
extern template class __attribute__ ((__visibility__("default"))) __money_put<char>;
extern template class __attribute__ ((__visibility__("default"))) __money_put<wchar_t>;
template <class _CharT, class _OutputIterator = ostreambuf_iterator<_CharT> >
class __attribute__ ((__type_visibility__("default"))) money_put
: public locale::facet,
private __money_put<_CharT>
{
public:
typedef _CharT char_type;
typedef _OutputIterator iter_type;
typedef basic_string<char_type> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit money_put(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, bool __intl, ios_base& __iob, char_type __fl,
long double __units) const
{
return do_put(__s, __intl, __iob, __fl, __units);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
iter_type put(iter_type __s, bool __intl, ios_base& __iob, char_type __fl,
const string_type& __digits) const
{
return do_put(__s, __intl, __iob, __fl, __digits);
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~money_put() {}
virtual iter_type do_put(iter_type __s, bool __intl, ios_base& __iob,
char_type __fl, long double __units) const;
virtual iter_type do_put(iter_type __s, bool __intl, ios_base& __iob,
char_type __fl, const string_type& __digits) const;
};
template <class _CharT, class _OutputIterator>
locale::id
money_put<_CharT, _OutputIterator>::id;
template <class _CharT, class _OutputIterator>
_OutputIterator
money_put<_CharT, _OutputIterator>::do_put(iter_type __s, bool __intl,
ios_base& __iob, char_type __fl,
long double __units) const
{
const size_t __bs = 100;
char __buf[__bs];
char* __bb = __buf;
char_type __digits[__bs];
char_type* __db = __digits;
size_t __n = static_cast<size_t>(snprintf(__bb, __bs, "%.0Lf", __units));
unique_ptr<char, void(*)(void*)> __hn(0, free);
unique_ptr<char_type, void(*)(void*)> __hd(0, free);
if (__n > __bs-1)
{
__n = static_cast<size_t>(asprintf_l(&__bb, 0, "%.0Lf", __units));
if (__bb == 0)
__throw_bad_alloc();
__hn.reset(__bb);
__hd.reset((char_type*)malloc(__n * sizeof(char_type)));
if (__hd == std::__1::__get_nullptr_t())
__throw_bad_alloc();
__db = __hd.get();
}
locale __loc = __iob.getloc();
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__loc);
__ct.widen(__bb, __bb + __n, __db);
bool __neg = __n > 0 && __bb[0] == '-';
money_base::pattern __pat;
char_type __dp;
char_type __ts;
string __grp;
string_type __sym;
string_type __sn;
int __fd;
this->__gather_info(__intl, __neg, __loc, __pat, __dp, __ts, __grp, __sym, __sn, __fd);
char_type __mbuf[__bs];
char_type* __mb = __mbuf;
unique_ptr<char_type, void(*)(void*)> __hw(0, free);
size_t __exn = static_cast<int>(__n) > __fd ?
(__n - static_cast<size_t>(__fd)) * 2 + __sn.size() +
__sym.size() + static_cast<size_t>(__fd) + 1
: __sn.size() + __sym.size() + static_cast<size_t>(__fd) + 2;
if (__exn > __bs)
{
__hw.reset((char_type*)malloc(__exn * sizeof(char_type)));
__mb = __hw.get();
if (__mb == 0)
__throw_bad_alloc();
}
char_type* __mi;
char_type* __me;
this->__format(__mb, __mi, __me, __iob.flags(),
__db, __db + __n, __ct,
__neg, __pat, __dp, __ts, __grp, __sym, __sn, __fd);
return __pad_and_output(__s, __mb, __mi, __me, __iob, __fl);
}
template <class _CharT, class _OutputIterator>
_OutputIterator
money_put<_CharT, _OutputIterator>::do_put(iter_type __s, bool __intl,
ios_base& __iob, char_type __fl,
const string_type& __digits) const
{
locale __loc = __iob.getloc();
const ctype<char_type>& __ct = use_facet<ctype<char_type> >(__loc);
bool __neg = __digits.size() > 0 && __digits[0] == __ct.widen('-');
money_base::pattern __pat;
char_type __dp;
char_type __ts;
string __grp;
string_type __sym;
string_type __sn;
int __fd;
this->__gather_info(__intl, __neg, __loc, __pat, __dp, __ts, __grp, __sym, __sn, __fd);
char_type __mbuf[100];
char_type* __mb = __mbuf;
unique_ptr<char_type, void(*)(void*)> __h(0, free);
size_t __exn = static_cast<int>(__digits.size()) > __fd ?
(__digits.size() - static_cast<size_t>(__fd)) * 2 +
__sn.size() + __sym.size() + static_cast<size_t>(__fd) + 1
: __sn.size() + __sym.size() + static_cast<size_t>(__fd) + 2;
if (__exn > 100)
{
__h.reset((char_type*)malloc(__exn * sizeof(char_type)));
__mb = __h.get();
if (__mb == 0)
__throw_bad_alloc();
}
char_type* __mi;
char_type* __me;
this->__format(__mb, __mi, __me, __iob.flags(),
__digits.data(), __digits.data() + __digits.size(), __ct,
__neg, __pat, __dp, __ts, __grp, __sym, __sn, __fd);
return __pad_and_output(__s, __mb, __mi, __me, __iob, __fl);
}
extern template class __attribute__ ((__visibility__("default"))) money_put<char>;
extern template class __attribute__ ((__visibility__("default"))) money_put<wchar_t>;
class __attribute__ ((__visibility__("default"))) messages_base
{
public:
typedef ptrdiff_t catalog;
__attribute__ ((__visibility__("hidden"), __always_inline__)) messages_base() {}
};
template <class _CharT>
class __attribute__ ((__type_visibility__("default"))) messages
: public locale::facet,
public messages_base
{
public:
typedef _CharT char_type;
typedef basic_string<_CharT> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit messages(size_t __refs = 0)
: locale::facet(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
catalog open(const basic_string<char>& __nm, const locale& __loc) const
{
return do_open(__nm, __loc);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
string_type get(catalog __c, int __set, int __msgid,
const string_type& __dflt) const
{
return do_get(__c, __set, __msgid, __dflt);
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void close(catalog __c) const
{
do_close(__c);
}
static locale::id id;
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~messages() {}
virtual catalog do_open(const basic_string<char>&, const locale&) const;
virtual string_type do_get(catalog, int __set, int __msgid,
const string_type& __dflt) const;
virtual void do_close(catalog) const;
};
template <class _CharT>
locale::id
messages<_CharT>::id;
template <class _CharT>
typename messages<_CharT>::catalog
messages<_CharT>::do_open(const basic_string<char>& __nm, const locale&) const
{
catalog __cat = (catalog)catopen(__nm.c_str(), 1);
if (__cat != -1)
__cat = static_cast<catalog>((static_cast<size_t>(__cat) >> 1));
return __cat;
}
template <class _CharT>
typename messages<_CharT>::string_type
messages<_CharT>::do_get(catalog __c, int __set, int __msgid,
const string_type& __dflt) const
{
string __ndflt;
__narrow_to_utf8<sizeof(char_type)*8>()(back_inserter(__ndflt),
__dflt.c_str(),
__dflt.c_str() + __dflt.size());
if (__c != -1)
__c <<= 1;
nl_catd __cat = (nl_catd)__c;
char* __n = catgets(__cat, __set, __msgid, __ndflt.c_str());
string_type __w;
__widen_from_utf8<sizeof(char_type)*8>()(back_inserter(__w),
__n, __n + strlen(__n));
return __w;
}
template <class _CharT>
void
messages<_CharT>::do_close(catalog __c) const
{
if (__c != -1)
__c <<= 1;
nl_catd __cat = (nl_catd)__c;
catclose(__cat);
}
extern template class __attribute__ ((__visibility__("default"))) messages<char>;
extern template class __attribute__ ((__visibility__("default"))) messages<wchar_t>;
template <class _CharT>
class __attribute__ ((__type_visibility__("default"))) messages_byname
: public messages<_CharT>
{
public:
typedef messages_base::catalog catalog;
typedef basic_string<_CharT> string_type;
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit messages_byname(const char*, size_t __refs = 0)
: messages<_CharT>(__refs) {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit messages_byname(const string&, size_t __refs = 0)
: messages<_CharT>(__refs) {}
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
~messages_byname() {}
};
extern template class __attribute__ ((__visibility__("default"))) messages_byname<char>;
extern template class __attribute__ ((__visibility__("default"))) messages_byname<wchar_t>;
template<class _Codecvt, class _Elem = wchar_t,
class _Wide_alloc = allocator<_Elem>,
class _Byte_alloc = allocator<char> >
class __attribute__ ((__type_visibility__("default"))) wstring_convert
{
public:
typedef basic_string<char, char_traits<char>, _Byte_alloc> byte_string;
typedef basic_string<_Elem, char_traits<_Elem>, _Wide_alloc> wide_string;
typedef typename _Codecvt::state_type state_type;
typedef typename wide_string::traits_type::int_type int_type;
private:
byte_string __byte_err_string_;
wide_string __wide_err_string_;
_Codecvt* __cvtptr_;
state_type __cvtstate_;
size_t __cvtcount_;
wstring_convert(const wstring_convert& __wc);
wstring_convert& operator=(const wstring_convert& __wc);
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
wstring_convert(_Codecvt* __pcvt = new _Codecvt);
__attribute__ ((__visibility__("hidden"), __always_inline__))
wstring_convert(_Codecvt* __pcvt, state_type __state);
wstring_convert(const byte_string& __byte_err,
const wide_string& __wide_err = wide_string());
~wstring_convert();
__attribute__ ((__visibility__("hidden"), __always_inline__))
wide_string from_bytes(char __byte)
{return from_bytes(&__byte, &__byte+1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
wide_string from_bytes(const char* __ptr)
{return from_bytes(__ptr, __ptr + char_traits<char>::length(__ptr));}
__attribute__ ((__visibility__("hidden"), __always_inline__))
wide_string from_bytes(const byte_string& __str)
{return from_bytes(__str.data(), __str.data() + __str.size());}
wide_string from_bytes(const char* __first, const char* __last);
__attribute__ ((__visibility__("hidden"), __always_inline__))
byte_string to_bytes(_Elem __wchar)
{return to_bytes(&__wchar, &__wchar+1);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
byte_string to_bytes(const _Elem* __wptr)
{return to_bytes(__wptr, __wptr + char_traits<_Elem>::length(__wptr));}
__attribute__ ((__visibility__("hidden"), __always_inline__))
byte_string to_bytes(const wide_string& __wstr)
{return to_bytes(__wstr.data(), __wstr.data() + __wstr.size());}
byte_string to_bytes(const _Elem* __first, const _Elem* __last);
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t converted() const throw() {return __cvtcount_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
state_type state() const {return __cvtstate_;}
};
template<class _Codecvt, class _Elem, class _Wide_alloc, class _Byte_alloc>
inline
wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::
wstring_convert(_Codecvt* __pcvt)
: __cvtptr_(__pcvt), __cvtstate_(), __cvtcount_(0)
{
}
template<class _Codecvt, class _Elem, class _Wide_alloc, class _Byte_alloc>
inline
wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::
wstring_convert(_Codecvt* __pcvt, state_type __state)
: __cvtptr_(__pcvt), __cvtstate_(__state), __cvtcount_(0)
{
}
template<class _Codecvt, class _Elem, class _Wide_alloc, class _Byte_alloc>
wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::
wstring_convert(const byte_string& __byte_err, const wide_string& __wide_err)
: __byte_err_string_(__byte_err), __wide_err_string_(__wide_err),
__cvtstate_(), __cvtcount_(0)
{
__cvtptr_ = new _Codecvt;
}
# 3720 "/Library/Developer/CommandLineTools/usr/include/c++/v1/locale" 3
template<class _Codecvt, class _Elem, class _Wide_alloc, class _Byte_alloc>
wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::~wstring_convert()
{
delete __cvtptr_;
}
template<class _Codecvt, class _Elem, class _Wide_alloc, class _Byte_alloc>
typename wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::wide_string
wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::
from_bytes(const char* __frm, const char* __frm_end)
{
__cvtcount_ = 0;
if (__cvtptr_ != std::__1::__get_nullptr_t())
{
wide_string __ws(2*(__frm_end - __frm), _Elem());
if (__frm != __frm_end)
__ws.resize(__ws.capacity());
codecvt_base::result __r = codecvt_base::ok;
state_type __st = __cvtstate_;
if (__frm != __frm_end)
{
_Elem* __to = &__ws[0];
_Elem* __to_end = __to + __ws.size();
const char* __frm_nxt;
do
{
_Elem* __to_nxt;
__r = __cvtptr_->in(__st, __frm, __frm_end, __frm_nxt,
__to, __to_end, __to_nxt);
__cvtcount_ += __frm_nxt - __frm;
if (__frm_nxt == __frm)
{
__r = codecvt_base::error;
}
else if (__r == codecvt_base::noconv)
{
__ws.resize(__to - &__ws[0]);
__ws.append((const _Elem*)__frm, (const _Elem*)__frm_end);
__frm = __frm_nxt;
__r = codecvt_base::ok;
}
else if (__r == codecvt_base::ok)
{
__ws.resize(__to_nxt - &__ws[0]);
__frm = __frm_nxt;
}
else if (__r == codecvt_base::partial)
{
ptrdiff_t __s = __to_nxt - &__ws[0];
__ws.resize(2 * __s);
__to = &__ws[0] + __s;
__to_end = &__ws[0] + __ws.size();
__frm = __frm_nxt;
}
} while (__r == codecvt_base::partial && __frm_nxt < __frm_end);
}
if (__r == codecvt_base::ok)
return __ws;
}
if (__wide_err_string_.empty())
__throw_range_error("wstring_convert: from_bytes error");
return __wide_err_string_;
}
template<class _Codecvt, class _Elem, class _Wide_alloc, class _Byte_alloc>
typename wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::byte_string
wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::
to_bytes(const _Elem* __frm, const _Elem* __frm_end)
{
__cvtcount_ = 0;
if (__cvtptr_ != std::__1::__get_nullptr_t())
{
byte_string __bs(2*(__frm_end - __frm), char());
if (__frm != __frm_end)
__bs.resize(__bs.capacity());
codecvt_base::result __r = codecvt_base::ok;
state_type __st = __cvtstate_;
if (__frm != __frm_end)
{
char* __to = &__bs[0];
char* __to_end = __to + __bs.size();
const _Elem* __frm_nxt;
do
{
char* __to_nxt;
__r = __cvtptr_->out(__st, __frm, __frm_end, __frm_nxt,
__to, __to_end, __to_nxt);
__cvtcount_ += __frm_nxt - __frm;
if (__frm_nxt == __frm)
{
__r = codecvt_base::error;
}
else if (__r == codecvt_base::noconv)
{
__bs.resize(__to - &__bs[0]);
__bs.append((const char*)__frm, (const char*)__frm_end);
__frm = __frm_nxt;
__r = codecvt_base::ok;
}
else if (__r == codecvt_base::ok)
{
__bs.resize(__to_nxt - &__bs[0]);
__frm = __frm_nxt;
}
else if (__r == codecvt_base::partial)
{
ptrdiff_t __s = __to_nxt - &__bs[0];
__bs.resize(2 * __s);
__to = &__bs[0] + __s;
__to_end = &__bs[0] + __bs.size();
__frm = __frm_nxt;
}
} while (__r == codecvt_base::partial && __frm_nxt < __frm_end);
}
if (__r == codecvt_base::ok)
{
size_t __s = __bs.size();
__bs.resize(__bs.capacity());
char* __to = &__bs[0] + __s;
char* __to_end = __to + __bs.size();
do
{
char* __to_nxt;
__r = __cvtptr_->unshift(__st, __to, __to_end, __to_nxt);
if (__r == codecvt_base::noconv)
{
__bs.resize(__to - &__bs[0]);
__r = codecvt_base::ok;
}
else if (__r == codecvt_base::ok)
{
__bs.resize(__to_nxt - &__bs[0]);
}
else if (__r == codecvt_base::partial)
{
ptrdiff_t __sp = __to_nxt - &__bs[0];
__bs.resize(2 * __sp);
__to = &__bs[0] + __sp;
__to_end = &__bs[0] + __bs.size();
}
} while (__r == codecvt_base::partial);
if (__r == codecvt_base::ok)
return __bs;
}
}
if (__byte_err_string_.empty())
__throw_range_error("wstring_convert: to_bytes error");
return __byte_err_string_;
}
template <class _Codecvt, class _Elem = wchar_t, class _Tr = char_traits<_Elem> >
class __attribute__ ((__type_visibility__("default"))) wbuffer_convert
: public basic_streambuf<_Elem, _Tr>
{
public:
typedef _Elem char_type;
typedef _Tr traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
typedef typename _Codecvt::state_type state_type;
private:
char* __extbuf_;
const char* __extbufnext_;
const char* __extbufend_;
char __extbuf_min_[8];
size_t __ebs_;
char_type* __intbuf_;
size_t __ibs_;
streambuf* __bufptr_;
_Codecvt* __cv_;
state_type __st_;
ios_base::openmode __cm_;
bool __owns_eb_;
bool __owns_ib_;
bool __always_noconv_;
wbuffer_convert(const wbuffer_convert&);
wbuffer_convert& operator=(const wbuffer_convert&);
public:
wbuffer_convert(streambuf* __bytebuf = 0,
_Codecvt* __pcvt = new _Codecvt, state_type __state = state_type());
~wbuffer_convert();
__attribute__ ((__visibility__("hidden"), __always_inline__))
streambuf* rdbuf() const {return __bufptr_;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
streambuf* rdbuf(streambuf* __bytebuf)
{
streambuf* __r = __bufptr_;
__bufptr_ = __bytebuf;
return __r;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
state_type state() const {return __st_;}
protected:
virtual int_type underflow();
virtual int_type pbackfail(int_type __c = traits_type::eof());
virtual int_type overflow (int_type __c = traits_type::eof());
virtual basic_streambuf<char_type, traits_type>* setbuf(char_type* __s,
streamsize __n);
virtual pos_type seekoff(off_type __off, ios_base::seekdir __way,
ios_base::openmode __wch = ios_base::in | ios_base::out);
virtual pos_type seekpos(pos_type __sp,
ios_base::openmode __wch = ios_base::in | ios_base::out);
virtual int sync();
private:
bool __read_mode();
void __write_mode();
wbuffer_convert* __close();
};
template <class _Codecvt, class _Elem, class _Tr>
wbuffer_convert<_Codecvt, _Elem, _Tr>::
wbuffer_convert(streambuf* __bytebuf, _Codecvt* __pcvt, state_type __state)
: __extbuf_(0),
__extbufnext_(0),
__extbufend_(0),
__ebs_(0),
__intbuf_(0),
__ibs_(0),
__bufptr_(__bytebuf),
__cv_(__pcvt),
__st_(__state),
__cm_(0),
__owns_eb_(false),
__owns_ib_(false),
__always_noconv_(__cv_ ? __cv_->always_noconv() : false)
{
setbuf(0, 4096);
}
template <class _Codecvt, class _Elem, class _Tr>
wbuffer_convert<_Codecvt, _Elem, _Tr>::~wbuffer_convert()
{
__close();
delete __cv_;
if (__owns_eb_)
delete [] __extbuf_;
if (__owns_ib_)
delete [] __intbuf_;
}
template <class _Codecvt, class _Elem, class _Tr>
typename wbuffer_convert<_Codecvt, _Elem, _Tr>::int_type
wbuffer_convert<_Codecvt, _Elem, _Tr>::underflow()
{
if (__cv_ == 0 || __bufptr_ == 0)
return traits_type::eof();
bool __initial = __read_mode();
char_type __1buf;
if (this->gptr() == 0)
this->setg(&__1buf, &__1buf+1, &__1buf+1);
const size_t __unget_sz = __initial ? 0 : min<size_t>((this->egptr() - this->eback()) / 2, 4);
int_type __c = traits_type::eof();
if (this->gptr() == this->egptr())
{
memmove(this->eback(), this->egptr() - __unget_sz, __unget_sz * sizeof(char_type));
if (__always_noconv_)
{
streamsize __nmemb = static_cast<streamsize>(this->egptr() - this->eback() - __unget_sz);
__nmemb = __bufptr_->sgetn((char*)this->eback() + __unget_sz, __nmemb);
if (__nmemb != 0)
{
this->setg(this->eback(),
this->eback() + __unget_sz,
this->eback() + __unget_sz + __nmemb);
__c = *this->gptr();
}
}
else
{
((void)0);
if (__extbufend_ != __extbufnext_)
memmove(__extbuf_, __extbufnext_, __extbufend_ - __extbufnext_);
__extbufnext_ = __extbuf_ + (__extbufend_ - __extbufnext_);
__extbufend_ = __extbuf_ + (__extbuf_ == __extbuf_min_ ? sizeof(__extbuf_min_) : __ebs_);
streamsize __nmemb = std::__1::min(static_cast<streamsize>(this->egptr() - this->eback() - __unget_sz),
static_cast<streamsize>(__extbufend_ - __extbufnext_));
codecvt_base::result __r;
streamsize __nr = __bufptr_->sgetn(const_cast<char*>(__extbufnext_), __nmemb);
if (__nr != 0)
{
__extbufend_ = __extbufnext_ + __nr;
char_type* __inext;
__r = __cv_->in(__st_, __extbuf_, __extbufend_, __extbufnext_,
this->eback() + __unget_sz,
this->egptr(), __inext);
if (__r == codecvt_base::noconv)
{
this->setg((char_type*)__extbuf_, (char_type*)__extbuf_,
(char_type*) const_cast<char *>(__extbufend_));
__c = *this->gptr();
}
else if (__inext != this->eback() + __unget_sz)
{
this->setg(this->eback(), this->eback() + __unget_sz, __inext);
__c = *this->gptr();
}
}
}
}
else
__c = *this->gptr();
if (this->eback() == &__1buf)
this->setg(0, 0, 0);
return __c;
}
template <class _Codecvt, class _Elem, class _Tr>
typename wbuffer_convert<_Codecvt, _Elem, _Tr>::int_type
wbuffer_convert<_Codecvt, _Elem, _Tr>::pbackfail(int_type __c)
{
if (__cv_ != 0 && __bufptr_ != 0 && this->eback() < this->gptr())
{
if (traits_type::eq_int_type(__c, traits_type::eof()))
{
this->gbump(-1);
return traits_type::not_eof(__c);
}
if (traits_type::eq(traits_type::to_char_type(__c), this->gptr()[-1]))
{
this->gbump(-1);
*this->gptr() = traits_type::to_char_type(__c);
return __c;
}
}
return traits_type::eof();
}
template <class _Codecvt, class _Elem, class _Tr>
typename wbuffer_convert<_Codecvt, _Elem, _Tr>::int_type
wbuffer_convert<_Codecvt, _Elem, _Tr>::overflow(int_type __c)
{
if (__cv_ == 0 || __bufptr_ == 0)
return traits_type::eof();
__write_mode();
char_type __1buf;
char_type* __pb_save = this->pbase();
char_type* __epb_save = this->epptr();
if (!traits_type::eq_int_type(__c, traits_type::eof()))
{
if (this->pptr() == 0)
this->setp(&__1buf, &__1buf+1);
*this->pptr() = traits_type::to_char_type(__c);
this->pbump(1);
}
if (this->pptr() != this->pbase())
{
if (__always_noconv_)
{
streamsize __nmemb = static_cast<streamsize>(this->pptr() - this->pbase());
if (__bufptr_->sputn((const char*)this->pbase(), __nmemb) != __nmemb)
return traits_type::eof();
}
else
{
char* __extbe = __extbuf_;
codecvt_base::result __r;
do
{
const char_type* __e;
__r = __cv_->out(__st_, this->pbase(), this->pptr(), __e,
__extbuf_, __extbuf_ + __ebs_, __extbe);
if (__e == this->pbase())
return traits_type::eof();
if (__r == codecvt_base::noconv)
{
streamsize __nmemb = static_cast<size_t>(this->pptr() - this->pbase());
if (__bufptr_->sputn((const char*)this->pbase(), __nmemb) != __nmemb)
return traits_type::eof();
}
else if (__r == codecvt_base::ok || __r == codecvt_base::partial)
{
streamsize __nmemb = static_cast<size_t>(__extbe - __extbuf_);
if (__bufptr_->sputn(__extbuf_, __nmemb) != __nmemb)
return traits_type::eof();
if (__r == codecvt_base::partial)
{
this->setp(const_cast<char_type *>(__e), this->pptr());
this->__pbump(this->epptr() - this->pbase());
}
}
else
return traits_type::eof();
} while (__r == codecvt_base::partial);
}
this->setp(__pb_save, __epb_save);
}
return traits_type::not_eof(__c);
}
template <class _Codecvt, class _Elem, class _Tr>
basic_streambuf<_Elem, _Tr>*
wbuffer_convert<_Codecvt, _Elem, _Tr>::setbuf(char_type* __s, streamsize __n)
{
this->setg(0, 0, 0);
this->setp(0, 0);
if (__owns_eb_)
delete [] __extbuf_;
if (__owns_ib_)
delete [] __intbuf_;
__ebs_ = __n;
if (__ebs_ > sizeof(__extbuf_min_))
{
if (__always_noconv_ && __s)
{
__extbuf_ = (char*)__s;
__owns_eb_ = false;
}
else
{
__extbuf_ = new char[__ebs_];
__owns_eb_ = true;
}
}
else
{
__extbuf_ = __extbuf_min_;
__ebs_ = sizeof(__extbuf_min_);
__owns_eb_ = false;
}
if (!__always_noconv_)
{
__ibs_ = max<streamsize>(__n, sizeof(__extbuf_min_));
if (__s && __ibs_ >= sizeof(__extbuf_min_))
{
__intbuf_ = __s;
__owns_ib_ = false;
}
else
{
__intbuf_ = new char_type[__ibs_];
__owns_ib_ = true;
}
}
else
{
__ibs_ = 0;
__intbuf_ = 0;
__owns_ib_ = false;
}
return this;
}
template <class _Codecvt, class _Elem, class _Tr>
typename wbuffer_convert<_Codecvt, _Elem, _Tr>::pos_type
wbuffer_convert<_Codecvt, _Elem, _Tr>::seekoff(off_type __off, ios_base::seekdir __way,
ios_base::openmode __om)
{
int __width = __cv_->encoding();
if (__cv_ == 0 || __bufptr_ == 0 || (__width <= 0 && __off != 0) || sync())
return pos_type(off_type(-1));
if (__way != ios_base::beg && __way != ios_base::cur && __way != ios_base::end)
return pos_type(off_type(-1));
pos_type __r = __bufptr_->pubseekoff(__width * __off, __way, __om);
__r.state(__st_);
return __r;
}
template <class _Codecvt, class _Elem, class _Tr>
typename wbuffer_convert<_Codecvt, _Elem, _Tr>::pos_type
wbuffer_convert<_Codecvt, _Elem, _Tr>::seekpos(pos_type __sp, ios_base::openmode __wch)
{
if (__cv_ == 0 || __bufptr_ == 0 || sync())
return pos_type(off_type(-1));
if (__bufptr_->pubseekpos(__sp, __wch) == pos_type(off_type(-1)))
return pos_type(off_type(-1));
return __sp;
}
template <class _Codecvt, class _Elem, class _Tr>
int
wbuffer_convert<_Codecvt, _Elem, _Tr>::sync()
{
if (__cv_ == 0 || __bufptr_ == 0)
return 0;
if (__cm_ & ios_base::out)
{
if (this->pptr() != this->pbase())
if (overflow() == traits_type::eof())
return -1;
codecvt_base::result __r;
do
{
char* __extbe;
__r = __cv_->unshift(__st_, __extbuf_, __extbuf_ + __ebs_, __extbe);
streamsize __nmemb = static_cast<streamsize>(__extbe - __extbuf_);
if (__bufptr_->sputn(__extbuf_, __nmemb) != __nmemb)
return -1;
} while (__r == codecvt_base::partial);
if (__r == codecvt_base::error)
return -1;
if (__bufptr_->pubsync())
return -1;
}
else if (__cm_ & ios_base::in)
{
off_type __c;
if (__always_noconv_)
__c = this->egptr() - this->gptr();
else
{
int __width = __cv_->encoding();
__c = __extbufend_ - __extbufnext_;
if (__width > 0)
__c += __width * (this->egptr() - this->gptr());
else
{
if (this->gptr() != this->egptr())
{
reverse(this->gptr(), this->egptr());
codecvt_base::result __r;
const char_type* __e = this->gptr();
char* __extbe;
do
{
__r = __cv_->out(__st_, __e, this->egptr(), __e,
__extbuf_, __extbuf_ + __ebs_, __extbe);
switch (__r)
{
case codecvt_base::noconv:
__c += this->egptr() - this->gptr();
break;
case codecvt_base::ok:
case codecvt_base::partial:
__c += __extbe - __extbuf_;
break;
default:
return -1;
}
} while (__r == codecvt_base::partial);
}
}
}
if (__bufptr_->pubseekoff(-__c, ios_base::cur, __cm_) == pos_type(off_type(-1)))
return -1;
this->setg(0, 0, 0);
__cm_ = 0;
}
return 0;
}
template <class _Codecvt, class _Elem, class _Tr>
bool
wbuffer_convert<_Codecvt, _Elem, _Tr>::__read_mode()
{
if (!(__cm_ & ios_base::in))
{
this->setp(0, 0);
if (__always_noconv_)
this->setg((char_type*)__extbuf_,
(char_type*)__extbuf_ + __ebs_,
(char_type*)__extbuf_ + __ebs_);
else
this->setg(__intbuf_, __intbuf_ + __ibs_, __intbuf_ + __ibs_);
__cm_ = ios_base::in;
return true;
}
return false;
}
template <class _Codecvt, class _Elem, class _Tr>
void
wbuffer_convert<_Codecvt, _Elem, _Tr>::__write_mode()
{
if (!(__cm_ & ios_base::out))
{
this->setg(0, 0, 0);
if (__ebs_ > sizeof(__extbuf_min_))
{
if (__always_noconv_)
this->setp((char_type*)__extbuf_,
(char_type*)__extbuf_ + (__ebs_ - 1));
else
this->setp(__intbuf_, __intbuf_ + (__ibs_ - 1));
}
else
this->setp(0, 0);
__cm_ = ios_base::out;
}
}
template <class _Codecvt, class _Elem, class _Tr>
wbuffer_convert<_Codecvt, _Elem, _Tr>*
wbuffer_convert<_Codecvt, _Elem, _Tr>::__close()
{
wbuffer_convert* __rt = 0;
if (__cv_ != 0 && __bufptr_ != 0)
{
__rt = this;
if ((__cm_ & ios_base::out) && sync())
__rt = 0;
}
return __rt;
}
} }
# 141 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/bitset" 1 3
# 117 "/Library/Developer/CommandLineTools/usr/include/c++/v1/bitset" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__bit_reference" 1 3
# 19 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__bit_reference" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 23 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__bit_reference" 2 3
namespace std {inline namespace __1 {
template <class _Cp, bool _IsConst, typename _Cp::__storage_type = 0> class __bit_iterator;
template <class _Cp> class __bit_const_reference;
template <class _Tp>
struct __has_storage_type
{
static const bool value = false;
};
template <class _Cp, bool = __has_storage_type<_Cp>::value>
class __bit_reference
{
typedef typename _Cp::__storage_type __storage_type;
typedef typename _Cp::__storage_pointer __storage_pointer;
__storage_pointer __seg_;
__storage_type __mask_;
friend typename _Cp::__self;
friend class __bit_const_reference<_Cp>;
friend class __bit_iterator<_Cp, false>;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator bool() const throw()
{return static_cast<bool>(*__seg_ & __mask_);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool operator ~() const throw()
{return !static_cast<bool>(*this);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_reference& operator=(bool __x) throw()
{
if (__x)
*__seg_ |= __mask_;
else
*__seg_ &= ~__mask_;
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_reference& operator=(const __bit_reference& __x) throw()
{return operator=(static_cast<bool>(__x));}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void flip() throw() {*__seg_ ^= __mask_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator<_Cp, false> operator&() const throw()
{return __bit_iterator<_Cp, false>(__seg_, static_cast<unsigned>(__ctz(__mask_)));}
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_reference(__storage_pointer __s, __storage_type __m) throw()
: __seg_(__s), __mask_(__m) {}
};
template <class _Cp>
class __bit_reference<_Cp, false>
{
};
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(__bit_reference<_Cp> __x, __bit_reference<_Cp> __y) throw()
{
bool __t = __x;
__x = __y;
__y = __t;
}
template <class _Cp, class _Dp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(__bit_reference<_Cp> __x, __bit_reference<_Dp> __y) throw()
{
bool __t = __x;
__x = __y;
__y = __t;
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(__bit_reference<_Cp> __x, bool& __y) throw()
{
bool __t = __x;
__x = __y;
__y = __t;
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(bool& __x, __bit_reference<_Cp> __y) throw()
{
bool __t = __x;
__x = __y;
__y = __t;
}
template <class _Cp>
class __bit_const_reference
{
typedef typename _Cp::__storage_type __storage_type;
typedef typename _Cp::__const_storage_pointer __storage_pointer;
__storage_pointer __seg_;
__storage_type __mask_;
friend typename _Cp::__self;
friend class __bit_iterator<_Cp, true>;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_const_reference(const __bit_reference<_Cp>& __x) throw()
: __seg_(__x.__seg_), __mask_(__x.__mask_) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) operator bool() const throw()
{return static_cast<bool>(*__seg_ & __mask_);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator<_Cp, true> operator&() const throw()
{return __bit_iterator<_Cp, true>(__seg_, static_cast<unsigned>(__ctz(__mask_)));}
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_const_reference(__storage_pointer __s, __storage_type __m) throw()
: __seg_(__s), __mask_(__m) {}
__bit_const_reference& operator=(const __bit_const_reference& __x);
};
template <class _Cp, bool _IsConst>
__bit_iterator<_Cp, _IsConst>
__find_bool_true(__bit_iterator<_Cp, _IsConst> __first, typename _Cp::size_type __n)
{
typedef __bit_iterator<_Cp, _IsConst> _It;
typedef typename _It::__storage_type __storage_type;
static const int __bits_per_word = _It::__bits_per_word;
if (__first.__ctz_ != 0)
{
__storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_);
__storage_type __dn = std::__1::min(__clz_f, __n);
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__storage_type __b = *__first.__seg_ & __m;
if (__b)
return _It(__first.__seg_, static_cast<unsigned>(std::__1::__ctz(__b)));
if (__n == __dn)
return __first + __n;
__n -= __dn;
++__first.__seg_;
}
for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word)
if (*__first.__seg_)
return _It(__first.__seg_, static_cast<unsigned>(std::__1::__ctz(*__first.__seg_)));
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b = *__first.__seg_ & __m;
if (__b)
return _It(__first.__seg_, static_cast<unsigned>(std::__1::__ctz(__b)));
}
return _It(__first.__seg_, static_cast<unsigned>(__n));
}
template <class _Cp, bool _IsConst>
__bit_iterator<_Cp, _IsConst>
__find_bool_false(__bit_iterator<_Cp, _IsConst> __first, typename _Cp::size_type __n)
{
typedef __bit_iterator<_Cp, _IsConst> _It;
typedef typename _It::__storage_type __storage_type;
const int __bits_per_word = _It::__bits_per_word;
if (__first.__ctz_ != 0)
{
__storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_);
__storage_type __dn = std::__1::min(__clz_f, __n);
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__storage_type __b = ~*__first.__seg_ & __m;
if (__b)
return _It(__first.__seg_, static_cast<unsigned>(std::__1::__ctz(__b)));
if (__n == __dn)
return __first + __n;
__n -= __dn;
++__first.__seg_;
}
for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word)
{
__storage_type __b = ~*__first.__seg_;
if (__b)
return _It(__first.__seg_, static_cast<unsigned>(std::__1::__ctz(__b)));
}
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b = ~*__first.__seg_ & __m;
if (__b)
return _It(__first.__seg_, static_cast<unsigned>(std::__1::__ctz(__b)));
}
return _It(__first.__seg_, static_cast<unsigned>(__n));
}
template <class _Cp, bool _IsConst, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator<_Cp, _IsConst>
find(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, const _Tp& __value_)
{
if (static_cast<bool>(__value_))
return __find_bool_true(__first, static_cast<typename _Cp::size_type>(__last - __first));
return __find_bool_false(__first, static_cast<typename _Cp::size_type>(__last - __first));
}
template <class _Cp, bool _IsConst>
typename __bit_iterator<_Cp, _IsConst>::difference_type
__count_bool_true(__bit_iterator<_Cp, _IsConst> __first, typename _Cp::size_type __n)
{
typedef __bit_iterator<_Cp, _IsConst> _It;
typedef typename _It::__storage_type __storage_type;
typedef typename _It::difference_type difference_type;
const int __bits_per_word = _It::__bits_per_word;
difference_type __r = 0;
if (__first.__ctz_ != 0)
{
__storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_);
__storage_type __dn = std::__1::min(__clz_f, __n);
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__r = std::__1::__pop_count(*__first.__seg_ & __m);
__n -= __dn;
++__first.__seg_;
}
for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word)
__r += std::__1::__pop_count(*__first.__seg_);
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__r += std::__1::__pop_count(*__first.__seg_ & __m);
}
return __r;
}
template <class _Cp, bool _IsConst>
typename __bit_iterator<_Cp, _IsConst>::difference_type
__count_bool_false(__bit_iterator<_Cp, _IsConst> __first, typename _Cp::size_type __n)
{
typedef __bit_iterator<_Cp, _IsConst> _It;
typedef typename _It::__storage_type __storage_type;
typedef typename _It::difference_type difference_type;
const int __bits_per_word = _It::__bits_per_word;
difference_type __r = 0;
if (__first.__ctz_ != 0)
{
__storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_);
__storage_type __dn = std::__1::min(__clz_f, __n);
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__r = std::__1::__pop_count(~*__first.__seg_ & __m);
__n -= __dn;
++__first.__seg_;
}
for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word)
__r += std::__1::__pop_count(~*__first.__seg_);
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__r += std::__1::__pop_count(~*__first.__seg_ & __m);
}
return __r;
}
template <class _Cp, bool _IsConst, class _Tp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
typename __bit_iterator<_Cp, _IsConst>::difference_type
count(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, const _Tp& __value_)
{
if (static_cast<bool>(__value_))
return __count_bool_true(__first, static_cast<typename _Cp::size_type>(__last - __first));
return __count_bool_false(__first, static_cast<typename _Cp::size_type>(__last - __first));
}
template <class _Cp>
void
__fill_n_false(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n)
{
typedef __bit_iterator<_Cp, false> _It;
typedef typename _It::__storage_type __storage_type;
const int __bits_per_word = _It::__bits_per_word;
if (__first.__ctz_ != 0)
{
__storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_);
__storage_type __dn = std::__1::min(__clz_f, __n);
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
*__first.__seg_ &= ~__m;
__n -= __dn;
++__first.__seg_;
}
__storage_type __nw = __n / __bits_per_word;
std::__1::memset(std::__1::__to_raw_pointer(__first.__seg_), 0, __nw * sizeof(__storage_type));
__n -= __nw * __bits_per_word;
if (__n > 0)
{
__first.__seg_ += __nw;
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
*__first.__seg_ &= ~__m;
}
}
template <class _Cp>
void
__fill_n_true(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n)
{
typedef __bit_iterator<_Cp, false> _It;
typedef typename _It::__storage_type __storage_type;
const int __bits_per_word = _It::__bits_per_word;
if (__first.__ctz_ != 0)
{
__storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_);
__storage_type __dn = std::__1::min(__clz_f, __n);
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
*__first.__seg_ |= __m;
__n -= __dn;
++__first.__seg_;
}
__storage_type __nw = __n / __bits_per_word;
std::__1::memset(std::__1::__to_raw_pointer(__first.__seg_), -1, __nw * sizeof(__storage_type));
__n -= __nw * __bits_per_word;
if (__n > 0)
{
__first.__seg_ += __nw;
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
*__first.__seg_ |= __m;
}
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n, bool __value_)
{
if (__n > 0)
{
if (__value_)
__fill_n_true(__first, __n);
else
__fill_n_false(__first, __n);
}
}
template <class _Cp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
fill(__bit_iterator<_Cp, false> __first, __bit_iterator<_Cp, false> __last, bool __value_)
{
std::__1::fill_n(__first, static_cast<typename _Cp::size_type>(__last - __first), __value_);
}
template <class _Cp, bool _IsConst>
__bit_iterator<_Cp, false>
__copy_aligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last,
__bit_iterator<_Cp, false> __result)
{
typedef __bit_iterator<_Cp, _IsConst> _In;
typedef typename _In::difference_type difference_type;
typedef typename _In::__storage_type __storage_type;
const int __bits_per_word = _In::__bits_per_word;
difference_type __n = __last - __first;
if (__n > 0)
{
if (__first.__ctz_ != 0)
{
unsigned __clz = __bits_per_word - __first.__ctz_;
difference_type __dn = std::__1::min(static_cast<difference_type>(__clz), __n);
__n -= __dn;
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz - __dn));
__storage_type __b = *__first.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b;
__result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word;
__result.__ctz_ = static_cast<unsigned>((__dn + __result.__ctz_) % __bits_per_word);
++__first.__seg_;
}
__storage_type __nw = __n / __bits_per_word;
std::__1::memmove(std::__1::__to_raw_pointer(__result.__seg_),
std::__1::__to_raw_pointer(__first.__seg_),
__nw * sizeof(__storage_type));
__n -= __nw * __bits_per_word;
__result.__seg_ += __nw;
if (__n > 0)
{
__first.__seg_ += __nw;
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b = *__first.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b;
__result.__ctz_ = static_cast<unsigned>(__n);
}
}
return __result;
}
template <class _Cp, bool _IsConst>
__bit_iterator<_Cp, false>
__copy_unaligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last,
__bit_iterator<_Cp, false> __result)
{
typedef __bit_iterator<_Cp, _IsConst> _In;
typedef typename _In::difference_type difference_type;
typedef typename _In::__storage_type __storage_type;
static const int __bits_per_word = _In::__bits_per_word;
difference_type __n = __last - __first;
if (__n > 0)
{
if (__first.__ctz_ != 0)
{
unsigned __clz_f = __bits_per_word - __first.__ctz_;
difference_type __dn = std::__1::min(static_cast<difference_type>(__clz_f), __n);
__n -= __dn;
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__storage_type __b = *__first.__seg_ & __m;
unsigned __clz_r = __bits_per_word - __result.__ctz_;
__storage_type __ddn = std::__1::min<__storage_type>(__dn, __clz_r);
__m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __ddn));
*__result.__seg_ &= ~__m;
if (__result.__ctz_ > __first.__ctz_)
*__result.__seg_ |= __b << (__result.__ctz_ - __first.__ctz_);
else
*__result.__seg_ |= __b >> (__first.__ctz_ - __result.__ctz_);
__result.__seg_ += (__ddn + __result.__ctz_) / __bits_per_word;
__result.__ctz_ = static_cast<unsigned>((__ddn + __result.__ctz_) % __bits_per_word);
__dn -= __ddn;
if (__dn > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __dn);
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b >> (__first.__ctz_ + __ddn);
__result.__ctz_ = static_cast<unsigned>(__dn);
}
++__first.__seg_;
}
unsigned __clz_r = __bits_per_word - __result.__ctz_;
__storage_type __m = ~__storage_type(0) << __result.__ctz_;
for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first.__seg_)
{
__storage_type __b = *__first.__seg_;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b << __result.__ctz_;
++__result.__seg_;
*__result.__seg_ &= __m;
*__result.__seg_ |= __b >> __clz_r;
}
if (__n > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b = *__first.__seg_ & __m;
__storage_type __dn = std::__1::min(__n, static_cast<difference_type>(__clz_r));
__m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __dn));
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b << __result.__ctz_;
__result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word;
__result.__ctz_ = static_cast<unsigned>((__dn + __result.__ctz_) % __bits_per_word);
__n -= __dn;
if (__n > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __n);
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b >> __dn;
__result.__ctz_ = static_cast<unsigned>(__n);
}
}
}
return __result;
}
template <class _Cp, bool _IsConst>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator<_Cp, false>
copy(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result)
{
if (__first.__ctz_ == __result.__ctz_)
return __copy_aligned(__first, __last, __result);
return __copy_unaligned(__first, __last, __result);
}
template <class _Cp, bool _IsConst>
__bit_iterator<_Cp, false>
__copy_backward_aligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last,
__bit_iterator<_Cp, false> __result)
{
typedef __bit_iterator<_Cp, _IsConst> _In;
typedef typename _In::difference_type difference_type;
typedef typename _In::__storage_type __storage_type;
const int __bits_per_word = _In::__bits_per_word;
difference_type __n = __last - __first;
if (__n > 0)
{
if (__last.__ctz_ != 0)
{
difference_type __dn = std::__1::min(static_cast<difference_type>(__last.__ctz_), __n);
__n -= __dn;
unsigned __clz = __bits_per_word - __last.__ctz_;
__storage_type __m = (~__storage_type(0) << (__last.__ctz_ - __dn)) & (~__storage_type(0) >> __clz);
__storage_type __b = *__last.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b;
__result.__ctz_ = static_cast<unsigned>(((-__dn & (__bits_per_word - 1)) +
__result.__ctz_) % __bits_per_word);
}
__storage_type __nw = __n / __bits_per_word;
__result.__seg_ -= __nw;
__last.__seg_ -= __nw;
std::__1::memmove(std::__1::__to_raw_pointer(__result.__seg_),
std::__1::__to_raw_pointer(__last.__seg_),
__nw * sizeof(__storage_type));
__n -= __nw * __bits_per_word;
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) << (__bits_per_word - __n);
__storage_type __b = *--__last.__seg_ & __m;
*--__result.__seg_ &= ~__m;
*__result.__seg_ |= __b;
__result.__ctz_ = static_cast<unsigned>(-__n & (__bits_per_word - 1));
}
}
return __result;
}
template <class _Cp, bool _IsConst>
__bit_iterator<_Cp, false>
__copy_backward_unaligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last,
__bit_iterator<_Cp, false> __result)
{
typedef __bit_iterator<_Cp, _IsConst> _In;
typedef typename _In::difference_type difference_type;
typedef typename _In::__storage_type __storage_type;
const int __bits_per_word = _In::__bits_per_word;
difference_type __n = __last - __first;
if (__n > 0)
{
if (__last.__ctz_ != 0)
{
difference_type __dn = std::__1::min(static_cast<difference_type>(__last.__ctz_), __n);
__n -= __dn;
unsigned __clz_l = __bits_per_word - __last.__ctz_;
__storage_type __m = (~__storage_type(0) << (__last.__ctz_ - __dn)) & (~__storage_type(0) >> __clz_l);
__storage_type __b = *__last.__seg_ & __m;
unsigned __clz_r = __bits_per_word - __result.__ctz_;
__storage_type __ddn = std::__1::min(__dn, static_cast<difference_type>(__result.__ctz_));
if (__ddn > 0)
{
__m = (~__storage_type(0) << (__result.__ctz_ - __ddn)) & (~__storage_type(0) >> __clz_r);
*__result.__seg_ &= ~__m;
if (__result.__ctz_ > __last.__ctz_)
*__result.__seg_ |= __b << (__result.__ctz_ - __last.__ctz_);
else
*__result.__seg_ |= __b >> (__last.__ctz_ - __result.__ctz_);
__result.__ctz_ = static_cast<unsigned>(((-__ddn & (__bits_per_word - 1)) +
__result.__ctz_) % __bits_per_word);
__dn -= __ddn;
}
if (__dn > 0)
{
--__result.__seg_;
__result.__ctz_ = static_cast<unsigned>(-__dn & (__bits_per_word - 1));
__m = ~__storage_type(0) << __result.__ctz_;
*__result.__seg_ &= ~__m;
__last.__ctz_ -= __dn + __ddn;
*__result.__seg_ |= __b << (__result.__ctz_ - __last.__ctz_);
}
}
unsigned __clz_r = __bits_per_word - __result.__ctz_;
__storage_type __m = ~__storage_type(0) >> __clz_r;
for (; __n >= __bits_per_word; __n -= __bits_per_word)
{
__storage_type __b = *--__last.__seg_;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b >> __clz_r;
*--__result.__seg_ &= __m;
*__result.__seg_ |= __b << __result.__ctz_;
}
if (__n > 0)
{
__m = ~__storage_type(0) << (__bits_per_word - __n);
__storage_type __b = *--__last.__seg_ & __m;
__clz_r = __bits_per_word - __result.__ctz_;
__storage_type __dn = std::__1::min(__n, static_cast<difference_type>(__result.__ctz_));
__m = (~__storage_type(0) << (__result.__ctz_ - __dn)) & (~__storage_type(0) >> __clz_r);
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b >> (__bits_per_word - __result.__ctz_);
__result.__ctz_ = static_cast<unsigned>(((-__dn & (__bits_per_word - 1)) +
__result.__ctz_) % __bits_per_word);
__n -= __dn;
if (__n > 0)
{
--__result.__seg_;
__result.__ctz_ = static_cast<unsigned>(-__n & (__bits_per_word - 1));
__m = ~__storage_type(0) << __result.__ctz_;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b << (__result.__ctz_ - (__bits_per_word - __n - __dn));
}
}
}
return __result;
}
template <class _Cp, bool _IsConst>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator<_Cp, false>
copy_backward(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result)
{
if (__last.__ctz_ == __result.__ctz_)
return __copy_backward_aligned(__first, __last, __result);
return __copy_backward_unaligned(__first, __last, __result);
}
template <class _Cp, bool _IsConst>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator<_Cp, false>
move(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result)
{
return std::__1::copy(__first, __last, __result);
}
template <class _Cp, bool _IsConst>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator<_Cp, false>
move_backward(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result)
{
return std::__1::copy_backward(__first, __last, __result);
}
template <class __C1, class __C2>
__bit_iterator<__C2, false>
__swap_ranges_aligned(__bit_iterator<__C1, false> __first, __bit_iterator<__C1, false> __last,
__bit_iterator<__C2, false> __result)
{
typedef __bit_iterator<__C1, false> _I1;
typedef typename _I1::difference_type difference_type;
typedef typename _I1::__storage_type __storage_type;
const int __bits_per_word = _I1::__bits_per_word;
difference_type __n = __last - __first;
if (__n > 0)
{
if (__first.__ctz_ != 0)
{
unsigned __clz = __bits_per_word - __first.__ctz_;
difference_type __dn = std::__1::min(static_cast<difference_type>(__clz), __n);
__n -= __dn;
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz - __dn));
__storage_type __b1 = *__first.__seg_ & __m;
*__first.__seg_ &= ~__m;
__storage_type __b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b1;
*__first.__seg_ |= __b2;
__result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word;
__result.__ctz_ = static_cast<unsigned>((__dn + __result.__ctz_) % __bits_per_word);
++__first.__seg_;
}
for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first.__seg_, ++__result.__seg_)
swap(*__first.__seg_, *__result.__seg_);
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b1 = *__first.__seg_ & __m;
*__first.__seg_ &= ~__m;
__storage_type __b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b1;
*__first.__seg_ |= __b2;
__result.__ctz_ = static_cast<unsigned>(__n);
}
}
return __result;
}
template <class __C1, class __C2>
__bit_iterator<__C2, false>
__swap_ranges_unaligned(__bit_iterator<__C1, false> __first, __bit_iterator<__C1, false> __last,
__bit_iterator<__C2, false> __result)
{
typedef __bit_iterator<__C1, false> _I1;
typedef typename _I1::difference_type difference_type;
typedef typename _I1::__storage_type __storage_type;
const int __bits_per_word = _I1::__bits_per_word;
difference_type __n = __last - __first;
if (__n > 0)
{
if (__first.__ctz_ != 0)
{
unsigned __clz_f = __bits_per_word - __first.__ctz_;
difference_type __dn = std::__1::min(static_cast<difference_type>(__clz_f), __n);
__n -= __dn;
__storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__storage_type __b1 = *__first.__seg_ & __m;
*__first.__seg_ &= ~__m;
unsigned __clz_r = __bits_per_word - __result.__ctz_;
__storage_type __ddn = std::__1::min<__storage_type>(__dn, __clz_r);
__m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __ddn));
__storage_type __b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
if (__result.__ctz_ > __first.__ctz_)
{
unsigned __s = __result.__ctz_ - __first.__ctz_;
*__result.__seg_ |= __b1 << __s;
*__first.__seg_ |= __b2 >> __s;
}
else
{
unsigned __s = __first.__ctz_ - __result.__ctz_;
*__result.__seg_ |= __b1 >> __s;
*__first.__seg_ |= __b2 << __s;
}
__result.__seg_ += (__ddn + __result.__ctz_) / __bits_per_word;
__result.__ctz_ = static_cast<unsigned>((__ddn + __result.__ctz_) % __bits_per_word);
__dn -= __ddn;
if (__dn > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __dn);
__b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
unsigned __s = __first.__ctz_ + __ddn;
*__result.__seg_ |= __b1 >> __s;
*__first.__seg_ |= __b2 << __s;
__result.__ctz_ = static_cast<unsigned>(__dn);
}
++__first.__seg_;
}
__storage_type __m = ~__storage_type(0) << __result.__ctz_;
unsigned __clz_r = __bits_per_word - __result.__ctz_;
for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first.__seg_)
{
__storage_type __b1 = *__first.__seg_;
__storage_type __b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b1 << __result.__ctz_;
*__first.__seg_ = __b2 >> __result.__ctz_;
++__result.__seg_;
__b2 = *__result.__seg_ & ~__m;
*__result.__seg_ &= __m;
*__result.__seg_ |= __b1 >> __clz_r;
*__first.__seg_ |= __b2 << __clz_r;
}
if (__n > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b1 = *__first.__seg_ & __m;
*__first.__seg_ &= ~__m;
__storage_type __dn = std::__1::min<__storage_type>(__n, __clz_r);
__m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __dn));
__storage_type __b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b1 << __result.__ctz_;
*__first.__seg_ |= __b2 >> __result.__ctz_;
__result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word;
__result.__ctz_ = static_cast<unsigned>((__dn + __result.__ctz_) % __bits_per_word);
__n -= __dn;
if (__n > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __n);
__b2 = *__result.__seg_ & __m;
*__result.__seg_ &= ~__m;
*__result.__seg_ |= __b1 >> __dn;
*__first.__seg_ |= __b2 << __dn;
__result.__ctz_ = static_cast<unsigned>(__n);
}
}
}
return __result;
}
template <class __C1, class __C2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator<__C2, false>
swap_ranges(__bit_iterator<__C1, false> __first1, __bit_iterator<__C1, false> __last1,
__bit_iterator<__C2, false> __first2)
{
if (__first1.__ctz_ == __first2.__ctz_)
return __swap_ranges_aligned(__first1, __last1, __first2);
return __swap_ranges_unaligned(__first1, __last1, __first2);
}
template <class _Cp>
struct __bit_array
{
typedef typename _Cp::difference_type difference_type;
typedef typename _Cp::__storage_type __storage_type;
typedef typename _Cp::__storage_pointer __storage_pointer;
typedef typename _Cp::iterator iterator;
static const unsigned __bits_per_word = _Cp::__bits_per_word;
static const unsigned _Np = 4;
difference_type __size_;
__storage_type __word_[_Np];
__attribute__ ((__visibility__("hidden"), __always_inline__)) static difference_type capacity()
{return static_cast<difference_type>(_Np * __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) explicit __bit_array(difference_type __s) : __size_(__s) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iterator begin()
{
return iterator(pointer_traits<__storage_pointer>::pointer_to(__word_[0]), 0);
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iterator end()
{
return iterator(pointer_traits<__storage_pointer>::pointer_to(__word_[0]) + __size_ / __bits_per_word,
static_cast<unsigned>(__size_ % __bits_per_word));
}
};
template <class _Cp>
__bit_iterator<_Cp, false>
rotate(__bit_iterator<_Cp, false> __first, __bit_iterator<_Cp, false> __middle, __bit_iterator<_Cp, false> __last)
{
typedef __bit_iterator<_Cp, false> _I1;
typedef typename _I1::difference_type difference_type;
difference_type __d1 = __middle - __first;
difference_type __d2 = __last - __middle;
_I1 __r = __first + __d2;
while (__d1 != 0 && __d2 != 0)
{
if (__d1 <= __d2)
{
if (__d1 <= __bit_array<_Cp>::capacity())
{
__bit_array<_Cp> __b(__d1);
std::__1::copy(__first, __middle, __b.begin());
std::__1::copy(__b.begin(), __b.end(), std::__1::copy(__middle, __last, __first));
break;
}
else
{
__bit_iterator<_Cp, false> __mp = std::__1::swap_ranges(__first, __middle, __middle);
__first = __middle;
__middle = __mp;
__d2 -= __d1;
}
}
else
{
if (__d2 <= __bit_array<_Cp>::capacity())
{
__bit_array<_Cp> __b(__d2);
std::__1::copy(__middle, __last, __b.begin());
std::__1::copy_backward(__b.begin(), __b.end(), std::__1::copy_backward(__first, __middle, __last));
break;
}
else
{
__bit_iterator<_Cp, false> __mp = __first + __d2;
std::__1::swap_ranges(__first, __mp, __middle);
__first = __mp;
__d1 -= __d2;
}
}
}
return __r;
}
template <class _Cp, bool _IC1, bool _IC2>
bool
__equal_unaligned(__bit_iterator<_Cp, _IC1> __first1, __bit_iterator<_Cp, _IC1> __last1,
__bit_iterator<_Cp, _IC2> __first2)
{
typedef __bit_iterator<_Cp, _IC1> _It;
typedef typename _It::difference_type difference_type;
typedef typename _It::__storage_type __storage_type;
static const int __bits_per_word = _It::__bits_per_word;
difference_type __n = __last1 - __first1;
if (__n > 0)
{
if (__first1.__ctz_ != 0)
{
unsigned __clz_f = __bits_per_word - __first1.__ctz_;
difference_type __dn = std::__1::min(static_cast<difference_type>(__clz_f), __n);
__n -= __dn;
__storage_type __m = (~__storage_type(0) << __first1.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn));
__storage_type __b = *__first1.__seg_ & __m;
unsigned __clz_r = __bits_per_word - __first2.__ctz_;
__storage_type __ddn = std::__1::min<__storage_type>(__dn, __clz_r);
__m = (~__storage_type(0) << __first2.__ctz_) & (~__storage_type(0) >> (__clz_r - __ddn));
if (__first2.__ctz_ > __first1.__ctz_)
{
if ((*__first2.__seg_ & __m) != (__b << (__first2.__ctz_ - __first1.__ctz_)))
return false;
}
else
{
if ((*__first2.__seg_ & __m) != (__b >> (__first1.__ctz_ - __first2.__ctz_)))
return false;
}
__first2.__seg_ += (__ddn + __first2.__ctz_) / __bits_per_word;
__first2.__ctz_ = static_cast<unsigned>((__ddn + __first2.__ctz_) % __bits_per_word);
__dn -= __ddn;
if (__dn > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __dn);
if ((*__first2.__seg_ & __m) != (__b >> (__first1.__ctz_ + __ddn)))
return false;
__first2.__ctz_ = static_cast<unsigned>(__dn);
}
++__first1.__seg_;
}
unsigned __clz_r = __bits_per_word - __first2.__ctz_;
__storage_type __m = ~__storage_type(0) << __first2.__ctz_;
for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first1.__seg_)
{
__storage_type __b = *__first1.__seg_;
if ((*__first2.__seg_ & __m) != (__b << __first2.__ctz_))
return false;
++__first2.__seg_;
if ((*__first2.__seg_ & ~__m) != (__b >> __clz_r))
return false;
}
if (__n > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b = *__first1.__seg_ & __m;
__storage_type __dn = std::__1::min(__n, static_cast<difference_type>(__clz_r));
__m = (~__storage_type(0) << __first2.__ctz_) & (~__storage_type(0) >> (__clz_r - __dn));
if ((*__first2.__seg_ & __m) != (__b << __first2.__ctz_))
return false;
__first2.__seg_ += (__dn + __first2.__ctz_) / __bits_per_word;
__first2.__ctz_ = static_cast<unsigned>((__dn + __first2.__ctz_) % __bits_per_word);
__n -= __dn;
if (__n > 0)
{
__m = ~__storage_type(0) >> (__bits_per_word - __n);
if ((*__first2.__seg_ & __m) != (__b >> __dn))
return false;
}
}
}
return true;
}
template <class _Cp, bool _IC1, bool _IC2>
bool
__equal_aligned(__bit_iterator<_Cp, _IC1> __first1, __bit_iterator<_Cp, _IC1> __last1,
__bit_iterator<_Cp, _IC2> __first2)
{
typedef __bit_iterator<_Cp, _IC1> _It;
typedef typename _It::difference_type difference_type;
typedef typename _It::__storage_type __storage_type;
static const int __bits_per_word = _It::__bits_per_word;
difference_type __n = __last1 - __first1;
if (__n > 0)
{
if (__first1.__ctz_ != 0)
{
unsigned __clz = __bits_per_word - __first1.__ctz_;
difference_type __dn = std::__1::min(static_cast<difference_type>(__clz), __n);
__n -= __dn;
__storage_type __m = (~__storage_type(0) << __first1.__ctz_) & (~__storage_type(0) >> (__clz - __dn));
if ((*__first2.__seg_ & __m) != (*__first1.__seg_ & __m))
return false;
++__first2.__seg_;
++__first1.__seg_;
}
for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first1.__seg_, ++__first2.__seg_)
if (*__first2.__seg_ != *__first1.__seg_)
return false;
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
if ((*__first2.__seg_ & __m) != (*__first1.__seg_ & __m))
return false;
}
}
return true;
}
template <class _Cp, bool _IC1, bool _IC2>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bool
equal(__bit_iterator<_Cp, _IC1> __first1, __bit_iterator<_Cp, _IC1> __last1, __bit_iterator<_Cp, _IC2> __first2)
{
if (__first1.__ctz_ == __first2.__ctz_)
return __equal_aligned(__first1, __last1, __first2);
return __equal_unaligned(__first1, __last1, __first2);
}
template <class _Cp, bool _IsConst,
typename _Cp::__storage_type>
class __bit_iterator
{
public:
typedef typename _Cp::difference_type difference_type;
typedef bool value_type;
typedef __bit_iterator pointer;
typedef typename conditional<_IsConst, __bit_const_reference<_Cp>, __bit_reference<_Cp> >::type reference;
typedef random_access_iterator_tag iterator_category;
private:
typedef typename _Cp::__storage_type __storage_type;
typedef typename conditional<_IsConst, typename _Cp::__const_storage_pointer,
typename _Cp::__storage_pointer>::type __storage_pointer;
static const unsigned __bits_per_word = _Cp::__bits_per_word;
__storage_pointer __seg_;
unsigned __ctz_;
public:
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator() throw()
{}
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator(const __bit_iterator<_Cp, false>& __it) throw()
: __seg_(__it.__seg_), __ctz_(__it.__ctz_) {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference operator*() const throw()
{return reference(__seg_, __storage_type(1) << __ctz_);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator& operator++()
{
if (__ctz_ != __bits_per_word-1)
++__ctz_;
else
{
__ctz_ = 0;
++__seg_;
}
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator operator++(int)
{
__bit_iterator __tmp = *this;
++(*this);
return __tmp;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator& operator--()
{
if (__ctz_ != 0)
--__ctz_;
else
{
__ctz_ = __bits_per_word - 1;
--__seg_;
}
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator operator--(int)
{
__bit_iterator __tmp = *this;
--(*this);
return __tmp;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator& operator+=(difference_type __n)
{
if (__n >= 0)
__seg_ += (__n + __ctz_) / __bits_per_word;
else
__seg_ += static_cast<difference_type>(__n - __bits_per_word + __ctz_ + 1)
/ static_cast<difference_type>(__bits_per_word);
__n &= (__bits_per_word - 1);
__ctz_ = static_cast<unsigned>((__n + __ctz_) % __bits_per_word);
return *this;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator& operator-=(difference_type __n)
{
return *this += -__n;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator operator+(difference_type __n) const
{
__bit_iterator __t(*this);
__t += __n;
return __t;
}
__attribute__ ((__visibility__("hidden"), __always_inline__)) __bit_iterator operator-(difference_type __n) const
{
__bit_iterator __t(*this);
__t -= __n;
return __t;
}
__attribute__ ((__visibility__("hidden"), __always_inline__))
friend __bit_iterator operator+(difference_type __n, const __bit_iterator& __it) {return __it + __n;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
friend difference_type operator-(const __bit_iterator& __x, const __bit_iterator& __y)
{return (__x.__seg_ - __y.__seg_) * __bits_per_word + __x.__ctz_ - __y.__ctz_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference operator[](difference_type __n) const {return *(*this + __n);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) friend bool operator==(const __bit_iterator& __x, const __bit_iterator& __y)
{return __x.__seg_ == __y.__seg_ && __x.__ctz_ == __y.__ctz_;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) friend bool operator!=(const __bit_iterator& __x, const __bit_iterator& __y)
{return !(__x == __y);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) friend bool operator<(const __bit_iterator& __x, const __bit_iterator& __y)
{return __x.__seg_ < __y.__seg_ || (__x.__seg_ == __y.__seg_ && __x.__ctz_ < __y.__ctz_);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) friend bool operator>(const __bit_iterator& __x, const __bit_iterator& __y)
{return __y < __x;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) friend bool operator<=(const __bit_iterator& __x, const __bit_iterator& __y)
{return !(__y < __x);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) friend bool operator>=(const __bit_iterator& __x, const __bit_iterator& __y)
{return !(__x < __y);}
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bit_iterator(__storage_pointer __s, unsigned __ctz) throw()
: __seg_(__s), __ctz_(__ctz) {}
friend typename _Cp::__self;
friend class __bit_reference<_Cp>;
friend class __bit_const_reference<_Cp>;
friend class __bit_iterator<_Cp, true>;
template <class _Dp> friend struct __bit_array;
template <class _Dp> friend void __fill_n_false(__bit_iterator<_Dp, false> __first, typename _Dp::size_type __n);
template <class _Dp> friend void __fill_n_true(__bit_iterator<_Dp, false> __first, typename _Dp::size_type __n);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, false> __copy_aligned(__bit_iterator<_Dp, _IC> __first,
__bit_iterator<_Dp, _IC> __last,
__bit_iterator<_Dp, false> __result);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, false> __copy_unaligned(__bit_iterator<_Dp, _IC> __first,
__bit_iterator<_Dp, _IC> __last,
__bit_iterator<_Dp, false> __result);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, false> copy(__bit_iterator<_Dp, _IC> __first,
__bit_iterator<_Dp, _IC> __last,
__bit_iterator<_Dp, false> __result);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, false> __copy_backward_aligned(__bit_iterator<_Dp, _IC> __first,
__bit_iterator<_Dp, _IC> __last,
__bit_iterator<_Dp, false> __result);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, false> __copy_backward_unaligned(__bit_iterator<_Dp, _IC> __first,
__bit_iterator<_Dp, _IC> __last,
__bit_iterator<_Dp, false> __result);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, false> copy_backward(__bit_iterator<_Dp, _IC> __first,
__bit_iterator<_Dp, _IC> __last,
__bit_iterator<_Dp, false> __result);
template <class __C1, class __C2>friend __bit_iterator<__C2, false> __swap_ranges_aligned(__bit_iterator<__C1, false>,
__bit_iterator<__C1, false>,
__bit_iterator<__C2, false>);
template <class __C1, class __C2>friend __bit_iterator<__C2, false> __swap_ranges_unaligned(__bit_iterator<__C1, false>,
__bit_iterator<__C1, false>,
__bit_iterator<__C2, false>);
template <class __C1, class __C2>friend __bit_iterator<__C2, false> swap_ranges(__bit_iterator<__C1, false>,
__bit_iterator<__C1, false>,
__bit_iterator<__C2, false>);
template <class _Dp> friend __bit_iterator<_Dp, false> rotate(__bit_iterator<_Dp, false>,
__bit_iterator<_Dp, false>,
__bit_iterator<_Dp, false>);
template <class _Dp, bool _IC1, bool _IC2> friend bool __equal_aligned(__bit_iterator<_Dp, _IC1>,
__bit_iterator<_Dp, _IC1>,
__bit_iterator<_Dp, _IC2>);
template <class _Dp, bool _IC1, bool _IC2> friend bool __equal_unaligned(__bit_iterator<_Dp, _IC1>,
__bit_iterator<_Dp, _IC1>,
__bit_iterator<_Dp, _IC2>);
template <class _Dp, bool _IC1, bool _IC2> friend bool equal(__bit_iterator<_Dp, _IC1>,
__bit_iterator<_Dp, _IC1>,
__bit_iterator<_Dp, _IC2>);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, _IC> __find_bool_true(__bit_iterator<_Dp, _IC>,
typename _Dp::size_type);
template <class _Dp, bool _IC> friend __bit_iterator<_Dp, _IC> __find_bool_false(__bit_iterator<_Dp, _IC>,
typename _Dp::size_type);
template <class _Dp, bool _IC> friend typename __bit_iterator<_Dp, _IC>::difference_type
__count_bool_true(__bit_iterator<_Dp, _IC>, typename _Dp::size_type);
template <class _Dp, bool _IC> friend typename __bit_iterator<_Dp, _IC>::difference_type
__count_bool_false(__bit_iterator<_Dp, _IC>, typename _Dp::size_type);
};
} }
# 118 "/Library/Developer/CommandLineTools/usr/include/c++/v1/bitset" 2 3
# 127 "/Library/Developer/CommandLineTools/usr/include/c++/v1/bitset" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 131 "/Library/Developer/CommandLineTools/usr/include/c++/v1/bitset" 2 3
namespace std {inline namespace __1 {
template <size_t _N_words, size_t _Size>
class __bitset;
template <size_t _N_words, size_t _Size>
struct __has_storage_type<__bitset<_N_words, _Size> >
{
static const bool value = true;
};
template <size_t _N_words, size_t _Size>
class __bitset
{
public:
typedef ptrdiff_t difference_type;
typedef size_t size_type;
typedef size_type __storage_type;
protected:
typedef __bitset __self;
typedef __storage_type* __storage_pointer;
typedef const __storage_type* __const_storage_pointer;
static const unsigned __bits_per_word = static_cast<unsigned>(sizeof(__storage_type) * 8);
friend class __bit_reference<__bitset>;
friend class __bit_const_reference<__bitset>;
friend class __bit_iterator<__bitset, false>;
friend class __bit_iterator<__bitset, true>;
friend struct __bit_array<__bitset>;
__storage_type __first_[_N_words];
typedef __bit_reference<__bitset> reference;
typedef __bit_const_reference<__bitset> const_reference;
typedef __bit_iterator<__bitset, false> iterator;
typedef __bit_iterator<__bitset, true> const_iterator;
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bitset() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __bitset(unsigned long long __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference __make_ref(size_t __pos) throw()
{return reference(__first_ + __pos / __bits_per_word, __storage_type(1) << __pos % __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_reference __make_ref(size_t __pos) const throw()
{return const_reference(__first_ + __pos / __bits_per_word, __storage_type(1) << __pos % __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iterator __make_iter(size_t __pos) throw()
{return iterator(__first_ + __pos / __bits_per_word, __pos % __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_iterator __make_iter(size_t __pos) const throw()
{return const_iterator(__first_ + __pos / __bits_per_word, __pos % __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator&=(const __bitset& __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator|=(const __bitset& __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator^=(const __bitset& __v) throw();
void flip() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) unsigned long to_ulong() const
{return to_ulong(integral_constant<bool, _Size < sizeof(unsigned long) * 8>());}
__attribute__ ((__visibility__("hidden"), __always_inline__)) unsigned long long to_ullong() const
{return to_ullong(integral_constant<bool, _Size < sizeof(unsigned long long) * 8>());}
bool all() const throw();
bool any() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t __hash_code() const throw();
private:
void __init(unsigned long long __v, false_type) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void __init(unsigned long long __v, true_type) throw();
unsigned long to_ulong(false_type) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long to_ulong(true_type) const;
unsigned long long to_ullong(false_type) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long to_ullong(true_type) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long to_ullong(true_type, false_type) const;
unsigned long long to_ullong(true_type, true_type) const;
};
template <size_t _N_words, size_t _Size>
inline
__bitset<_N_words, _Size>::__bitset() throw()
{
std::__1::fill_n(__first_, _N_words, __storage_type(0));
}
template <size_t _N_words, size_t _Size>
void
__bitset<_N_words, _Size>::__init(unsigned long long __v, false_type) throw()
{
__storage_type __t[sizeof(unsigned long long) / sizeof(__storage_type)];
size_t __sz = _Size;
for (size_t __i = 0; __i < sizeof(__t)/sizeof(__t[0]); ++__i, __v >>= __bits_per_word, __sz -= __bits_per_word )
if ( __sz < __bits_per_word)
__t[__i] = static_cast<__storage_type>(__v) & ( 1ULL << __sz ) - 1;
else
__t[__i] = static_cast<__storage_type>(__v);
std::__1::copy(__t, __t + sizeof(__t)/sizeof(__t[0]), __first_);
std::__1::fill(__first_ + sizeof(__t)/sizeof(__t[0]), __first_ + sizeof(__first_)/sizeof(__first_[0]),
__storage_type(0));
}
template <size_t _N_words, size_t _Size>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
__bitset<_N_words, _Size>::__init(unsigned long long __v, true_type) throw()
{
__first_[0] = __v;
if (_Size < __bits_per_word)
__first_[0] &= ( 1ULL << _Size ) - 1;
std::__1::fill(__first_ + 1, __first_ + sizeof(__first_)/sizeof(__first_[0]), __storage_type(0));
}
template <size_t _N_words, size_t _Size>
inline
__bitset<_N_words, _Size>::__bitset(unsigned long long __v) throw()
# 279 "/Library/Developer/CommandLineTools/usr/include/c++/v1/bitset" 3
{
__init(__v, integral_constant<bool, sizeof(unsigned long long) == sizeof(__storage_type)>());
}
template <size_t _N_words, size_t _Size>
inline
void
__bitset<_N_words, _Size>::operator&=(const __bitset& __v) throw()
{
for (size_type __i = 0; __i < _N_words; ++__i)
__first_[__i] &= __v.__first_[__i];
}
template <size_t _N_words, size_t _Size>
inline
void
__bitset<_N_words, _Size>::operator|=(const __bitset& __v) throw()
{
for (size_type __i = 0; __i < _N_words; ++__i)
__first_[__i] |= __v.__first_[__i];
}
template <size_t _N_words, size_t _Size>
inline
void
__bitset<_N_words, _Size>::operator^=(const __bitset& __v) throw()
{
for (size_type __i = 0; __i < _N_words; ++__i)
__first_[__i] ^= __v.__first_[__i];
}
template <size_t _N_words, size_t _Size>
void
__bitset<_N_words, _Size>::flip() throw()
{
size_type __n = _Size;
__storage_pointer __p = __first_;
for (; __n >= __bits_per_word; ++__p, __n -= __bits_per_word)
*__p = ~*__p;
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
__storage_type __b = *__p & __m;
*__p &= ~__m;
*__p |= ~__b & __m;
}
}
template <size_t _N_words, size_t _Size>
unsigned long
__bitset<_N_words, _Size>::to_ulong(false_type) const
{
const_iterator __e = __make_iter(_Size);
const_iterator __i = std::__1::find(__make_iter(sizeof(unsigned long) * 8), __e, true);
if (__i != __e)
__throw_overflow_error("bitset to_ulong overflow error");
return __first_[0];
}
template <size_t _N_words, size_t _Size>
inline
unsigned long
__bitset<_N_words, _Size>::to_ulong(true_type) const
{
return __first_[0];
}
template <size_t _N_words, size_t _Size>
unsigned long long
__bitset<_N_words, _Size>::to_ullong(false_type) const
{
const_iterator __e = __make_iter(_Size);
const_iterator __i = std::__1::find(__make_iter(sizeof(unsigned long long) * 8), __e, true);
if (__i != __e)
__throw_overflow_error("bitset to_ullong overflow error");
return to_ullong(true_type());
}
template <size_t _N_words, size_t _Size>
inline
unsigned long long
__bitset<_N_words, _Size>::to_ullong(true_type) const
{
return to_ullong(true_type(), integral_constant<bool, sizeof(__storage_type) < sizeof(unsigned long long)>());
}
template <size_t _N_words, size_t _Size>
inline
unsigned long long
__bitset<_N_words, _Size>::to_ullong(true_type, false_type) const
{
return __first_[0];
}
template <size_t _N_words, size_t _Size>
unsigned long long
__bitset<_N_words, _Size>::to_ullong(true_type, true_type) const
{
unsigned long long __r = __first_[0];
for (std::size_t __i = 1; __i < sizeof(unsigned long long) / sizeof(__storage_type); ++__i)
__r |= static_cast<unsigned long long>(__first_[__i]) << (sizeof(__storage_type) * 8);
return __r;
}
template <size_t _N_words, size_t _Size>
bool
__bitset<_N_words, _Size>::all() const throw()
{
size_type __n = _Size;
__const_storage_pointer __p = __first_;
for (; __n >= __bits_per_word; ++__p, __n -= __bits_per_word)
if (~*__p)
return false;
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
if (~*__p & __m)
return false;
}
return true;
}
template <size_t _N_words, size_t _Size>
bool
__bitset<_N_words, _Size>::any() const throw()
{
size_type __n = _Size;
__const_storage_pointer __p = __first_;
for (; __n >= __bits_per_word; ++__p, __n -= __bits_per_word)
if (*__p)
return true;
if (__n > 0)
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n);
if (*__p & __m)
return true;
}
return false;
}
template <size_t _N_words, size_t _Size>
inline
size_t
__bitset<_N_words, _Size>::__hash_code() const throw()
{
size_t __h = 0;
for (size_type __i = 0; __i < _N_words; ++__i)
__h ^= __first_[__i];
return __h;
}
template <size_t _Size>
class __bitset<1, _Size>
{
public:
typedef ptrdiff_t difference_type;
typedef size_t size_type;
typedef size_type __storage_type;
protected:
typedef __bitset __self;
typedef __storage_type* __storage_pointer;
typedef const __storage_type* __const_storage_pointer;
static const unsigned __bits_per_word = static_cast<unsigned>(sizeof(__storage_type) * 8);
friend class __bit_reference<__bitset>;
friend class __bit_const_reference<__bitset>;
friend class __bit_iterator<__bitset, false>;
friend class __bit_iterator<__bitset, true>;
friend struct __bit_array<__bitset>;
__storage_type __first_;
typedef __bit_reference<__bitset> reference;
typedef __bit_const_reference<__bitset> const_reference;
typedef __bit_iterator<__bitset, false> iterator;
typedef __bit_iterator<__bitset, true> const_iterator;
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bitset() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __bitset(unsigned long long __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference __make_ref(size_t __pos) throw()
{return reference(&__first_, __storage_type(1) << __pos);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_reference __make_ref(size_t __pos) const throw()
{return const_reference(&__first_, __storage_type(1) << __pos);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iterator __make_iter(size_t __pos) throw()
{return iterator(&__first_ + __pos / __bits_per_word, __pos % __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_iterator __make_iter(size_t __pos) const throw()
{return const_iterator(&__first_ + __pos / __bits_per_word, __pos % __bits_per_word);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator&=(const __bitset& __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator|=(const __bitset& __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void operator^=(const __bitset& __v) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
void flip() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long to_ulong() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long to_ullong() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool all() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool any() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t __hash_code() const throw();
};
template <size_t _Size>
inline
__bitset<1, _Size>::__bitset() throw()
: __first_(0)
{
}
template <size_t _Size>
inline
__bitset<1, _Size>::__bitset(unsigned long long __v) throw()
: __first_(
_Size == __bits_per_word ? static_cast<__storage_type>(__v)
: static_cast<__storage_type>(__v) & ((__storage_type(1) << _Size) - 1)
)
{
}
template <size_t _Size>
inline
void
__bitset<1, _Size>::operator&=(const __bitset& __v) throw()
{
__first_ &= __v.__first_;
}
template <size_t _Size>
inline
void
__bitset<1, _Size>::operator|=(const __bitset& __v) throw()
{
__first_ |= __v.__first_;
}
template <size_t _Size>
inline
void
__bitset<1, _Size>::operator^=(const __bitset& __v) throw()
{
__first_ ^= __v.__first_;
}
template <size_t _Size>
inline
void
__bitset<1, _Size>::flip() throw()
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - _Size);
__first_ = ~__first_;
__first_ &= __m;
}
template <size_t _Size>
inline
unsigned long
__bitset<1, _Size>::to_ulong() const
{
return __first_;
}
template <size_t _Size>
inline
unsigned long long
__bitset<1, _Size>::to_ullong() const
{
return __first_;
}
template <size_t _Size>
inline
bool
__bitset<1, _Size>::all() const throw()
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - _Size);
return !(~__first_ & __m);
}
template <size_t _Size>
inline
bool
__bitset<1, _Size>::any() const throw()
{
__storage_type __m = ~__storage_type(0) >> (__bits_per_word - _Size);
return __first_ & __m;
}
template <size_t _Size>
inline
size_t
__bitset<1, _Size>::__hash_code() const throw()
{
return __first_;
}
template <>
class __bitset<0, 0>
{
public:
typedef ptrdiff_t difference_type;
typedef size_t size_type;
typedef size_type __storage_type;
protected:
typedef __bitset __self;
typedef __storage_type* __storage_pointer;
typedef const __storage_type* __const_storage_pointer;
static const unsigned __bits_per_word = static_cast<unsigned>(sizeof(__storage_type) * 8);
friend class __bit_reference<__bitset>;
friend class __bit_const_reference<__bitset>;
friend class __bit_iterator<__bitset, false>;
friend class __bit_iterator<__bitset, true>;
friend struct __bit_array<__bitset>;
typedef __bit_reference<__bitset> reference;
typedef __bit_const_reference<__bitset> const_reference;
typedef __bit_iterator<__bitset, false> iterator;
typedef __bit_iterator<__bitset, true> const_iterator;
__attribute__ ((__visibility__("hidden"), __always_inline__))
__bitset() throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
explicit __bitset(unsigned long long) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference __make_ref(size_t) throw()
{return reference(0, 1);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_reference __make_ref(size_t) const throw()
{return const_reference(0, 1);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) iterator __make_iter(size_t) throw()
{return iterator(0, 0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) const_iterator __make_iter(size_t) const throw()
{return const_iterator(0, 0);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void operator&=(const __bitset&) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void operator|=(const __bitset&) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void operator^=(const __bitset&) throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) void flip() throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__)) unsigned long to_ulong() const {return 0;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) unsigned long long to_ullong() const {return 0;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool all() const throw() {return true;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool any() const throw() {return false;}
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_t __hash_code() const throw() {return 0;}
};
inline
__bitset<0, 0>::__bitset() throw()
{
}
inline
__bitset<0, 0>::__bitset(unsigned long long) throw()
{
}
template <size_t _Size> class __attribute__ ((__type_visibility__("default"))) bitset;
template <size_t _Size> struct hash<bitset<_Size> >;
template <size_t _Size>
class __attribute__ ((__type_visibility__("default"))) bitset
: private __bitset<_Size == 0 ? 0 : (_Size - 1) / (sizeof(size_t) * 8) + 1, _Size>
{
public:
static const unsigned __n_words = _Size == 0 ? 0 : (_Size - 1) / (sizeof(size_t) * 8) + 1;
typedef __bitset<__n_words, _Size> base;
public:
typedef typename base::reference reference;
typedef typename base::const_reference const_reference;
__attribute__ ((__visibility__("hidden"), __always_inline__)) bitset() throw() {}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset(unsigned long long __v) throw() : base(__v) {}
template<class _CharT>
explicit bitset(const _CharT* __str,
typename basic_string<_CharT>::size_type __n = basic_string<_CharT>::npos,
_CharT __zero = _CharT('0'), _CharT __one = _CharT('1'));
template<class _CharT, class _Traits, class _Allocator>
explicit bitset(const basic_string<_CharT,_Traits,_Allocator>& __str,
typename basic_string<_CharT,_Traits,_Allocator>::size_type __pos = 0,
typename basic_string<_CharT,_Traits,_Allocator>::size_type __n =
(basic_string<_CharT,_Traits,_Allocator>::npos),
_CharT __zero = _CharT('0'), _CharT __one = _CharT('1'));
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset& operator&=(const bitset& __rhs) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset& operator|=(const bitset& __rhs) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset& operator^=(const bitset& __rhs) throw();
bitset& operator<<=(size_t __pos) throw();
bitset& operator>>=(size_t __pos) throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset& set() throw();
bitset& set(size_t __pos, bool __val = true);
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset& reset() throw();
bitset& reset(size_t __pos);
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset operator~() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset& flip() throw();
bitset& flip(size_t __pos);
__attribute__ ((__visibility__("hidden"), __always_inline__))
const_reference operator[](size_t __p) const {return base::__make_ref(__p);}
__attribute__ ((__visibility__("hidden"), __always_inline__)) reference operator[](size_t __p) {return base::__make_ref(__p);}
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long to_ulong() const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
unsigned long long to_ullong() const;
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator> to_string(_CharT __zero = _CharT('0'),
_CharT __one = _CharT('1')) const;
template <class _CharT, class _Traits>
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, _Traits, allocator<_CharT> > to_string(_CharT __zero = _CharT('0'),
_CharT __one = _CharT('1')) const;
template <class _CharT>
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<_CharT, char_traits<_CharT>, allocator<_CharT> > to_string(_CharT __zero = _CharT('0'),
_CharT __one = _CharT('1')) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_string<char, char_traits<char>, allocator<char> > to_string(char __zero = '0',
char __one = '1') const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t count() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) size_t size() const throw() {return _Size;}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator==(const bitset& __rhs) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool operator!=(const bitset& __rhs) const throw();
bool test(size_t __pos) const;
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool all() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bool any() const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__)) bool none() const throw() {return !any();}
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset operator<<(size_t __pos) const throw();
__attribute__ ((__visibility__("hidden"), __always_inline__))
bitset operator>>(size_t __pos) const throw();
private:
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t __hash_code() const throw() {return base::__hash_code();}
friend struct hash<bitset>;
};
template <size_t _Size>
template<class _CharT>
bitset<_Size>::bitset(const _CharT* __str,
typename basic_string<_CharT>::size_type __n,
_CharT __zero, _CharT __one)
{
size_t __rlen = std::__1::min(__n, char_traits<_CharT>::length(__str));
for (size_t __i = 0; __i < __rlen; ++__i)
if (__str[__i] != __zero && __str[__i] != __one)
__throw_invalid_argument("bitset string ctor has invalid argument");
size_t _Mp = std::__1::min(__rlen, _Size);
size_t __i = 0;
for (; __i < _Mp; ++__i)
{
_CharT __c = __str[_Mp - 1 - __i];
if (__c == __zero)
(*this)[__i] = false;
else
(*this)[__i] = true;
}
std::__1::fill(base::__make_iter(__i), base::__make_iter(_Size), false);
}
template <size_t _Size>
template<class _CharT, class _Traits, class _Allocator>
bitset<_Size>::bitset(const basic_string<_CharT,_Traits,_Allocator>& __str,
typename basic_string<_CharT,_Traits,_Allocator>::size_type __pos,
typename basic_string<_CharT,_Traits,_Allocator>::size_type __n,
_CharT __zero, _CharT __one)
{
if (__pos > __str.size())
__throw_out_of_range("bitset string pos out of range");
size_t __rlen = std::__1::min(__n, __str.size() - __pos);
for (size_t __i = __pos; __i < __pos + __rlen; ++__i)
if (!_Traits::eq(__str[__i], __zero) && !_Traits::eq(__str[__i], __one))
__throw_invalid_argument("bitset string ctor has invalid argument");
size_t _Mp = std::__1::min(__rlen, _Size);
size_t __i = 0;
for (; __i < _Mp; ++__i)
{
_CharT __c = __str[__pos + _Mp - 1 - __i];
if (_Traits::eq(__c, __zero))
(*this)[__i] = false;
else
(*this)[__i] = true;
}
std::__1::fill(base::__make_iter(__i), base::__make_iter(_Size), false);
}
template <size_t _Size>
inline
bitset<_Size>&
bitset<_Size>::operator&=(const bitset& __rhs) throw()
{
base::operator&=(__rhs);
return *this;
}
template <size_t _Size>
inline
bitset<_Size>&
bitset<_Size>::operator|=(const bitset& __rhs) throw()
{
base::operator|=(__rhs);
return *this;
}
template <size_t _Size>
inline
bitset<_Size>&
bitset<_Size>::operator^=(const bitset& __rhs) throw()
{
base::operator^=(__rhs);
return *this;
}
template <size_t _Size>
bitset<_Size>&
bitset<_Size>::operator<<=(size_t __pos) throw()
{
__pos = std::__1::min(__pos, _Size);
std::__1::copy_backward(base::__make_iter(0), base::__make_iter(_Size - __pos), base::__make_iter(_Size));
std::__1::fill_n(base::__make_iter(0), __pos, false);
return *this;
}
template <size_t _Size>
bitset<_Size>&
bitset<_Size>::operator>>=(size_t __pos) throw()
{
__pos = std::__1::min(__pos, _Size);
std::__1::copy(base::__make_iter(__pos), base::__make_iter(_Size), base::__make_iter(0));
std::__1::fill_n(base::__make_iter(_Size - __pos), __pos, false);
return *this;
}
template <size_t _Size>
inline
bitset<_Size>&
bitset<_Size>::set() throw()
{
std::__1::fill_n(base::__make_iter(0), _Size, true);
return *this;
}
template <size_t _Size>
bitset<_Size>&
bitset<_Size>::set(size_t __pos, bool __val)
{
if (__pos >= _Size)
__throw_out_of_range("bitset set argument out of range");
(*this)[__pos] = __val;
return *this;
}
template <size_t _Size>
inline
bitset<_Size>&
bitset<_Size>::reset() throw()
{
std::__1::fill_n(base::__make_iter(0), _Size, false);
return *this;
}
template <size_t _Size>
bitset<_Size>&
bitset<_Size>::reset(size_t __pos)
{
if (__pos >= _Size)
__throw_out_of_range("bitset reset argument out of range");
(*this)[__pos] = false;
return *this;
}
template <size_t _Size>
inline
bitset<_Size>
bitset<_Size>::operator~() const throw()
{
bitset __x(*this);
__x.flip();
return __x;
}
template <size_t _Size>
inline
bitset<_Size>&
bitset<_Size>::flip() throw()
{
base::flip();
return *this;
}
template <size_t _Size>
bitset<_Size>&
bitset<_Size>::flip(size_t __pos)
{
if (__pos >= _Size)
__throw_out_of_range("bitset flip argument out of range");
reference r = base::__make_ref(__pos);
r = ~r;
return *this;
}
template <size_t _Size>
inline
unsigned long
bitset<_Size>::to_ulong() const
{
return base::to_ulong();
}
template <size_t _Size>
inline
unsigned long long
bitset<_Size>::to_ullong() const
{
return base::to_ullong();
}
template <size_t _Size>
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
bitset<_Size>::to_string(_CharT __zero, _CharT __one) const
{
basic_string<_CharT, _Traits, _Allocator> __r(_Size, __zero);
for (size_t __i = 0; __i < _Size; ++__i)
{
if ((*this)[__i])
__r[_Size - 1 - __i] = __one;
}
return __r;
}
template <size_t _Size>
template <class _CharT, class _Traits>
inline
basic_string<_CharT, _Traits, allocator<_CharT> >
bitset<_Size>::to_string(_CharT __zero, _CharT __one) const
{
return to_string<_CharT, _Traits, allocator<_CharT> >(__zero, __one);
}
template <size_t _Size>
template <class _CharT>
inline
basic_string<_CharT, char_traits<_CharT>, allocator<_CharT> >
bitset<_Size>::to_string(_CharT __zero, _CharT __one) const
{
return to_string<_CharT, char_traits<_CharT>, allocator<_CharT> >(__zero, __one);
}
template <size_t _Size>
inline
basic_string<char, char_traits<char>, allocator<char> >
bitset<_Size>::to_string(char __zero, char __one) const
{
return to_string<char, char_traits<char>, allocator<char> >(__zero, __one);
}
template <size_t _Size>
inline
size_t
bitset<_Size>::count() const throw()
{
return static_cast<size_t>(std::__1::count(base::__make_iter(0), base::__make_iter(_Size), true));
}
template <size_t _Size>
inline
bool
bitset<_Size>::operator==(const bitset& __rhs) const throw()
{
return std::__1::equal(base::__make_iter(0), base::__make_iter(_Size), __rhs.__make_iter(0));
}
template <size_t _Size>
inline
bool
bitset<_Size>::operator!=(const bitset& __rhs) const throw()
{
return !(*this == __rhs);
}
template <size_t _Size>
bool
bitset<_Size>::test(size_t __pos) const
{
if (__pos >= _Size)
__throw_out_of_range("bitset test argument out of range");
return (*this)[__pos];
}
template <size_t _Size>
inline
bool
bitset<_Size>::all() const throw()
{
return base::all();
}
template <size_t _Size>
inline
bool
bitset<_Size>::any() const throw()
{
return base::any();
}
template <size_t _Size>
inline
bitset<_Size>
bitset<_Size>::operator<<(size_t __pos) const throw()
{
bitset __r = *this;
__r <<= __pos;
return __r;
}
template <size_t _Size>
inline
bitset<_Size>
bitset<_Size>::operator>>(size_t __pos) const throw()
{
bitset __r = *this;
__r >>= __pos;
return __r;
}
template <size_t _Size>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bitset<_Size>
operator&(const bitset<_Size>& __x, const bitset<_Size>& __y) throw()
{
bitset<_Size> __r = __x;
__r &= __y;
return __r;
}
template <size_t _Size>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bitset<_Size>
operator|(const bitset<_Size>& __x, const bitset<_Size>& __y) throw()
{
bitset<_Size> __r = __x;
__r |= __y;
return __r;
}
template <size_t _Size>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
bitset<_Size>
operator^(const bitset<_Size>& __x, const bitset<_Size>& __y) throw()
{
bitset<_Size> __r = __x;
__r ^= __y;
return __r;
}
template <size_t _Size>
struct __attribute__ ((__type_visibility__("default"))) hash<bitset<_Size> >
: public unary_function<bitset<_Size>, size_t>
{
__attribute__ ((__visibility__("hidden"), __always_inline__))
size_t operator()(const bitset<_Size>& __bs) const throw()
{return __bs.__hash_code();}
};
template <class _CharT, class _Traits, size_t _Size>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Size>& __x);
template <class _CharT, class _Traits, size_t _Size>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, const bitset<_Size>& __x);
} }
# 143 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 2 3
# 146 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 3
namespace std {inline namespace __1 {
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_ostream
: virtual public basic_ios<_CharT, _Traits>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
inline __attribute__((__visibility__("default"), __always_inline__))
explicit basic_ostream(basic_streambuf<char_type, traits_type>* __sb)
{ this->init(__sb); }
virtual ~basic_ostream();
protected:
# 176 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 3
inline __attribute__((__visibility__("default"), __always_inline__))
void swap(basic_ostream& __rhs)
{ basic_ios<char_type, traits_type>::swap(__rhs); }
basic_ostream (const basic_ostream& __rhs);
basic_ostream& operator=(const basic_ostream& __rhs);
public:
class __attribute__ ((__type_visibility__("default"))) sentry;
inline __attribute__((__visibility__("default"), __always_inline__))
basic_ostream& operator<<(basic_ostream& (*__pf)(basic_ostream&))
{ return __pf(*this); }
inline __attribute__((__visibility__("default"), __always_inline__))
basic_ostream& operator<<(basic_ios<char_type, traits_type>&
(*__pf)(basic_ios<char_type,traits_type>&))
{ __pf(*this); return *this; }
inline __attribute__((__visibility__("default"), __always_inline__))
basic_ostream& operator<<(ios_base& (*__pf)(ios_base&))
{ __pf(*this); return *this; }
basic_ostream& operator<<(bool __n);
basic_ostream& operator<<(short __n);
basic_ostream& operator<<(unsigned short __n);
basic_ostream& operator<<(int __n);
basic_ostream& operator<<(unsigned int __n);
basic_ostream& operator<<(long __n);
basic_ostream& operator<<(unsigned long __n);
basic_ostream& operator<<(long long __n);
basic_ostream& operator<<(unsigned long long __n);
basic_ostream& operator<<(float __f);
basic_ostream& operator<<(double __f);
basic_ostream& operator<<(long double __f);
basic_ostream& operator<<(const void* __p);
basic_ostream& operator<<(basic_streambuf<char_type, traits_type>* __sb);
basic_ostream& put(char_type __c);
basic_ostream& write(const char_type* __s, streamsize __n);
basic_ostream& flush();
inline __attribute__((__visibility__("default"), __always_inline__))
pos_type tellp();
inline __attribute__((__visibility__("default"), __always_inline__))
basic_ostream& seekp(pos_type __pos);
inline __attribute__((__visibility__("default"), __always_inline__))
basic_ostream& seekp(off_type __off, ios_base::seekdir __dir);
protected:
__attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream() {}
};
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_ostream<_CharT, _Traits>::sentry
{
bool __ok_;
basic_ostream<_CharT, _Traits>& __os_;
sentry(const sentry&);
sentry& operator=(const sentry&);
public:
explicit sentry(basic_ostream<_CharT, _Traits>& __os);
~sentry();
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const {return __ok_;}
};
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>::sentry::sentry(basic_ostream<_CharT, _Traits>& __os)
: __ok_(false),
__os_(__os)
{
if (__os.good())
{
if (__os.tie())
__os.tie()->flush();
__ok_ = true;
}
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>::sentry::~sentry()
{
if (__os_.rdbuf() && __os_.good() && (__os_.flags() & ios_base::unitbuf)
&& !uncaught_exception())
{
try
{
if (__os_.rdbuf()->pubsync() == -1)
__os_.setstate(ios_base::badbit);
}
catch (...)
{
}
}
}
# 309 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 3
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>::~basic_ostream()
{
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(basic_streambuf<char_type, traits_type>* __sb)
{
try
{
sentry __s(*this);
if (__s)
{
if (__sb)
{
try
{
typedef istreambuf_iterator<_CharT, _Traits> _Ip;
typedef ostreambuf_iterator<_CharT, _Traits> _Op;
_Ip __i(__sb);
_Ip __eof;
_Op __o(*this);
size_t __c = 0;
for (; __i != __eof; ++__i, ++__o, ++__c)
{
*__o = *__i;
if (__o.failed())
break;
}
if (__c == 0)
this->setstate(ios_base::failbit);
}
catch (...)
{
this->__set_failbit_and_consider_rethrow();
}
}
else
this->setstate(ios_base::badbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(bool __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(short __n)
{
try
{
sentry __s(*this);
if (__s)
{
ios_base::fmtflags __flags = ios_base::flags() & ios_base::basefield;
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(),
__flags == ios_base::oct || __flags == ios_base::hex ?
static_cast<long>(static_cast<unsigned short>(__n)) :
static_cast<long>(__n)).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(unsigned short __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), static_cast<unsigned long>(__n)).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(int __n)
{
try
{
sentry __s(*this);
if (__s)
{
ios_base::fmtflags __flags = ios_base::flags() & ios_base::basefield;
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(),
__flags == ios_base::oct || __flags == ios_base::hex ?
static_cast<long>(static_cast<unsigned int>(__n)) :
static_cast<long>(__n)).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(unsigned int __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), static_cast<unsigned long>(__n)).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(long __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(unsigned long __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(long long __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(unsigned long long __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(float __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), static_cast<double>(__n)).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(double __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(long double __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::operator<<(const void* __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef num_put<char_type, ostreambuf_iterator<char_type, traits_type> > _Fp;
const _Fp& __f = use_facet<_Fp>(this->getloc());
if (__f.put(*this, *this, this->fill(), __n).failed())
this->setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
__put_character_sequence(basic_ostream<_CharT, _Traits>& __os,
const _CharT* __str, size_t __len)
{
try
{
typename basic_ostream<_CharT, _Traits>::sentry __s(__os);
if (__s)
{
typedef ostreambuf_iterator<_CharT, _Traits> _Ip;
if (__pad_and_output(_Ip(__os),
__str,
(__os.flags() & ios_base::adjustfield) == ios_base::left ?
__str + __len :
__str,
__str + __len,
__os,
__os.fill()).failed())
__os.setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
__os.__set_badbit_and_consider_rethrow();
}
return __os;
}
template<class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, _CharT __c)
{
return std::__1::__put_character_sequence(__os, &__c, 1);
}
template<class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, char __cn)
{
try
{
typename basic_ostream<_CharT, _Traits>::sentry __s(__os);
if (__s)
{
_CharT __c = __os.widen(__cn);
typedef ostreambuf_iterator<_CharT, _Traits> _Ip;
if (__pad_and_output(_Ip(__os),
&__c,
(__os.flags() & ios_base::adjustfield) == ios_base::left ?
&__c + 1 :
&__c,
&__c + 1,
__os,
__os.fill()).failed())
__os.setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
__os.__set_badbit_and_consider_rethrow();
}
return __os;
}
template<class _Traits>
basic_ostream<char, _Traits>&
operator<<(basic_ostream<char, _Traits>& __os, char __c)
{
return std::__1::__put_character_sequence(__os, &__c, 1);
}
template<class _Traits>
basic_ostream<char, _Traits>&
operator<<(basic_ostream<char, _Traits>& __os, signed char __c)
{
return std::__1::__put_character_sequence(__os, (char *) &__c, 1);
}
template<class _Traits>
basic_ostream<char, _Traits>&
operator<<(basic_ostream<char, _Traits>& __os, unsigned char __c)
{
return std::__1::__put_character_sequence(__os, (char *) &__c, 1);
}
template<class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, const _CharT* __str)
{
return std::__1::__put_character_sequence(__os, __str, _Traits::length(__str));
}
template<class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, const char* __strn)
{
try
{
typename basic_ostream<_CharT, _Traits>::sentry __s(__os);
if (__s)
{
typedef ostreambuf_iterator<_CharT, _Traits> _Ip;
size_t __len = char_traits<char>::length(__strn);
const int __bs = 100;
_CharT __wbb[__bs];
_CharT* __wb = __wbb;
unique_ptr<_CharT, void(*)(void*)> __h(0, free);
if (__len > __bs)
{
__wb = (_CharT*)malloc(__len*sizeof(_CharT));
if (__wb == 0)
__throw_bad_alloc();
__h.reset(__wb);
}
for (_CharT* __p = __wb; *__strn != '\0'; ++__strn, ++__p)
*__p = __os.widen(*__strn);
if (__pad_and_output(_Ip(__os),
__wb,
(__os.flags() & ios_base::adjustfield) == ios_base::left ?
__wb + __len :
__wb,
__wb + __len,
__os,
__os.fill()).failed())
__os.setstate(ios_base::badbit | ios_base::failbit);
}
}
catch (...)
{
__os.__set_badbit_and_consider_rethrow();
}
return __os;
}
template<class _Traits>
basic_ostream<char, _Traits>&
operator<<(basic_ostream<char, _Traits>& __os, const char* __str)
{
return std::__1::__put_character_sequence(__os, __str, _Traits::length(__str));
}
template<class _Traits>
basic_ostream<char, _Traits>&
operator<<(basic_ostream<char, _Traits>& __os, const signed char* __str)
{
const char *__s = (const char *) __str;
return std::__1::__put_character_sequence(__os, __s, _Traits::length(__s));
}
template<class _Traits>
basic_ostream<char, _Traits>&
operator<<(basic_ostream<char, _Traits>& __os, const unsigned char* __str)
{
const char *__s = (const char *) __str;
return std::__1::__put_character_sequence(__os, __s, _Traits::length(__s));
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::put(char_type __c)
{
try
{
sentry __s(*this);
if (__s)
{
typedef ostreambuf_iterator<_CharT, _Traits> _Op;
_Op __o(*this);
*__o = __c;
if (__o.failed())
this->setstate(ios_base::badbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::write(const char_type* __s, streamsize __n)
{
try
{
sentry __sen(*this);
if (__sen && __n)
{
if (this->rdbuf()->sputn(__s, __n) != __n)
this->setstate(ios_base::badbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::flush()
{
try
{
if (this->rdbuf())
{
sentry __s(*this);
if (__s)
{
if (this->rdbuf()->pubsync() == -1)
this->setstate(ios_base::badbit);
}
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
typename basic_ostream<_CharT, _Traits>::pos_type
basic_ostream<_CharT, _Traits>::tellp()
{
if (this->fail())
return pos_type(-1);
return this->rdbuf()->pubseekoff(0, ios_base::cur, ios_base::out);
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::seekp(pos_type __pos)
{
sentry __s(*this);
if (!this->fail())
{
if (this->rdbuf()->pubseekpos(__pos, ios_base::out) == pos_type(-1))
this->setstate(ios_base::failbit);
}
return *this;
}
template <class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
basic_ostream<_CharT, _Traits>::seekp(off_type __off, ios_base::seekdir __dir)
{
sentry __s(*this);
if (!this->fail())
{
if (this->rdbuf()->pubseekoff(__off, __dir, ios_base::out) == pos_type(-1))
this->setstate(ios_base::failbit);
}
return *this;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>&
endl(basic_ostream<_CharT, _Traits>& __os)
{
__os.put(__os.widen('\n'));
__os.flush();
return __os;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>&
ends(basic_ostream<_CharT, _Traits>& __os)
{
__os.put(_CharT());
return __os;
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>&
flush(basic_ostream<_CharT, _Traits>& __os)
{
__os.flush();
return __os;
}
# 1042 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 3
template<class _CharT, class _Traits, class _Allocator>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os,
const basic_string<_CharT, _Traits, _Allocator>& __str)
{
return std::__1::__put_character_sequence(__os, __str.data(), __str.size());
}
template<class _CharT, class _Traits>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os,
const basic_string_view<_CharT, _Traits> __sv)
{
return std::__1::__put_character_sequence(__os, __sv.data(), __sv.size());
}
template <class _CharT, class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, const error_code& __ec)
{
return __os << __ec.category().name() << ':' << __ec.value();
}
template<class _CharT, class _Traits, class _Yp>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, shared_ptr<_Yp> const& __p)
{
return __os << __p.get();
}
# 1088 "/Library/Developer/CommandLineTools/usr/include/c++/v1/ostream" 3
template <class _CharT, class _Traits, size_t _Size>
basic_ostream<_CharT, _Traits>&
operator<<(basic_ostream<_CharT, _Traits>& __os, const bitset<_Size>& __x)
{
return __os << __x.template to_string<_CharT, _Traits>
(use_facet<ctype<_CharT> >(__os.getloc()).widen('0'),
use_facet<ctype<_CharT> >(__os.getloc()).widen('1'));
}
extern template class __attribute__ ((__visibility__("default"))) basic_ostream<char>;
extern template class __attribute__ ((__visibility__("default"))) basic_ostream<wchar_t>;
} }
# 175 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 2 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 1 3
# 167 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 171 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 2 3
namespace std {inline namespace __1 {
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_istream
: virtual public basic_ios<_CharT, _Traits>
{
streamsize __gc_;
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
inline __attribute__((__visibility__("default"), __always_inline__))
explicit basic_istream(basic_streambuf<char_type, traits_type>* __sb) : __gc_(0)
{ this->init(__sb); }
virtual ~basic_istream();
protected:
# 203 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
inline __attribute__((__visibility__("default"), __always_inline__))
void swap(basic_istream& __rhs) {
std::__1::swap(__gc_, __rhs.__gc_);
basic_ios<char_type, traits_type>::swap(__rhs);
}
public:
class __attribute__ ((__type_visibility__("default"))) sentry;
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& operator>>(basic_istream& (*__pf)(basic_istream&))
{ return __pf(*this); }
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& operator>>(basic_ios<char_type, traits_type>&
(*__pf)(basic_ios<char_type, traits_type>&))
{ __pf(*this); return *this; }
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& operator>>(ios_base& (*__pf)(ios_base&))
{ __pf(*this); return *this; }
basic_istream& operator>>(basic_streambuf<char_type, traits_type>* __sb);
basic_istream& operator>>(bool& __n);
basic_istream& operator>>(short& __n);
basic_istream& operator>>(unsigned short& __n);
basic_istream& operator>>(int& __n);
basic_istream& operator>>(unsigned int& __n);
basic_istream& operator>>(long& __n);
basic_istream& operator>>(unsigned long& __n);
basic_istream& operator>>(long long& __n);
basic_istream& operator>>(unsigned long long& __n);
basic_istream& operator>>(float& __f);
basic_istream& operator>>(double& __f);
basic_istream& operator>>(long double& __f);
basic_istream& operator>>(void*& __p);
__attribute__ ((__visibility__("hidden"), __always_inline__))
streamsize gcount() const {return __gc_;}
int_type get();
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& get(char_type& __c) {
int_type __ch = get();
if (__ch != traits_type::eof())
__c = traits_type::to_char_type(__ch);
return *this;
}
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& get(char_type* __s, streamsize __n)
{ return get(__s, __n, this->widen('\n')); }
basic_istream& get(char_type* __s, streamsize __n, char_type __dlm);
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& get(basic_streambuf<char_type, traits_type>& __sb)
{ return get(__sb, this->widen('\n')); }
basic_istream& get(basic_streambuf<char_type, traits_type>& __sb, char_type __dlm);
inline __attribute__((__visibility__("default"), __always_inline__))
basic_istream& getline(char_type* __s, streamsize __n)
{ return getline(__s, __n, this->widen('\n')); }
basic_istream& getline(char_type* __s, streamsize __n, char_type __dlm);
basic_istream& ignore(streamsize __n = 1, int_type __dlm = traits_type::eof());
int_type peek();
basic_istream& read (char_type* __s, streamsize __n);
streamsize readsome(char_type* __s, streamsize __n);
basic_istream& putback(char_type __c);
basic_istream& unget();
int sync();
pos_type tellg();
basic_istream& seekg(pos_type __pos);
basic_istream& seekg(off_type __off, ios_base::seekdir __dir);
};
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_istream<_CharT, _Traits>::sentry
{
bool __ok_;
sentry(const sentry&);
sentry& operator=(const sentry&);
public:
explicit sentry(basic_istream<_CharT, _Traits>& __is, bool __noskipws = false);
__attribute__ ((__visibility__("hidden"), __always_inline__))
operator bool() const {return __ok_;}
};
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>::sentry::sentry(basic_istream<_CharT, _Traits>& __is,
bool __noskipws)
: __ok_(false)
{
if (__is.good())
{
if (__is.tie())
__is.tie()->flush();
if (!__noskipws && (__is.flags() & ios_base::skipws))
{
typedef istreambuf_iterator<_CharT, _Traits> _Ip;
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__is.getloc());
_Ip __i(__is);
_Ip __eof;
for (; __i != __eof; ++__i)
if (!__ct.is(__ct.space, *__i))
break;
if (__i == __eof)
__is.setstate(ios_base::failbit | ios_base::eofbit);
}
__ok_ = __is.good();
}
else
__is.setstate(ios_base::failbit);
}
# 356 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>::~basic_istream()
{
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(unsigned short& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(unsigned int& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(long& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(unsigned long& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(long long& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(unsigned long long& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(float& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(double& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(long double& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(bool& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(void*& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(short& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
long __temp;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __temp);
if (__temp < numeric_limits<short>::min())
{
__err |= ios_base::failbit;
__n = numeric_limits<short>::min();
}
else if (__temp > numeric_limits<short>::max())
{
__err |= ios_base::failbit;
__n = numeric_limits<short>::max();
}
else
__n = static_cast<short>(__temp);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(int& __n)
{
try
{
sentry __s(*this);
if (__s)
{
typedef istreambuf_iterator<char_type, traits_type> _Ip;
typedef num_get<char_type, _Ip> _Fp;
ios_base::iostate __err = ios_base::goodbit;
long __temp;
use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __temp);
if (__temp < numeric_limits<int>::min())
{
__err |= ios_base::failbit;
__n = numeric_limits<int>::min();
}
else if (__temp > numeric_limits<int>::max())
{
__err |= ios_base::failbit;
__n = numeric_limits<int>::max();
}
else
__n = static_cast<int>(__temp);
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is, _CharT* __s)
{
try
{
typename basic_istream<_CharT, _Traits>::sentry __sen(__is);
if (__sen)
{
streamsize __n = __is.width();
if (__n <= 0)
__n = numeric_limits<streamsize>::max() / sizeof(_CharT) - 1;
streamsize __c = 0;
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__is.getloc());
ios_base::iostate __err = ios_base::goodbit;
while (__c < __n-1)
{
typename _Traits::int_type __i = __is.rdbuf()->sgetc();
if (_Traits::eq_int_type(__i, _Traits::eof()))
{
__err |= ios_base::eofbit;
break;
}
_CharT __ch = _Traits::to_char_type(__i);
if (__ct.is(__ct.space, __ch))
break;
*__s++ = __ch;
++__c;
__is.rdbuf()->sbumpc();
}
*__s = _CharT();
__is.width(0);
if (__c == 0)
__err |= ios_base::failbit;
__is.setstate(__err);
}
}
catch (...)
{
__is.__set_badbit_and_consider_rethrow();
}
return __is;
}
template<class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_istream<char, _Traits>&
operator>>(basic_istream<char, _Traits>& __is, unsigned char* __s)
{
return __is >> (char*)__s;
}
template<class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_istream<char, _Traits>&
operator>>(basic_istream<char, _Traits>& __is, signed char* __s)
{
return __is >> (char*)__s;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is, _CharT& __c)
{
try
{
typename basic_istream<_CharT, _Traits>::sentry __sen(__is);
if (__sen)
{
typename _Traits::int_type __i = __is.rdbuf()->sbumpc();
if (_Traits::eq_int_type(__i, _Traits::eof()))
__is.setstate(ios_base::eofbit | ios_base::failbit);
else
__c = _Traits::to_char_type(__i);
}
}
catch (...)
{
__is.__set_badbit_and_consider_rethrow();
}
return __is;
}
template<class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_istream<char, _Traits>&
operator>>(basic_istream<char, _Traits>& __is, unsigned char& __c)
{
return __is >> (char&)__c;
}
template<class _Traits>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_istream<char, _Traits>&
operator>>(basic_istream<char, _Traits>& __is, signed char& __c)
{
return __is >> (char&)__c;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::operator>>(basic_streambuf<char_type, traits_type>* __sb)
{
__gc_ = 0;
try
{
sentry __s(*this, true);
if (__s)
{
if (__sb)
{
try
{
ios_base::iostate __err = ios_base::goodbit;
while (true)
{
typename traits_type::int_type __i = this->rdbuf()->sgetc();
if (traits_type::eq_int_type(__i, _Traits::eof()))
{
__err |= ios_base::eofbit;
break;
}
if (traits_type::eq_int_type(
__sb->sputc(traits_type::to_char_type(__i)),
traits_type::eof()))
break;
++__gc_;
this->rdbuf()->sbumpc();
}
if (__gc_ == 0)
__err |= ios_base::failbit;
this->setstate(__err);
}
catch (...)
{
if (__gc_ == 0)
this->__set_failbit_and_consider_rethrow();
}
}
else
this->setstate(ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
typename basic_istream<_CharT, _Traits>::int_type
basic_istream<_CharT, _Traits>::get()
{
__gc_ = 0;
int_type __r = traits_type::eof();
try
{
sentry __s(*this, true);
if (__s)
{
__r = this->rdbuf()->sbumpc();
if (traits_type::eq_int_type(__r, traits_type::eof()))
this->setstate(ios_base::failbit | ios_base::eofbit);
else
__gc_ = 1;
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return __r;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::get(char_type* __s, streamsize __n, char_type __dlm)
{
__gc_ = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
if (__n > 0)
{
ios_base::iostate __err = ios_base::goodbit;
while (__gc_ < __n-1)
{
int_type __i = this->rdbuf()->sgetc();
if (traits_type::eq_int_type(__i, traits_type::eof()))
{
__err |= ios_base::eofbit;
break;
}
char_type __ch = traits_type::to_char_type(__i);
if (traits_type::eq(__ch, __dlm))
break;
*__s++ = __ch;
++__gc_;
this->rdbuf()->sbumpc();
}
if (__gc_ == 0)
__err |= ios_base::failbit;
this->setstate(__err);
}
else
this->setstate(ios_base::failbit);
}
if (__n > 0)
*__s = char_type();
}
catch (...)
{
if (__n > 0)
*__s = char_type();
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::get(basic_streambuf<char_type, traits_type>& __sb,
char_type __dlm)
{
__gc_ = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
ios_base::iostate __err = ios_base::goodbit;
try
{
while (true)
{
typename traits_type::int_type __i = this->rdbuf()->sgetc();
if (traits_type::eq_int_type(__i, traits_type::eof()))
{
__err |= ios_base::eofbit;
break;
}
char_type __ch = traits_type::to_char_type(__i);
if (traits_type::eq(__ch, __dlm))
break;
if (traits_type::eq_int_type(__sb.sputc(__ch), traits_type::eof()))
break;
++__gc_;
this->rdbuf()->sbumpc();
}
}
catch (...)
{
}
if (__gc_ == 0)
__err |= ios_base::failbit;
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::getline(char_type* __s, streamsize __n, char_type __dlm)
{
__gc_ = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
ios_base::iostate __err = ios_base::goodbit;
while (true)
{
typename traits_type::int_type __i = this->rdbuf()->sgetc();
if (traits_type::eq_int_type(__i, traits_type::eof()))
{
__err |= ios_base::eofbit;
break;
}
char_type __ch = traits_type::to_char_type(__i);
if (traits_type::eq(__ch, __dlm))
{
this->rdbuf()->sbumpc();
++__gc_;
break;
}
if (__gc_ >= __n-1)
{
__err |= ios_base::failbit;
break;
}
*__s++ = __ch;
this->rdbuf()->sbumpc();
++__gc_;
}
if (__gc_ == 0)
__err |= ios_base::failbit;
this->setstate(__err);
}
if (__n > 0)
*__s = char_type();
}
catch (...)
{
if (__n > 0)
*__s = char_type();
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::ignore(streamsize __n, int_type __dlm)
{
__gc_ = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
ios_base::iostate __err = ios_base::goodbit;
if (__n == numeric_limits<streamsize>::max())
{
while (true)
{
typename traits_type::int_type __i = this->rdbuf()->sbumpc();
if (traits_type::eq_int_type(__i, traits_type::eof()))
{
__err |= ios_base::eofbit;
break;
}
++__gc_;
if (traits_type::eq_int_type(__i, __dlm))
break;
}
}
else
{
while (__gc_ < __n)
{
typename traits_type::int_type __i = this->rdbuf()->sbumpc();
if (traits_type::eq_int_type(__i, traits_type::eof()))
{
__err |= ios_base::eofbit;
break;
}
++__gc_;
if (traits_type::eq_int_type(__i, __dlm))
break;
}
}
this->setstate(__err);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
typename basic_istream<_CharT, _Traits>::int_type
basic_istream<_CharT, _Traits>::peek()
{
__gc_ = 0;
int_type __r = traits_type::eof();
try
{
sentry __sen(*this, true);
if (__sen)
{
__r = this->rdbuf()->sgetc();
if (traits_type::eq_int_type(__r, traits_type::eof()))
this->setstate(ios_base::eofbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return __r;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::read(char_type* __s, streamsize __n)
{
__gc_ = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
__gc_ = this->rdbuf()->sgetn(__s, __n);
if (__gc_ != __n)
this->setstate(ios_base::failbit | ios_base::eofbit);
}
else
this->setstate(ios_base::failbit);
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
streamsize
basic_istream<_CharT, _Traits>::readsome(char_type* __s, streamsize __n)
{
__gc_ = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
streamsize __c = this->rdbuf()->in_avail();
switch (__c)
{
case -1:
this->setstate(ios_base::eofbit);
break;
case 0:
break;
default:
read(__s, std::__1::min(__c, __n));
break;
}
}
else
this->setstate(ios_base::failbit);
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return __gc_;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::putback(char_type __c)
{
__gc_ = 0;
try
{
this->clear(this->rdstate() & ~ios_base::eofbit);
sentry __sen(*this, true);
if (__sen)
{
if (this->rdbuf() == 0 || this->rdbuf()->sputbackc(__c) == traits_type::eof())
this->setstate(ios_base::badbit);
}
else
this->setstate(ios_base::failbit);
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::unget()
{
__gc_ = 0;
try
{
this->clear(this->rdstate() & ~ios_base::eofbit);
sentry __sen(*this, true);
if (__sen)
{
if (this->rdbuf() == 0 || this->rdbuf()->sungetc() == traits_type::eof())
this->setstate(ios_base::badbit);
}
else
this->setstate(ios_base::failbit);
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
int
basic_istream<_CharT, _Traits>::sync()
{
int __r = 0;
try
{
sentry __sen(*this, true);
if (__sen)
{
if (this->rdbuf() == 0)
return -1;
if (this->rdbuf()->pubsync() == -1)
{
this->setstate(ios_base::badbit);
return -1;
}
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return __r;
}
template<class _CharT, class _Traits>
typename basic_istream<_CharT, _Traits>::pos_type
basic_istream<_CharT, _Traits>::tellg()
{
pos_type __r(-1);
try
{
sentry __sen(*this, true);
if (__sen)
__r = this->rdbuf()->pubseekoff(0, ios_base::cur, ios_base::in);
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return __r;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::seekg(pos_type __pos)
{
try
{
this->clear(this->rdstate() & ~ios_base::eofbit);
sentry __sen(*this, true);
if (__sen)
{
if (this->rdbuf()->pubseekpos(__pos, ios_base::in) == pos_type(-1))
this->setstate(ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template<class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
basic_istream<_CharT, _Traits>::seekg(off_type __off, ios_base::seekdir __dir)
{
try
{
this->clear(this->rdstate() & ~ios_base::eofbit);
sentry __sen(*this, true);
if (__sen)
{
if (this->rdbuf()->pubseekoff(__off, __dir, ios_base::in) == pos_type(-1))
this->setstate(ios_base::failbit);
}
}
catch (...)
{
this->__set_badbit_and_consider_rethrow();
}
return *this;
}
template <class _CharT, class _Traits>
basic_istream<_CharT, _Traits>&
ws(basic_istream<_CharT, _Traits>& __is)
{
try
{
typename basic_istream<_CharT, _Traits>::sentry __sen(__is, true);
if (__sen)
{
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__is.getloc());
while (true)
{
typename _Traits::int_type __i = __is.rdbuf()->sgetc();
if (_Traits::eq_int_type(__i, _Traits::eof()))
{
__is.setstate(ios_base::eofbit);
break;
}
if (!__ct.is(__ct.space, _Traits::to_char_type(__i)))
break;
__is.rdbuf()->sbumpc();
}
}
}
catch (...)
{
__is.__set_badbit_and_consider_rethrow();
}
return __is;
}
# 1446 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
template <class _CharT, class _Traits>
class __attribute__ ((__type_visibility__("default"))) basic_iostream
: public basic_istream<_CharT, _Traits>,
public basic_ostream<_CharT, _Traits>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
inline __attribute__((__visibility__("default"), __always_inline__))
explicit basic_iostream(basic_streambuf<char_type, traits_type>* __sb)
: basic_istream<_CharT, _Traits>(__sb)
{}
virtual ~basic_iostream();
protected:
# 1475 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
inline __attribute__((__visibility__("default"), __always_inline__))
void swap(basic_iostream& __rhs)
{ basic_istream<char_type, traits_type>::swap(__rhs); }
public:
};
# 1499 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
template <class _CharT, class _Traits>
basic_iostream<_CharT, _Traits>::~basic_iostream()
{
}
template<class _CharT, class _Traits, class _Allocator>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is,
basic_string<_CharT, _Traits, _Allocator>& __str)
{
try
{
typename basic_istream<_CharT, _Traits>::sentry __sen(__is);
if (__sen)
{
__str.clear();
streamsize __n = __is.width();
if (__n <= 0)
__n = __str.max_size();
if (__n <= 0)
__n = numeric_limits<streamsize>::max();
streamsize __c = 0;
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__is.getloc());
ios_base::iostate __err = ios_base::goodbit;
while (__c < __n)
{
typename _Traits::int_type __i = __is.rdbuf()->sgetc();
if (_Traits::eq_int_type(__i, _Traits::eof()))
{
__err |= ios_base::eofbit;
break;
}
_CharT __ch = _Traits::to_char_type(__i);
if (__ct.is(__ct.space, __ch))
break;
__str.push_back(__ch);
++__c;
__is.rdbuf()->sbumpc();
}
__is.width(0);
if (__c == 0)
__err |= ios_base::failbit;
__is.setstate(__err);
}
else
__is.setstate(ios_base::failbit);
}
catch (...)
{
__is.__set_badbit_and_consider_rethrow();
}
return __is;
}
template<class _CharT, class _Traits, class _Allocator>
basic_istream<_CharT, _Traits>&
getline(basic_istream<_CharT, _Traits>& __is,
basic_string<_CharT, _Traits, _Allocator>& __str, _CharT __dlm)
{
try
{
typename basic_istream<_CharT, _Traits>::sentry __sen(__is, true);
if (__sen)
{
__str.clear();
ios_base::iostate __err = ios_base::goodbit;
streamsize __extr = 0;
while (true)
{
typename _Traits::int_type __i = __is.rdbuf()->sbumpc();
if (_Traits::eq_int_type(__i, _Traits::eof()))
{
__err |= ios_base::eofbit;
break;
}
++__extr;
_CharT __ch = _Traits::to_char_type(__i);
if (_Traits::eq(__ch, __dlm))
break;
__str.push_back(__ch);
if (__str.size() == __str.max_size())
{
__err |= ios_base::failbit;
break;
}
}
if (__extr == 0)
__err |= ios_base::failbit;
__is.setstate(__err);
}
}
catch (...)
{
__is.__set_badbit_and_consider_rethrow();
}
return __is;
}
template<class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_istream<_CharT, _Traits>&
getline(basic_istream<_CharT, _Traits>& __is,
basic_string<_CharT, _Traits, _Allocator>& __str)
{
return getline(__is, __str, __is.widen('\n'));
}
# 1636 "/Library/Developer/CommandLineTools/usr/include/c++/v1/istream" 3
template <class _CharT, class _Traits, size_t _Size>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Size>& __x)
{
try
{
typename basic_istream<_CharT, _Traits>::sentry __sen(__is);
if (__sen)
{
basic_string<_CharT, _Traits> __str;
const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__is.getloc());
size_t __c = 0;
ios_base::iostate __err = ios_base::goodbit;
_CharT __zero = __ct.widen('0');
_CharT __one = __ct.widen('1');
while (__c < _Size)
{
typename _Traits::int_type __i = __is.rdbuf()->sgetc();
if (_Traits::eq_int_type(__i, _Traits::eof()))
{
__err |= ios_base::eofbit;
break;
}
_CharT __ch = _Traits::to_char_type(__i);
if (!_Traits::eq(__ch, __zero) && !_Traits::eq(__ch, __one))
break;
__str.push_back(__ch);
++__c;
__is.rdbuf()->sbumpc();
}
__x = bitset<_Size>(__str);
if (__c == 0)
__err |= ios_base::failbit;
__is.setstate(__err);
}
else
__is.setstate(ios_base::failbit);
}
catch (...)
{
__is.__set_badbit_and_consider_rethrow();
}
return __is;
}
extern template class __attribute__ ((__visibility__("default"))) basic_istream<char>;
extern template class __attribute__ ((__visibility__("default"))) basic_istream<wchar_t>;
extern template class __attribute__ ((__visibility__("default"))) basic_iostream<char>;
} }
# 176 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 2 3
# 180 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 3
# 1 "/Library/Developer/CommandLineTools/usr/include/c++/v1/__undef_macros" 1 3
# 184 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 2 3
namespace std {inline namespace __1 {
template <class _CharT, class _Traits, class _Allocator>
class __attribute__ ((__type_visibility__("default"))) basic_stringbuf
: public basic_streambuf<_CharT, _Traits>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
typedef _Allocator allocator_type;
typedef basic_string<char_type, traits_type, allocator_type> string_type;
private:
string_type __str_;
mutable char_type* __hm_;
ios_base::openmode __mode_;
public:
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_stringbuf(ios_base::openmode __wch = ios_base::in | ios_base::out);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_stringbuf(const string_type& __s,
ios_base::openmode __wch = ios_base::in | ios_base::out);
void swap(basic_stringbuf& __rhs);
string_type str() const;
void str(const string_type& __s);
protected:
virtual int_type underflow();
virtual int_type pbackfail(int_type __c = traits_type::eof());
virtual int_type overflow (int_type __c = traits_type::eof());
virtual pos_type seekoff(off_type __off, ios_base::seekdir __way,
ios_base::openmode __wch = ios_base::in | ios_base::out);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
virtual pos_type seekpos(pos_type __sp,
ios_base::openmode __wch = ios_base::in | ios_base::out);
};
template <class _CharT, class _Traits, class _Allocator>
basic_stringbuf<_CharT, _Traits, _Allocator>::basic_stringbuf(ios_base::openmode __wch)
: __hm_(0),
__mode_(__wch)
{
}
template <class _CharT, class _Traits, class _Allocator>
basic_stringbuf<_CharT, _Traits, _Allocator>::basic_stringbuf(const string_type& __s,
ios_base::openmode __wch)
: __str_(__s.get_allocator()),
__hm_(0),
__mode_(__wch)
{
str(__s);
}
# 351 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 3
template <class _CharT, class _Traits, class _Allocator>
void
basic_stringbuf<_CharT, _Traits, _Allocator>::swap(basic_stringbuf& __rhs)
{
char_type* __p = const_cast<char_type*>(__rhs.__str_.data());
ptrdiff_t __rbinp = -1;
ptrdiff_t __rninp = -1;
ptrdiff_t __reinp = -1;
if (__rhs.eback() != std::__1::__get_nullptr_t())
{
__rbinp = __rhs.eback() - __p;
__rninp = __rhs.gptr() - __p;
__reinp = __rhs.egptr() - __p;
}
ptrdiff_t __rbout = -1;
ptrdiff_t __rnout = -1;
ptrdiff_t __reout = -1;
if (__rhs.pbase() != std::__1::__get_nullptr_t())
{
__rbout = __rhs.pbase() - __p;
__rnout = __rhs.pptr() - __p;
__reout = __rhs.epptr() - __p;
}
ptrdiff_t __rhm = __rhs.__hm_ == std::__1::__get_nullptr_t() ? -1 : __rhs.__hm_ - __p;
__p = const_cast<char_type*>(__str_.data());
ptrdiff_t __lbinp = -1;
ptrdiff_t __lninp = -1;
ptrdiff_t __leinp = -1;
if (this->eback() != std::__1::__get_nullptr_t())
{
__lbinp = this->eback() - __p;
__lninp = this->gptr() - __p;
__leinp = this->egptr() - __p;
}
ptrdiff_t __lbout = -1;
ptrdiff_t __lnout = -1;
ptrdiff_t __leout = -1;
if (this->pbase() != std::__1::__get_nullptr_t())
{
__lbout = this->pbase() - __p;
__lnout = this->pptr() - __p;
__leout = this->epptr() - __p;
}
ptrdiff_t __lhm = __hm_ == std::__1::__get_nullptr_t() ? -1 : __hm_ - __p;
std::__1::swap(__mode_, __rhs.__mode_);
__str_.swap(__rhs.__str_);
__p = const_cast<char_type*>(__str_.data());
if (__rbinp != -1)
this->setg(__p + __rbinp, __p + __rninp, __p + __reinp);
else
this->setg(std::__1::__get_nullptr_t(), std::__1::__get_nullptr_t(), std::__1::__get_nullptr_t());
if (__rbout != -1)
{
this->setp(__p + __rbout, __p + __reout);
this->__pbump(__rnout);
}
else
this->setp(std::__1::__get_nullptr_t(), std::__1::__get_nullptr_t());
__hm_ = __rhm == -1 ? std::__1::__get_nullptr_t() : __p + __rhm;
__p = const_cast<char_type*>(__rhs.__str_.data());
if (__lbinp != -1)
__rhs.setg(__p + __lbinp, __p + __lninp, __p + __leinp);
else
__rhs.setg(std::__1::__get_nullptr_t(), std::__1::__get_nullptr_t(), std::__1::__get_nullptr_t());
if (__lbout != -1)
{
__rhs.setp(__p + __lbout, __p + __leout);
__rhs.__pbump(__lnout);
}
else
__rhs.setp(std::__1::__get_nullptr_t(), std::__1::__get_nullptr_t());
__rhs.__hm_ = __lhm == -1 ? std::__1::__get_nullptr_t() : __p + __lhm;
locale __tl = __rhs.getloc();
__rhs.pubimbue(this->getloc());
this->pubimbue(__tl);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(basic_stringbuf<_CharT, _Traits, _Allocator>& __x,
basic_stringbuf<_CharT, _Traits, _Allocator>& __y)
{
__x.swap(__y);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
basic_stringbuf<_CharT, _Traits, _Allocator>::str() const
{
if (__mode_ & ios_base::out)
{
if (__hm_ < this->pptr())
__hm_ = this->pptr();
return string_type(this->pbase(), __hm_, __str_.get_allocator());
}
else if (__mode_ & ios_base::in)
return string_type(this->eback(), this->egptr(), __str_.get_allocator());
return string_type(__str_.get_allocator());
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_stringbuf<_CharT, _Traits, _Allocator>::str(const string_type& __s)
{
__str_ = __s;
__hm_ = 0;
if (__mode_ & ios_base::in)
{
__hm_ = const_cast<char_type*>(__str_.data()) + __str_.size();
this->setg(const_cast<char_type*>(__str_.data()),
const_cast<char_type*>(__str_.data()),
__hm_);
}
if (__mode_ & ios_base::out)
{
typename string_type::size_type __sz = __str_.size();
__hm_ = const_cast<char_type*>(__str_.data()) + __sz;
__str_.resize(__str_.capacity());
this->setp(const_cast<char_type*>(__str_.data()),
const_cast<char_type*>(__str_.data()) + __str_.size());
if (__mode_ & (ios_base::app | ios_base::ate))
{
while (__sz > 2147483647)
{
this->pbump(2147483647);
__sz -= 2147483647;
}
if (__sz > 0)
this->pbump(__sz);
}
}
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_stringbuf<_CharT, _Traits, _Allocator>::int_type
basic_stringbuf<_CharT, _Traits, _Allocator>::underflow()
{
if (__hm_ < this->pptr())
__hm_ = this->pptr();
if (__mode_ & ios_base::in)
{
if (this->egptr() < __hm_)
this->setg(this->eback(), this->gptr(), __hm_);
if (this->gptr() < this->egptr())
return traits_type::to_int_type(*this->gptr());
}
return traits_type::eof();
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_stringbuf<_CharT, _Traits, _Allocator>::int_type
basic_stringbuf<_CharT, _Traits, _Allocator>::pbackfail(int_type __c)
{
if (__hm_ < this->pptr())
__hm_ = this->pptr();
if (this->eback() < this->gptr())
{
if (traits_type::eq_int_type(__c, traits_type::eof()))
{
this->setg(this->eback(), this->gptr()-1, __hm_);
return traits_type::not_eof(__c);
}
if ((__mode_ & ios_base::out) ||
traits_type::eq(traits_type::to_char_type(__c), this->gptr()[-1]))
{
this->setg(this->eback(), this->gptr()-1, __hm_);
*this->gptr() = traits_type::to_char_type(__c);
return __c;
}
}
return traits_type::eof();
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_stringbuf<_CharT, _Traits, _Allocator>::int_type
basic_stringbuf<_CharT, _Traits, _Allocator>::overflow(int_type __c)
{
if (!traits_type::eq_int_type(__c, traits_type::eof()))
{
ptrdiff_t __ninp = this->gptr() - this->eback();
if (this->pptr() == this->epptr())
{
if (!(__mode_ & ios_base::out))
return traits_type::eof();
try
{
ptrdiff_t __nout = this->pptr() - this->pbase();
ptrdiff_t __hm = __hm_ - this->pbase();
__str_.push_back(char_type());
__str_.resize(__str_.capacity());
char_type* __p = const_cast<char_type*>(__str_.data());
this->setp(__p, __p + __str_.size());
this->__pbump(__nout);
__hm_ = this->pbase() + __hm;
}
catch (...)
{
return traits_type::eof();
}
}
__hm_ = std::__1::max(this->pptr() + 1, __hm_);
if (__mode_ & ios_base::in)
{
char_type* __p = const_cast<char_type*>(__str_.data());
this->setg(__p, __p + __ninp, __hm_);
}
return this->sputc(__c);
}
return traits_type::not_eof(__c);
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_stringbuf<_CharT, _Traits, _Allocator>::pos_type
basic_stringbuf<_CharT, _Traits, _Allocator>::seekoff(off_type __off,
ios_base::seekdir __way,
ios_base::openmode __wch)
{
if (__hm_ < this->pptr())
__hm_ = this->pptr();
if ((__wch & (ios_base::in | ios_base::out)) == 0)
return pos_type(-1);
if ((__wch & (ios_base::in | ios_base::out)) == (ios_base::in | ios_base::out)
&& __way == ios_base::cur)
return pos_type(-1);
const ptrdiff_t __hm = __hm_ == std::__1::__get_nullptr_t() ? 0 : __hm_ - __str_.data();
off_type __noff;
switch (__way)
{
case ios_base::beg:
__noff = 0;
break;
case ios_base::cur:
if (__wch & ios_base::in)
__noff = this->gptr() - this->eback();
else
__noff = this->pptr() - this->pbase();
break;
case ios_base::end:
__noff = __hm;
break;
default:
return pos_type(-1);
}
__noff += __off;
if (__noff < 0 || __hm < __noff)
return pos_type(-1);
if (__noff != 0)
{
if ((__wch & ios_base::in) && this->gptr() == 0)
return pos_type(-1);
if ((__wch & ios_base::out) && this->pptr() == 0)
return pos_type(-1);
}
if (__wch & ios_base::in)
this->setg(this->eback(), this->eback() + __noff, __hm_);
if (__wch & ios_base::out)
{
this->setp(this->pbase(), this->epptr());
this->pbump(__noff);
}
return pos_type(__noff);
}
template <class _CharT, class _Traits, class _Allocator>
typename basic_stringbuf<_CharT, _Traits, _Allocator>::pos_type
basic_stringbuf<_CharT, _Traits, _Allocator>::seekpos(pos_type __sp,
ios_base::openmode __wch)
{
return seekoff(__sp, ios_base::beg, __wch);
}
template <class _CharT, class _Traits, class _Allocator>
class __attribute__ ((__type_visibility__("default"))) basic_istringstream
: public basic_istream<_CharT, _Traits>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
typedef _Allocator allocator_type;
typedef basic_string<char_type, traits_type, allocator_type> string_type;
private:
basic_stringbuf<char_type, traits_type, allocator_type> __sb_;
public:
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_istringstream(ios_base::openmode __wch = ios_base::in);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_istringstream(const string_type& __s,
ios_base::openmode __wch = ios_base::in);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(basic_istringstream& __rhs);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_stringbuf<char_type, traits_type, allocator_type>* rdbuf() const;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
string_type str() const;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void str(const string_type& __s);
};
template <class _CharT, class _Traits, class _Allocator>
basic_istringstream<_CharT, _Traits, _Allocator>::basic_istringstream(ios_base::openmode __wch)
: basic_istream<_CharT, _Traits>(&__sb_),
__sb_(__wch | ios_base::in)
{
}
template <class _CharT, class _Traits, class _Allocator>
basic_istringstream<_CharT, _Traits, _Allocator>::basic_istringstream(const string_type& __s,
ios_base::openmode __wch)
: basic_istream<_CharT, _Traits>(&__sb_),
__sb_(__s, __wch | ios_base::in)
{
}
# 708 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 3
template <class _CharT, class _Traits, class _Allocator>
void basic_istringstream<_CharT, _Traits, _Allocator>::swap(basic_istringstream& __rhs)
{
basic_istream<char_type, traits_type>::swap(__rhs);
__sb_.swap(__rhs.__sb_);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(basic_istringstream<_CharT, _Traits, _Allocator>& __x,
basic_istringstream<_CharT, _Traits, _Allocator>& __y)
{
__x.swap(__y);
}
template <class _CharT, class _Traits, class _Allocator>
basic_stringbuf<_CharT, _Traits, _Allocator>*
basic_istringstream<_CharT, _Traits, _Allocator>::rdbuf() const
{
return const_cast<basic_stringbuf<char_type, traits_type, allocator_type>*>(&__sb_);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
basic_istringstream<_CharT, _Traits, _Allocator>::str() const
{
return __sb_.str();
}
template <class _CharT, class _Traits, class _Allocator>
void basic_istringstream<_CharT, _Traits, _Allocator>::str(const string_type& __s)
{
__sb_.str(__s);
}
template <class _CharT, class _Traits, class _Allocator>
class __attribute__ ((__type_visibility__("default"))) basic_ostringstream
: public basic_ostream<_CharT, _Traits>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
typedef _Allocator allocator_type;
typedef basic_string<char_type, traits_type, allocator_type> string_type;
private:
basic_stringbuf<char_type, traits_type, allocator_type> __sb_;
public:
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_ostringstream(ios_base::openmode __wch = ios_base::out);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_ostringstream(const string_type& __s,
ios_base::openmode __wch = ios_base::out);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(basic_ostringstream& __rhs);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_stringbuf<char_type, traits_type, allocator_type>* rdbuf() const;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
string_type str() const;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void str(const string_type& __s);
};
template <class _CharT, class _Traits, class _Allocator>
basic_ostringstream<_CharT, _Traits, _Allocator>::basic_ostringstream(ios_base::openmode __wch)
: basic_ostream<_CharT, _Traits>(&__sb_),
__sb_(__wch | ios_base::out)
{
}
template <class _CharT, class _Traits, class _Allocator>
basic_ostringstream<_CharT, _Traits, _Allocator>::basic_ostringstream(const string_type& __s,
ios_base::openmode __wch)
: basic_ostream<_CharT, _Traits>(&__sb_),
__sb_(__s, __wch | ios_base::out)
{
}
# 825 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 3
template <class _CharT, class _Traits, class _Allocator>
void
basic_ostringstream<_CharT, _Traits, _Allocator>::swap(basic_ostringstream& __rhs)
{
basic_ostream<char_type, traits_type>::swap(__rhs);
__sb_.swap(__rhs.__sb_);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(basic_ostringstream<_CharT, _Traits, _Allocator>& __x,
basic_ostringstream<_CharT, _Traits, _Allocator>& __y)
{
__x.swap(__y);
}
template <class _CharT, class _Traits, class _Allocator>
basic_stringbuf<_CharT, _Traits, _Allocator>*
basic_ostringstream<_CharT, _Traits, _Allocator>::rdbuf() const
{
return const_cast<basic_stringbuf<char_type, traits_type, allocator_type>*>(&__sb_);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
basic_ostringstream<_CharT, _Traits, _Allocator>::str() const
{
return __sb_.str();
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_ostringstream<_CharT, _Traits, _Allocator>::str(const string_type& __s)
{
__sb_.str(__s);
}
template <class _CharT, class _Traits, class _Allocator>
class __attribute__ ((__type_visibility__("default"))) basic_stringstream
: public basic_iostream<_CharT, _Traits>
{
public:
typedef _CharT char_type;
typedef _Traits traits_type;
typedef typename traits_type::int_type int_type;
typedef typename traits_type::pos_type pos_type;
typedef typename traits_type::off_type off_type;
typedef _Allocator allocator_type;
typedef basic_string<char_type, traits_type, allocator_type> string_type;
private:
basic_stringbuf<char_type, traits_type, allocator_type> __sb_;
public:
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_stringstream(ios_base::openmode __wch = ios_base::in | ios_base::out);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
explicit basic_stringstream(const string_type& __s,
ios_base::openmode __wch = ios_base::in | ios_base::out);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void swap(basic_stringstream& __rhs);
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
basic_stringbuf<char_type, traits_type, allocator_type>* rdbuf() const;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
string_type str() const;
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void str(const string_type& __s);
};
template <class _CharT, class _Traits, class _Allocator>
basic_stringstream<_CharT, _Traits, _Allocator>::basic_stringstream(ios_base::openmode __wch)
: basic_iostream<_CharT, _Traits>(&__sb_),
__sb_(__wch)
{
}
template <class _CharT, class _Traits, class _Allocator>
basic_stringstream<_CharT, _Traits, _Allocator>::basic_stringstream(const string_type& __s,
ios_base::openmode __wch)
: basic_iostream<_CharT, _Traits>(&__sb_),
__sb_(__s, __wch)
{
}
# 944 "/Library/Developer/CommandLineTools/usr/include/c++/v1/sstream" 3
template <class _CharT, class _Traits, class _Allocator>
void
basic_stringstream<_CharT, _Traits, _Allocator>::swap(basic_stringstream& __rhs)
{
basic_iostream<char_type, traits_type>::swap(__rhs);
__sb_.swap(__rhs.__sb_);
}
template <class _CharT, class _Traits, class _Allocator>
inline __attribute__ ((__visibility__("hidden"), __always_inline__))
void
swap(basic_stringstream<_CharT, _Traits, _Allocator>& __x,
basic_stringstream<_CharT, _Traits, _Allocator>& __y)
{
__x.swap(__y);
}
template <class _CharT, class _Traits, class _Allocator>
basic_stringbuf<_CharT, _Traits, _Allocator>*
basic_stringstream<_CharT, _Traits, _Allocator>::rdbuf() const
{
return const_cast<basic_stringbuf<char_type, traits_type, allocator_type>*>(&__sb_);
}
template <class _CharT, class _Traits, class _Allocator>
basic_string<_CharT, _Traits, _Allocator>
basic_stringstream<_CharT, _Traits, _Allocator>::str() const
{
return __sb_.str();
}
template <class _CharT, class _Traits, class _Allocator>
void
basic_stringstream<_CharT, _Traits, _Allocator>::str(const string_type& __s)
{
__sb_.str(__s);
}
} }
# 20 "./src/include/node_sodium.h" 2
# 9 "./src/crypto_pwhash_algos.cc" 2
# 1 "./src/include/crypto_pwhash_algos.h" 1
# 10 "./src/crypto_pwhash_algos.cc" 2
Napi::Value bind_crypto_pwhash_argon2i_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (6)) { Napi::Error::New(env, "arguments must be: output buffer, password buffer, salt buffer, oLimit, memLimit").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "out" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<unsigned char> out_buffer = info[_arg].As<Napi::Buffer<unsigned char>>(); unsigned char *out = (unsigned char *) out_buffer.Data(); unsigned long long out_size = out_buffer.Length(); if( out_size == 0 ) { }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<char> passwd_buffer = info[_arg].As<Napi::Buffer<char>>(); char *passwd = (char *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "salt" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<unsigned char> salt_buffer = info[_arg].As<Napi::Buffer<unsigned char>>(); unsigned char *salt = (unsigned char *) salt_buffer.Data(); unsigned long long salt_size = salt_buffer.Length(); if( salt_size == 0 ) { }; if( salt_size != crypto_pwhash_argon2i_SALTBYTES ) { std::ostringstream oss; oss << "argument " << "salt" << " must be " << crypto_pwhash_argon2i_SALTBYTES << " bytes long, but got " << salt_size ; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t oppLimit; if (info[_arg].IsNumber()) { oppLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t memLimit; if (info[_arg].IsNumber()) { memLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t alg; if (info[_arg].IsNumber()) { alg = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; if (crypto_pwhash_argon2i (out, out_size, passwd, passwd_size, salt, oppLimit, memLimit, alg) == 0) { return Napi::Boolean::New(env, true); } return Napi::Boolean::New(env, false); }
Napi::Value bind_crypto_pwhash_argon2i_str_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (3)) { Napi::Error::New(env, "arguments must be: password buffer, oLimit, memLimit").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<char> passwd_buffer = info[_arg].As<Napi::Buffer<char>>(); char *passwd = (char *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; size_t oppLimit; if (info[_arg].IsNumber()) { oppLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t memLimit; if (info[_arg].IsNumber()) { memLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; Napi::Buffer<unsigned char> out = Napi::Buffer<unsigned char>::New(info.Env(), crypto_pwhash_argon2i_STRBYTES); unsigned char* out_ptr = (unsigned char*) out.Data(); if( *out_ptr == 0 ) { }; if( crypto_pwhash_argon2i_str ((char*)out_ptr, passwd, passwd_size, oppLimit, memLimit) == 0 ) { return out; } return Napi::Boolean::New(env, false); } Napi::Value bind_crypto_pwhash_argon2i_str_verify_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (2)) { Napi::Error::New(env, "arguments must be: pwhash string, password").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "hash" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<unsigned char> hash_buffer = info[_arg].As<Napi::Buffer<unsigned char>>(); unsigned char *hash = (unsigned char *) hash_buffer.Data(); unsigned long long hash_size = hash_buffer.Length(); if( hash_size == 0 ) { }; if( hash_size != crypto_pwhash_argon2i_STRBYTES ) { std::ostringstream oss; oss << "argument " << "hash" << " must be " << crypto_pwhash_argon2i_STRBYTES << " bytes long, but got " << hash_size ; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<char> passwd_buffer = info[_arg].As<Napi::Buffer<char>>(); char *passwd = (char *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; if (crypto_pwhash_argon2i_str_verify((char*)hash, passwd, passwd_size) == 0) { return Napi::Boolean::New(env, true); } return Napi::Boolean::New(env, false); } Napi::Value bind_crypto_pwhash_argon2i_opslimit_interactive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_argon2i_opslimit_interactive()); } Napi::Value bind_crypto_pwhash_argon2i_memlimit_interactive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_argon2i_memlimit_interactive()); } Napi::Value bind_crypto_pwhash_argon2i_opslimit_sensitive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_argon2i_opslimit_sensitive()); } Napi::Value bind_crypto_pwhash_argon2i_memlimit_sensitive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_argon2i_memlimit_sensitive()); } Napi::Value bind_crypto_pwhash_argon2i_saltbytes_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_argon2i_saltbytes()); } Napi::Value bind_crypto_pwhash_argon2i_strbytes_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_argon2i_strbytes()); } Napi::Value bind_crypto_pwhash_argon2i_strprefix_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::String::New(env, crypto_pwhash_argon2i_strprefix()); }
Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (5)) { Napi::Error::New(env, "arguments must be: output buffer, password buffer, salt buffer, oLimit, memLimit").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "out" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<unsigned char> out_buffer = info[_arg].As<Napi::Buffer<unsigned char>>(); unsigned char *out = (unsigned char *) out_buffer.Data(); unsigned long long out_size = out_buffer.Length(); if( out_size == 0 ) { }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<char> passwd_buffer = info[_arg].As<Napi::Buffer<char>>(); char *passwd = (char *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "salt" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<unsigned char> salt_buffer = info[_arg].As<Napi::Buffer<unsigned char>>(); unsigned char *salt = (unsigned char *) salt_buffer.Data(); unsigned long long salt_size = salt_buffer.Length(); if( salt_size == 0 ) { }; if( salt_size != crypto_pwhash_scryptsalsa208sha256_SALTBYTES ) { std::ostringstream oss; oss << "argument " << "salt" << " must be " << crypto_pwhash_scryptsalsa208sha256_SALTBYTES << " bytes long, but got " << salt_size ; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t oppLimit; if (info[_arg].IsNumber()) { oppLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t memLimit; if (info[_arg].IsNumber()) { memLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; if (crypto_pwhash_scryptsalsa208sha256 (out, out_size, passwd, passwd_size, salt, oppLimit, memLimit) == 0) { return Napi::Boolean::New(env, true); } return Napi::Boolean::New(env, false); }
Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_str_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (3)) { Napi::Error::New(env, "arguments must be: password buffer, oLimit, memLimit").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<char> passwd_buffer = info[_arg].As<Napi::Buffer<char>>(); char *passwd = (char *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; size_t oppLimit; if (info[_arg].IsNumber()) { oppLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t memLimit; if (info[_arg].IsNumber()) { memLimit = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; Napi::Buffer<unsigned char> out = Napi::Buffer<unsigned char>::New(info.Env(), crypto_pwhash_scryptsalsa208sha256_STRBYTES); unsigned char* out_ptr = (unsigned char*) out.Data(); if( *out_ptr == 0 ) { }; if( crypto_pwhash_scryptsalsa208sha256_str ((char*)out_ptr, passwd, passwd_size, oppLimit, memLimit) == 0 ) { return out; } return Napi::Boolean::New(env, false); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_str_verify_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (2)) { Napi::Error::New(env, "arguments must be: pwhash string, password").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "hash" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<unsigned char> hash_buffer = info[_arg].As<Napi::Buffer<unsigned char>>(); unsigned char *hash = (unsigned char *) hash_buffer.Data(); unsigned long long hash_size = hash_buffer.Length(); if( hash_size == 0 ) { }; if( hash_size != crypto_pwhash_scryptsalsa208sha256_STRBYTES ) { std::ostringstream oss; oss << "argument " << "hash" << " must be " << crypto_pwhash_scryptsalsa208sha256_STRBYTES << " bytes long, but got " << hash_size ; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<char> passwd_buffer = info[_arg].As<Napi::Buffer<char>>(); char *passwd = (char *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; if (crypto_pwhash_scryptsalsa208sha256_str_verify((char*)hash, passwd, passwd_size) == 0) { return Napi::Boolean::New(env, true); } return Napi::Boolean::New(env, false); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_opslimit_interactive()); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_memlimit_interactive()); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive()); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive()); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_saltbytes_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_saltbytes()); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_strbytes_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_strbytes()); } Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_strprefix_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); return Napi::String::New(env, crypto_pwhash_scryptsalsa208sha256_strprefix()); }
Napi::Value bind_crypto_pwhash_scryptsalsa208sha256_ll_(const Napi::CallbackInfo& info) { Napi::Env env = info.Env(); int _arg = 0; if (info.Length() < (6)) { Napi::Error::New(env, "arguments must be: password buffer, salt buffer, N, r, p, output buffer").ThrowAsJavaScriptException(); return env.Null(); }; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "passwd" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<uint8_t> passwd_buffer = info[_arg].As<Napi::Buffer<uint8_t>>(); uint8_t *passwd = (uint8_t *) passwd_buffer.Data(); unsigned long long passwd_size = passwd_buffer.Length(); if( passwd_size == 0 ) { }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "salt" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<uint8_t> salt_buffer = info[_arg].As<Napi::Buffer<uint8_t>>(); uint8_t *salt = (uint8_t *) salt_buffer.Data(); unsigned long long salt_size = salt_buffer.Length(); if( salt_size == 0 ) { }; _arg++; size_t N; if (info[_arg].IsNumber()) { N = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t r; if (info[_arg].IsNumber()) { r = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; size_t p; if (info[_arg].IsNumber()) { p = info[_arg].As<Napi::Number>().Uint32Value(); } else { Napi::Error::New(env, "argument size must be a number").ThrowAsJavaScriptException(); return env.Null(); }; _arg++; if (!info[_arg].IsBuffer()) { std::ostringstream oss; oss << "argument " << "out" << " must be a buffer"; Napi::Error::New(env, oss.str().c_str()).ThrowAsJavaScriptException(); return env.Null(); }; Napi::Buffer<uint8_t> out_buffer = info[_arg].As<Napi::Buffer<uint8_t>>(); uint8_t *out = (uint8_t *) out_buffer.Data(); unsigned long long out_size = out_buffer.Length(); if( out_size == 0 ) { }; _arg++; if (crypto_pwhash_scryptsalsa208sha256_ll(passwd, passwd_size, salt, salt_size, N, r, p, out, out_size) == 0) { return Napi::Boolean::New(env, true); } return Napi::Boolean::New(env, false); }
void register_crypto_pwhash_algos(Napi::Env env, Napi::Object exports) {
exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_str"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_str_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_str_verify"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_str_verify_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_opslimit_interactive"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_opslimit_interactive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_memlimit_interactive"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_memlimit_interactive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_opslimit_sensitive"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_opslimit_sensitive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_memlimit_sensitive"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_memlimit_sensitive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_saltbytes"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_saltbytes_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_strbytes"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_strbytes_)); exports.Set(Napi::String::New(env, "crypto_pwhash_argon2i_strprefix"), Napi::Function::New(env, bind_crypto_pwhash_argon2i_strprefix_)); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_OPSLIMIT_INTERACTIVE"), Napi::Number::New(env, crypto_pwhash_argon2i_OPSLIMIT_INTERACTIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_MEMLIMIT_INTERACTIVE"), Napi::Number::New(env, crypto_pwhash_argon2i_MEMLIMIT_INTERACTIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_OPSLIMIT_SENSITIVE"), Napi::Number::New(env, crypto_pwhash_argon2i_OPSLIMIT_SENSITIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_MEMLIMIT_SENSITIVE"), Napi::Number::New(env, crypto_pwhash_argon2i_MEMLIMIT_SENSITIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_SALTBYTES"), Napi::Number::New(env, crypto_pwhash_argon2i_SALTBYTES), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_STRBYTES"), Napi::Number::New(env, crypto_pwhash_argon2i_STRBYTES), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_argon2i_STRPREFIX"), Napi::String::New(env, crypto_pwhash_argon2i_STRPREFIX), napi_default ) );;
exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_str"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_str_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_str_verify"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_str_verify_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_opslimit_interactive"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_memlimit_interactive"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_saltbytes"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_saltbytes_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_strbytes"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_strbytes_)); exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_strprefix"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_strprefix_)); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_INTERACTIVE"), Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_INTERACTIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_INTERACTIVE"), Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_INTERACTIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_SENSITIVE"), Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_SENSITIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_SENSITIVE"), Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_SENSITIVE), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_SALTBYTES"), Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_SALTBYTES), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_STRBYTES"), Napi::Number::New(env, crypto_pwhash_scryptsalsa208sha256_STRBYTES), napi_default ) ); exports.DefineProperty( Napi::PropertyDescriptor::Value( Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_STRPREFIX"), Napi::String::New(env, crypto_pwhash_scryptsalsa208sha256_STRPREFIX), napi_default ) );;
exports.Set(Napi::String::New(env, "crypto_pwhash_scryptsalsa208sha256_ll"), Napi::Function::New(env, bind_crypto_pwhash_scryptsalsa208sha256_ll_));
}