h$      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                                                                                Errno provided by libuv(c) Winterland, 2017-2018BSDdrkoster@qq.com experimental non-portable Safe-Inferredt]Z-IOtoo many links^Z-IOno such device or address_Z-IO end of file`Z-IO unknown erroraZ-IOcross-device link not permittedbZ-IOtext file is busycZ-IOconnection timed outdZ-IOno such processeZ-IO invalid seekfZ-IO-cannot send after transport endpoint shutdowngZ-IOread-only file systemhZ-IOresult too largeiZ-IOprotocol wrong type for socketjZ-IOprotocol not supportedkZ-IOprotocol errorlZ-IO broken pipemZ-IOoperation not permittednZ-IO!operation not supported on socketoZ-IOsocket operation on non-socketpZ-IOdirectory not emptyqZ-IOnot a directoryrZ-IOsocket is not connectedsZ-IOfunction not implementedtZ-IOno space left on deviceuZ-IOprotocol not availablevZ-IOmachine is not on the networkwZ-IOnot enough memoryxZ-IOno such file or directoryyZ-IOno such devicezZ-IOno buffer space available{Z-IOfile table overflow|Z-IOnetwork is unreachable}Z-IOnetwork is down~Z-IO name too longZ-IOmessage too longZ-IOtoo many open filesZ-IO#too many symbolic links encounteredZ-IO illegal operation on a directoryZ-IOsocket is already connectedZ-IO i/o errorZ-IOinvalid argumentZ-IOinterrupted system callZ-IOhost is unreachableZ-IOfile too largeZ-IO#bad address in system call argumentZ-IOfile already existsZ-IOdestination address requiredZ-IOconnection reset by peerZ-IOconnection refusedZ-IO software caused connection abortZ-IOinvalid Unicode characterZ-IOoperation canceledZ-IOresource busy or lockedZ-IObad file descriptorZ-IOconnection already in progressZ-IOsocket type not supportedZ-IO%service not available for socket typeZ-IOresolved protocol is unknownZ-IOargument buffer overflowZ-IOunknown node or serviceZ-IO no addressZ-IO out of memoryZ-IOai_family not supportedZ-IOpermanent failureZ-IOrequest canceledZ-IOinvalid value for hintsZ-IObad ai_flags valueZ-IOtemporary failureZ-IOaddress family not supportedZ-IO resource temporarily unavailableZ-IOaddress family not supportedZ-IOaddress not availableZ-IOaddress already in useZ-IOpermission deniedZ-IOargument list too long[\]^_`abcdefghijklmnopqrstuvwxyz{|}~\[~}|{zyxwvutsrqponmlkjihgfedcba`_^]Extensible IO exceptions(c) Dong Han, 2017-2018BSDwinterland1989@gmail.com experimental non-portableNone 3?" Z-IOIO exceptions informations.Z-IO8the errno name, e.g. EADDRINUSE, etc. empty if no errno.Z-IOdescription for this io error, can be errno description, or some custom description if no errno.Z-IOlightweight partial call-stackZ-IOThe root type of all io exceptions, you can catch all io exception by catching this root type.Z-IOThrow  if allocation return a .Z-IOThrow appropriate IO exception if return value < 0 (libuv's convention).Z-IOThrow appropriate IO exception if return value < 0, otherwise ignore the result.Z-IOThrow  with name ECLOSED& and description 'resource is closed'.Z-IOthe allocation actionZ-IO the IO actionZ-IO the IO action ! "#$%'&)(+*-,/.103284576;:9<=>?@ABCDHEGFILJKQNPOXRSTUVWYZM ! "#$%'&)(+*-,/.103284576;:9<=>?@ABCDHEGFILJKJQNPOXRSTUVWZMYTCP/UDP socket address API(c) Winterland, 2018BSDdrkoster@qq.com experimental non-portableNone3)Z-IOUse the Num! instance (i.e. use a literal or ) to create a  PortNumber. value with the correct network-byte-ordering.1 :: PortNumber1read "1" :: PortNumber1Z-IO'Independent of endianness. For example ::1 is stored as  (0, 0, 0, 1).For direct manipulation prefer  and .Z-IO'Independent of endianness. For example  127.0.0.1 is stored as (127, 0, 0, 1).For direct manipulation prefer  and .Z-IO&IPv4 or IPv6 socket address, i.e. the  sockaddr_in or  sockaddr_in6 struct.Z-IOUsed in getAddrInfo hints, for any type can be returned by getAddrInfoZ-IOInternet Protocol version 6Z-IOinternetwork: UDP, TCP, etcZ-IO unspecifiedZ-IOShow an IPv6 address in the most appropriate notation, based on recommended representation proposed by  "http://tools.ietf.org/html/rfc5952RFC 5952./The implementation is completely compatible with the current implementation of the  inet_ntop function in glibc./Z-IO 0.0.0.0Z-IO 255.255.255.255Z-IO 255.255.255.255Z-IO  127.0.0.1Z-IO  224.0.0.0Z-IO  224.0.0.1Z-IO  224.0.0.255Z-IO Converts  to representation-independent IPv4 quadruple. For example for  127.0.0.1 the function will return (127, 0, 0, 1) regardless of host endianness.Z-IOConverts IPv4 quadruple to .Z-IO ::Z-IO ::133"Low resolution (0.1s) timing wheel(c) Dong Han, 2017-2018BSDwinterland1989@gmail.com experimental non-portableNone8Z-IOTimer registered by  or .Z-IO=Create new low resolution timer manager on capability change.Since low resolution timer manager is not hooked into RTS, you're responsible to call this function after you call > to match timer manager array size with new capability number.This is not a must though, when we fetch timer manager we always take a modulo.Z-IOGet a  for current thread.Z-IO+Check if a timer manager's wheel is turning#This is mostly for testing purpose.Z-IORegister a new timer on current capability's timer manager, start the timing wheel if it's not turning.If the action could block, you may want to run it in another thread. Example to kill a thread after 10s: 4 registerLowResTimer 100 (forkIO $ killThread tid) Z-IO ( t action)Z-IOSame as %, but allow you choose timer manager.Z-IO2Query how many seconds remain before timer firing.;A return value <= 0 indictate the timer is firing or fired.Z-IO+Cancel a timer, return the remaining ticks.6This function have no effect after the timer is fired.Z-IO void . cancelLowResTimerZ-IO similar to <, this function put a limit on time which an IO can consume.,Note timeoutLowRes is also implemented with Q underhood, which can have some surprising effects on some devices, e.g. use  with reading or writing on UVStreams may close the UVStream: once a reading or writing is not able to be done in time.Z-IO Similar to , but raise a & to current thread instead of return  if timeout.Z-IO-Cache result of an IO action for give time t.This combinator is useful when you want to share IO result within a period, the action will be called on demand, and the result will be cached for t milliseconds.One common way to get a shared periodical updated value is to start a seperate thread and do calculation periodically, but doing that will stop system from being idle, which stop idle GC from running, and in turn disable deadlock detection, which is too bad. This function solves that.Z-IO-Throttle an IO action without caching result.The IO action will run at leading edge. i.e. once run, during following (t/10)s throttled action will no-ops./Note the action will run in the calling thread.Z-IO Similar to  but run action in trailing edgeThe IO action will run at trailing edge. i.e. no matter how many times throttled action are called, original action will run only once after (t/10)s.4Note the action will be run in a new created thread.Z-IOtimeout in unit of 0.1sZ-IO3the action you want to perform, it should not blockZ-IOtimeout in unit of 0.1sZ-IO3the action you want to perform, it should not blockZ-IOa low resolution timer managerZ-IOtimeout in unit of 0.1sZ-IO3the action you want to perform, it should not blockZ-IOtimeout in unit of 0.1sZ-IOtimeout in unit of 0.1sZ-IOcache time in unit of 0.1sZ-IOthe original IO actionZ-IOthrottled IO actionZ-IOcache time in unit of 0.1sZ-IOthe original IO actionZ-IOthrottled IO actionZ-IOthe original IO actionZ-IOthrottled IO actionThe Resource monad(c) Dong Han, 2017BSDwinterland1989@gmail.com experimental non-portableNone3F- Z-IO.A high performance resource pool based on STM.We choose to not divide pool into strips due to the difficults in resource balancing. If there is a high contention on resource (see ), just increase the maximum number of resources can be opened.Z-IOA  is an  action which acquires some resource of type a and also returns a finalizer of type IO () that releases the resource.The only safe way to use a  is . and 'withResource'', You should not use the  field directly, unless you want to implement your own resource management. In the later case, you should @  since some resource initializations may assume async exceptions are masked.+ instance is provided so that you can lift  computation inside %, this is convenient for propagating  around since many  computations carry finalizers.3A convention in Z-IO is that functions returning a  should be named in initXXX format, users are strongly recommended to follow this convention.3There're two additional guarantees we made in Z-IO:8All resources in Z-IO can track its own liveness, throw  exception using  or ) when used after resource is closed.5All resources' clean up action in Z-IO is idempotent.Library authors providing initXXX1 are also encouraged to provide these guarantees.Z-IOCreate  from create and release action.Note, resource doesn't open resource itself, resource is created when you use with / with'.Z-IOCreate  from create and release action.This function is useful when you want to add some initialization and clean up action inside  monad.Z-IOCreate a new resource and run some computation, resource is guarantee to be closed.Be care don't leak the resource through computation return value, because after the computation finishes, the resource is closed already.Z-IOCreate a new resource and run some computation, resource is guarantee to be closed.The difference from with is that the computation will receive an extra close action, which can be used to close the resource early before the whole computation finished, the close action can be called multiple times, only the first call will clean up the resource.Z-IO&Initialize a resource pool with given Like other initXXX functions, this function won't open a resource pool until you use . And this resource pool follow the same resource management pattern like other resources.Z-IOGet a resource pool's 7This function is useful when debug, under load lots of  may indicate contention on resources, i.e. the limit on maximum number of resources can be opened should be adjusted to a higher number. On the otherhand, lots of 0 may indicate there're too much free resources.Z-IO8Obtain the pooled resource inside a given resource pool.You shouldn't use 3 with this resource after you closed the pool, an  will be thrown.Z-IO)maximum number of resources can be openedZ-IOamount of time after which an unused resource can be released (in seconds).Buffered IO interface(c) Dong Han, 2017-2018BSDwinterland1989@gmail.com experimental non-portableNone#$3QZ-IO+Output device with buffer, NOT THREAD SAFE!A  should not be used in multiple threads, there's no locking mechanism to protect buffering state.A * device should only be used with a single , If multiple  s are opened on a same ( device, the output will be interleaved.Z-IO*Input device with buffer, NOT THREAD SAFE!A  should not be used in multiple threads, there's no locking mechanism to protect buffering state.A * device should only be used with a single , If multiple  s are opened on a same $ device, the behaviour is undefined.Z-IO Output device should not return until all data are written (may not necessarily flushed to hardware, that should be done in device specific way).Z-IO Input device should return 0 on EOF.Z-IO7Open a new buffered input with given buffer size, e.g. .Z-IO8Open a new buffered output with given buffer size, e.g. .Z-IORequest bytes from .$The buffering logic is quite simple:If we have pushed back bytes, directly return it, otherwise we read using buffer size. If we read N bytes, and N is larger than half of the buffer size, then we freeze buffer and return, otherwise we copy buffer into result and reuse buffer afterward.Z-IORead exactly N bytes&If EOF reached before N bytes read, a  will be thrownZ-IORead all chunks from a .Z-IORead all chunks from a , and concat chunks together.Z-IOPush bytes back into buffer.Z-IORead buffer and parse with Parser.This function will continuously draw data from input before parsing finish.Z-IORead until reach a magic bytesIf EOF is reached before meet a magic byte, partial bytes are returned.Z-IORead until reach a magic bytes.If EOF is reached before meet a magic byte, a  will be thrown.Z-IO)Read to a linefeed ('n' or 'rn'), return Bytes before it.If EOF is reached before meet a magic byte, partial line is returned.Z-IO)Read to a linefeed ('n' or 'rn'), return Bytes before it.$If EOF reached before meet a 'n', a  will be thrown.Z-IOWrite  into buffered handle.Copy  to buffer if it can hold, otherwise write both buffer(if not empty) and .Z-IOWrite  into buffered handle.Copy  to buffer if it can hold, otherwise write both buffer(if not empty) and .Z-IO2Flush the buffer into output device(if not empty).Z-IOInput buffer sizeZ-IOOutput buffer sizelibuv operations(c) Winterland, 2017-2018BSDdrkoster@qq.com experimental non-portableNone  8fR(Z-IOFlags control copying.: If present, uv_fs_copyfile() will fail with UV_EEXIST if the destination path already exists. The default behavior is to overwrite the destination if it exists.: If present, uv_fs_copyfile() will attempt to create a copy-on-write reflink. If the underlying platform does not support copy-on-write, then a fallback copy mechanism is used.Z-IOTerminal mode.When in  mode, input is always available character-by-character, not including modifiers. Additionally, all special processing of characters by the terminal is disabled, including echoing input characters. Note that CTRL+C will no longer cause a SIGINT when in this mode.Z-IO.UVSlotUnSafe wrap a slot which may not have a MVar in blocking table, i.e. the blocking table need to be resized.Z-IOuv_run with safe FFI.Z-IOuv_run with usafe FFI.Z-IO$Open the file for write-only access.Z-IOIf the file exists and is a regular file, and the file is opened successfully for write access, its length shall be truncated to zero.Z-IOThe file is temporary and should not be flushed to disk if possible.Note  o_TEMPORARY" is only supported on Windows via FILE_ATTRIBUTE_TEMPORARY.Z-IOThe file is opened for synchronous IO. Write operations will complete once all data and all metadata are flushed to disk.Note o_SYNC is supported on Windows via FILE_FLAG_WRITE_THROUGH.Z-IOOpen the symbolic link itself rather than the resource it points to.Z-IOThe file is temporary and should not be flushed to disk if possible.Note  o_SHORT_LIVED" is only supported on Windows via FILE_ATTRIBUTE_TEMPORARY.Z-IOAccess is intended to be sequential from beginning to end. The system can use this as a hint to optimize file caching.Note  o_SEQUENTIAL" is only supported on Windows via FILE_FLAG_SEQUENTIAL_SCAN.Z-IO$Open the file for read-write access.Z-IO#Open the file for read-only access.Z-IOAccess is intended to be random. The system can use this as a hint to optimize file caching.Note o_RANDOM" is only supported on Windows via FILE_FLAG_RANDOM_ACCESS.Z-IOOpen the file in nonblocking mode if possible. (Definitely not useful in Z-IO)Note  o_NONBLOCK is not supported on Windows. (Not useful on regular file anyway)Z-IO.If the path is a symbolic link, fail the open.Note  o_NOFOLLOW is not supported on Windows.Z-IOIf the path identifies a terminal device, opening the path will not cause that terminal to become the controlling terminal for the process (if the process does not already have one). (Not sure if this flag is useful)Note o_NOCTTY is not supported on Windows.Z-IO9Do not update the file access time when the file is read.Note  o_NOATIME is not supported on Windows.Z-IO$Atomically obtain an exclusive lock.Note UV_FS_O_EXLOCK is only supported on macOS and Windows. (libuv: Changed in version 1.17.0: support is added for Windows.)Z-IOIf the o_CREAT8 flag is set and the file already exists, fail the open.!Note In general, the behavior of o_EXCL$ is undefined if it is used without o_CREAT4. There is one exception: on Linux 2.6 and later, o_EXCL can be used without o_CREAT if pathname refers to a block device. If the block device is in use by the system (e.g., mounted), the open will fail with the error EBUSY.Z-IOThe file is opened for synchronous IO. Write operations will complete once all data and a minimum of metadata are flushed to disk.Note o_DSYNC is supported on Windows via FILE_FLAG_WRITE_THROUGH.Z-IOIf the path is not a directory, fail the open. (Not useful on regular file)Note  o_DIRECTORY is not supported on Windows.Z-IOFile IO is done directly to and from user-space buffers, which must be aligned. Buffer size and address should be a multiple of the physical sector size of the block device, (DO NOT USE WITH Z-IO's  BufferedIO)Z-IO1The file is created if it does not already exist.Z-IOThe file is opened in append mode. Before each write, the file offset is positioned at the end of the file.Z-IO4Default mode for open, 0o666(readable and writable).Z-IO$00001 others have execute permissionZ-IO"00002 others have write permissionZ-IO!00004 others have read permissionZ-IO400007 others have read, write and execute permissionZ-IO"00010 group has execute permissionZ-IO 00020 group has write permissionZ-IO00040 group has read permissionZ-IO200070 group has read, write and execute permissionZ-IO!00100 user has execute permissionZ-IO00200 user has write permissionZ-IO00400 user has read permissionZ-IO>00700 user (file owner) has read, write and execute permissionZ-IO-Peek loop data pointer from uv loop pointer. Filesystem IO(c) Dong Han, 2017~2019BSDwinterland1989@gmail.com experimental non-portableNone38Z-IO- and its operations are NOT thread safe, use MVar  in multiple threadslibuv implements read and write method with both implict and explict offset capable. Implict offset interface is provided by  / 5 instances. Explict offset interface is provided by  / .Z-IORead file with given offset,Read length may be smaller than buffer size.Z-IOWrite buffer to file4This function will loop until all bytes are written.Z-IO init a file , which open a file when used.Resource closing is thread safe, on some versions of OSX, repeatly open and close same file 0 may result in shared memory object error, use  to avoid that.Z-IOEquivalent to  http://linux.die.net/man/2/mkdirmkdir(2).2Note mode is currently not implemented on Windows.Z-IOEquivalent to  !http://linux.die.net/man/2/unlink unlink(2).Z-IOEquivalent to mkdtemp"http://linux.die.net/man/3/mkdtempCreates a temporary directory in the most secure manner possible. There are no race conditions in the directory@s creation. The directory is readable, writable, and searchable only by the creating user ID. The user of mkdtemp() is responsible for deleting the temporary directory and its contents when done with it.Note: the argument is the prefix of the temporary directory, so no need to add XXXXXX ending.Z-IOEquivalent to  http://linux.die.net/man/2/rmdirrmdir(2).Z-IOEquivalent to  "http://linux.die.net/man/3/scandir scandir(3).Note Unlike scandir(3), this function does not return the @.@ and @..@ entries.Note On Linux, getting the type of an entry is only supported by some file systems (btrfs, ext2, ext3 and ext4 at the time of this writing), check the  #http://linux.die.net/man/2/getdents getdents(2) man page.Z-IOEquivalent to http://linux.die.net/man/2/statstat(2)Z-IOEquivalent to http://linux.die.net/man/2/lstatlstat(2)Z-IOEquivalent to http://linux.die.net/man/2/fstatfstat(2)Z-IOEquivalent to  !http://linux.die.net/man/2/rename rename(2).Note On Windows if this function fails with UV_EBUSY, UV_EPERM or UV_EACCES, it will retry to rename the file up to four times with 250ms wait between attempts before giving up. If both path and new_path are existing directories this function will work only if target directory is empty.Z-IOEquivalent to  http://linux.die.net/man/2/fsyncfsync(2).Z-IOEquivalent to  $http://linux.die.net/man/2/fdatasync fdatasync(2).Z-IOEquivalent to  $http://linux.die.net/man/2/ftruncate ftruncate(2).Z-IO$Copies a file from path to new_path.Warning: If the destination path is created, but an error occurs while copying the data, then the destination path is removed. There is a brief window of time between closing and removing the file where another process could access the file.Z-IOEquivalent to  !http://linux.die.net/man/2/access access(2)- on Unix. Windows uses GetFileAttributesW().Z-IOEquivalent to  http://linux.die.net/man/2/chmodchmod(2).Z-IOEquivalent to  !http://linux.die.net/man/2/fchmod fchmod(2).Z-IOEquivalent to  http://linux.die.net/man/2/utimeutime(2). libuv choose  type due to cross platform concerns, we only provide micro-second precision:second = v,nanosecond = (v * 1000000) % 1000000 * 1000;$second and nanosecond are fields in  respectively.Note libuv prior to v1.23.1 have issues which may result in nanosecond not set,  doesn't have that issue.Z-IOEquivalent to  !http://linux.die.net/man/2/futime futime(2).Same precision notes with .Z-IOEquivalent to  http://linux.die.net/man/2/linklink(2).Z-IOEquivalent to  "http://linux.die.net/man/2/symlink symlink(2).| Note On Windows the flags parameter can be specified to control how the symlink will be created.,: indicates that path points to a directory.<: request that the symlink is created using junction points.+On other platforms these flags are ignored.Z-IOEquivalent to  #http://linux.die.net/man/2/readlink readlink(2).Z-IOEquivalent to  #http://linux.die.net/man/3/realpath realpath(3) on Unix. Windows uses  https://msdn.microsoft.com/en-us/library/windows/desktop/aa364962(v=vs.85).aspxGetFinalPathNameByHandle.Warning This function has certain platform-specific caveats that were discovered when used in Node.macOS and other BSDs: this function will fail with UV_ELOOP if more than 32 symlinks are found while resolving the given path. This limit is hardcoded and cannot be sidestepped.Windows: while this function works in the common case, there are a number of corner cases where it doesn@t:Paths in ramdisk volumes created by tools which sidestep the Volume Manager (such as ImDisk) cannot be resolved.-Inconsistent casing when using drive letters.&Resolved path bypasses subst@d drives.While this function can still be used, it@s not recommended if scenarios such as the above need to be supported. The background story and some more details on these issues can be checked  *https://github.com/nodejs/node/issues/7726here.Note This function is not implemented on Windows XP and Windows Server 2003. On these systems, UV_ENOSYS is returned.Z-IObufferZ-IO buffer sizeZ-IO2file offset, pass -1 to use default(system) offsetZ-IO read lengthZ-IObufferZ-IO buffer sizeZ-IO2file offset, pass -1 to use default(system) offsetZ-IOOpening flags, e.g.  .|. Z-IOSets the file mode (permission and sticky bits), but only if the file was created, see .Z-IOatime, i.e. access timeZ-IOmtime, i.e. modify time IO manager based on libuv(c) Dong Han, 2017-2018BSDwinterland1989@gmail.com experimental non-portableNone Z-IOA haskell data type wrap an  uv_stream_t inside# DO NOT provide thread safety! Use  concurrently in multiple threads will lead to undefined behavior.Z-IOGet  runing on the same capability.Z-IOGet % from blocking table with given slot.Z-IOPoke a prepared buffer and size into loop data under given slot.(NOTE, this action is not protected with  for effcient reason, you should merge this action with other uv action and put them together inside a " or 'withUVManager''. for example:  ... withUVManager' uvm $ do pokeBufferTable uvm slot buf len uvReadStart handle ... Z-IOLock an uv mananger, so that we can safely mutate its uv_loop's state.libuv is not thread safe, use this function to perform any action which will mutate uv_loop's state.Z-IOLock an uv mananger, so that we can safely mutate its uv_loop's state.Some action did not request uv_loop pointer explicitly, but will mutate uv_loop underhood, for example:  uv_read_start<. These actions have to be protected by locking the uv_loop.In fact most of the libuv's functions are not thread safe, so watch out!Z-IORun a libuv FFI to get a  (which may exceed block table size), resize the block table in that case, so that the returned slot always has an accompanying  in block table.$Always use this function to turn an  UVSlotUnsafe into , so that the block table size synchronize with libuv side's slot table.Z-IO Exception safe uv request helperThis helper will run a libuv's async function, which will return a libuv side's slot, then we will accommodate a " in block table and wait on that , until the async function finished or an exception is received, in later case we will call : to cancel the on-going async function with best efforts,Z-IO Same with  but disgard the result.Z-IO Same with ) but apply an convert function to result.The convert function have all access to the returned value including negative ones, it's convert funtions's responsiblity to throw an exception if appropriate.Z-IO Same with , but will also run an extra cleanup function if async exception hit this thread but the async action is already successfully performed, e.g. release result memory.Z-IO1Fork a new GHC thread with active load-balancing.Using libuv based IO solution has a disadvantage that file handlers are bound to certain uv_loop, thus certain uv mananger/capability. Worker threads that migrate to other capability will lead contention since various APIs here is protected by manager's lock, this makes GHC's work-stealing strategy unsuitable for certain workload, such as a webserver. we solve this problem with simple round-robin load-balancing: forkBa will automatically distribute new threads to all capabilities in round-robin manner. Thus its name forkBa(lance).Z-IO?Safely lock an uv manager and perform uv_handle initialization.2Initialization an UV stream usually take two step:-allocate an uv_stream struct with proper sizelock a particular uv_loop from a uv manager, and perform custom initialization, such as  uv_tcp_init.And this is what  do, all you need to do is to provide the manager you want to hook the handle onto(usually the one on the same capability, i.e. the one obtained by ), and provide a custom initialization function (which should throw an exception if failed).Z-IO uv managerZ-IOuv slotZ-IObuffer pointerZ-IO buffer lengthZ-IOconvert function  TTY devices(c) Dong Han, 2018~2019BSDwinterland1989@gmail.com experimental non-portableNone Z-IO!Standard input and output streamsWe support both regular file and TTY based streams, when initialized  is called to decide which type of devices are connected to standard streams.Note  is not thread safe, you shouldn't use them without lock. For the same reason you shouldn't use stderr directly, use  module instead.Z-IOThe global stdin stream.Z-IOThe global stdout stream.'| If you want to write logs, don't use  directly, use  instead.Z-IOThe global stderr stream.'| If you want to write logs, don't use  directly, use  instead.Z-IO,A global buffered stdin stream protected by .Z-IO-A global buffered stdout stream protected by .'| If you want to write logs, don't use  directly, use  instead.Z-IO-A global buffered stderr stream protected by .'| If you want to write logs, don't use  directly, use  instead.Z-IO;Change terminal's mode if stdin is connected to a terminal.Z-IOGet terminal's output window size in (width, height) format, return (-1, -1) if stdout is a file.Z-IOprint a  and flush to stdout.Z-IOprint a  and flush to stdout.Z-IOprint a & and flush to stdout, with a linefeed.Z-IOread a line from stdin High performance logger(c) Dong Han, 2017-2018BSDwinterland1989@gmail.com experimental non-portableNone > Z-IO%Minimal flush interval, see Notes on Z-IO/A IO action return a formatted date/time stringZ-IO"Buffer size to build each log/lineZ-IOSet to  to filter debug logsZ-IOSet to , to disable auto data/time string prependingZ-IO&flush logger's buffer to output deviceZ-IOMake a new loggerZ-IOChange the global logger.Z-IOGet the global logger.Z-IO'Flush stderr logger when program exits.Z-IO log levelZ-IOflush immediately?Z-IO log contentZ-IO log levelZ-IOflush immediately?Z-IO log content UDP servers and clients(c) Dong Han, 2018BSDwinterland1989@gmail.com experimental non-portableNoneZ-IOReceiving buffering config.Z-IO"maximum size of a received messageZ-IOhow many messages we want to receive per uv loop, inside each uv_run, we do batch receiving, increase this number can improve receiving performance, at the cost of memory and potential GHC thread starving.Z-IOWrapper for a connected .Z-IO UDP options.Though technically message length field in the UDP header is a max of 65535, but large packets could be more likely dropped by routers, usually a packet(IPV4) with a payload <= 508 bytes is considered safe.Z-IOmaximum size of sending bufferZ-IOdo we want bind a local address before receiving & sending? set to Nothing to let OS pick a random one.Z-IOUDP socket client.UDP is not a sequential protocol, thus not an instance of 'Input/Output'. Message are received or sent individually, UDP socket client is NOT thread safe! Use   in multiple threads.Z-IO UDPConfig 512 NothingZ-IOInitialize a UDP socket.Z-IO!Get the local IP and port of the .Z-IOAssociate the UDP handle to a remote address and port, so every message sent by this handle is automatically sent to that destinationZ-IO9Disconnect the UDP handle from a remote address and port.Z-IOGet the remote IP and port on .Z-IO(Send a UDP message with a connected UDP. WARNING: A  with errno + will be thrown if message is larger than  sendMsgSize.Z-IO%Send a UDP message to target address. WARNING: A  with errno + will be thrown if message is larger than  sendMsgSize.Z-IOSet IP multicast loop flag. Makes multicast packets loop back to local sockets.Z-IOSet the multicast ttl.Z-IO7Set the multicast interface to send or receive data on.Z-IOSet broadcast on or off.Z-IOSet the time to live.Z-IO%Set membership for a multicast group.Z-IO5Set membership for a source-specific multicast group.Z-IO UDPRecvConfig 512 6Z-IORecv UDP message within a loopLoop receiving can be faster since it can reuse receiving buffer.Z-IORecv messages from UDP socket, return source address if available, and a  to indicate if the message is partial (larger than receive buffer size).Z-IO1 ~ 255Z-IO(Multicast address to set membership for.Z-IOInterface address.Z-IOUV_JOIN_GROUP | UV_LEAVE_GROUPZ-IO(Multicast address to set membership for.Z-IOInterface address.Z-IOSource address.Z-IOUV_JOIN_GROUP | UV_LEAVE_GROUP#( TCP servers and clients(c) Dong Han, 2018BSDwinterland1989@gmail.com experimental non-portableNone#$ Z-IOA TCP server configurationZ-IOlistening addressZ-IO=listening socket's backlog size, should be large enough(>128)Z-IOif we want to use  TCP_NODELAYZ-IOworker which get an accepted TCP stream, the socket will be closed upon exception or worker finishes.Z-IOA TCP client configurationZ-IO*assign a local address, or let OS pick oneZ-IOremote target addressZ-IOif we want to use  TCP_NODELAYZ-IODefault config, connect to localhost:8888.Z-IOinit a TCP client %, which open a new connect when used.Z-IO.A default hello world server on localhost:8888 Test it with ,main = startTCPServer defaultTCPServerConfig , now try nc -v 127.0.0.1 8888Z-IOStart a server-Fork new worker thread upon a new connection.*Named pipe/Unix domain servers and clients(c) Dong Han, 2018BSDwinterland1989@gmail.com experimental non-portableNone #$ Z-IOA IPC server configurationZ-IO*listening path (Unix) or a name (Windows).Z-IO;listening pipe's backlog size, should be large enough(>128)Z-IOworker which get an accepted IPC stream, the socket will be closed upon exception or worker finishes.Z-IOA IPC client configurationZ-IObind to a local file path (Unix) or name (Windows), won't bind if set to .Z-IO'target path (Unix) or a name (Windows).Z-IO#Default config, connect to "./ipc".Z-IOinit a IPC client %, which open a new connect when used.Z-IO A default hello world server on ./ipc Test it with ,main = startIPCServer defaultIPCServerConfigZ-IOStart a server-Fork new worker thread upon a new connection.  Filesystem IO using threadpool(c) Dong Han, 2017~2019BSDwinterland1989@gmail.com experimental non-portableNone38Z-IO- and its operations are NOT thread safe, use MVar  in multiple threads.'Note this is a differet data type from Z.IO.FileSystem 's one, the  and , instance use thread pool version functions.libuv implements read and write method with both implict and explict offset capable. Implict offset interface is provided by  / 5 instances. Explict offset interface is provided by  / .Z-IOIf fd is -1 (closed), throw  ECLOSED.Z-IORead file with given offset,Read length may be smaller than buffer size.Z-IOWrite buffer to file4This function will loop until all bytes are written.Z-IO init a file , which open a file when used.Resource closing will wait for the referencing counter goes down to zero (no reading or writing is in process), which can be a problem if you are using multiple readers or writers in multiple threads. In that case you have to stop all reading or writing thread if you don't want to block the resource thread.Z-IOEquivalent to  http://linux.die.net/man/2/mkdirmkdir(2).2Note mode is currently not implemented on Windows.Z-IOEquivalent to  !http://linux.die.net/man/2/unlink unlink(2).Z-IOEquivalent to mkdtemp"http://linux.die.net/man/3/mkdtempCreates a temporary directory in the most secure manner possible. There are no race conditions in the directory@s creation. The directory is readable, writable, and searchable only by the creating user ID. The user of mkdtemp() is responsible for deleting the temporary directory and its contents when done with it.Note: the argument is the prefix of the temporary directory, so no need to add XXXXXX ending.Z-IOEquivalent to  http://linux.die.net/man/2/rmdirrmdir(2).Z-IOEquivalent to  "http://linux.die.net/man/3/scandir scandir(3).Note Unlike scandir(3), this function does not return the @.@ and @..@ entries.Note On Linux, getting the type of an entry is only supported by some file systems (btrfs, ext2, ext3 and ext4 at the time of this writing), check the  #http://linux.die.net/man/2/getdents getdents(2) man page.Z-IOEquivalent to http://linux.die.net/man/2/statstat(2)Z-IOEquivalent to http://linux.die.net/man/2/lstatlstat(2)Z-IOEquivalent to http://linux.die.net/man/2/fstatfstat(2)Z-IOEquivalent to  !http://linux.die.net/man/2/rename rename(2).Note On Windows if this function fails with UV_EBUSY, UV_EPERM or UV_EACCES, it will retry to rename the file up to four times with 250ms wait between attempts before giving up. If both path and new_path are existing directories this function will work only if target directory is empty.Z-IOEquivalent to  http://linux.die.net/man/2/fsyncfsync(2).Z-IOEquivalent to  $http://linux.die.net/man/2/fdatasync fdatasync(2).Z-IOEquivalent to  $http://linux.die.net/man/2/ftruncate ftruncate(2).Z-IO$Copies a file from path to new_path.Warning: If the destination path is created, but an error occurs while copying the data, then the destination path is removed. There is a brief window of time between closing and removing the file where another process could access the file.Z-IOEquivalent to  !http://linux.die.net/man/2/access access(2)- on Unix. Windows uses GetFileAttributesW().Z-IOEquivalent to  http://linux.die.net/man/2/chmodchmod(2).Z-IOEquivalent to  !http://linux.die.net/man/2/fchmod fchmod(2).Z-IOEquivalent to  http://linux.die.net/man/2/utimeutime(2). libuv choose  type due to cross platform concerns, we only provide micro-second precision:second = v,nanosecond = (v * 1000000) % 1000000 * 1000;$second and nanosecond are fields in  respectively.Note libuv prior to v1.23.1 have issues which may result in nanosecond not set,  doesn't haveZ-IOEquivalent to  !http://linux.die.net/man/2/futime futime(2).Same precision notes with .Z-IOEquivalent to  http://linux.die.net/man/2/linklink(2).Z-IOEquivalent to  "http://linux.die.net/man/2/symlink symlink(2).| Note On Windows the flags parameter can be specified to control how the symlink will be created.,: indicates that path points to a directory.<: request that the symlink is created using junction points.+On other platforms these flags are ignored.Z-IOEquivalent to  #http://linux.die.net/man/2/readlink readlink(2).Z-IOEquivalent to  #http://linux.die.net/man/3/realpath realpath(3) on Unix. Windows uses  https://msdn.microsoft.com/en-us/library/windows/desktop/aa364962(v=vs.85).aspxGetFinalPathNameByHandle.Warning This function has certain platform-specific caveats that were discovered when used in Node.macOS and other BSDs: this function will fail with UV_ELOOP if more than 32 symlinks are found while resolving the given path. This limit is hardcoded and cannot be sidestepped.Windows: while this function works in the common case, there are a number of corner cases where it doesn@t:Paths in ramdisk volumes created by tools which sidestep the Volume Manager (such as ImDisk) cannot be resolved.-Inconsistent casing when using drive letters.&Resolved path bypasses subst@d drives.While this function can still be used, it@s not recommended if scenarios such as the above need to be supported. The background story and some more details on these issues can be checked  *https://github.com/nodejs/node/issues/7726here.Note This function is not implemented on Windows XP and Windows Server 2003. On these systems, UV_ENOSYS is returned.Z-IObufferZ-IO buffer sizeZ-IO2file offset, pass -1 to use default(system) offsetZ-IO read lengthZ-IObufferZ-IO buffer sizeZ-IO2file offset, pass -1 to use default(system) offsetZ-IOOpening flags, e.g.  .|. Z-IOSets the file mode (permission and sticky bits), but only if the file was created, see .Z-IOatime, i.e. access timeZ-IOmtime, i.e. modify timeSpecial code on windows(c) Winterland, 2017-2018BSDdrkoster@qq.com experimental non-portable Safe-InferredͿZ-IO is necessary for some socket code because on windows WSAStartup has to be called before use sockets.This functions will run  uv__once_init once if not run before,TCP/UDP socket address API(c) Winterland, 2018BSDdrkoster@qq.com experimental non-portableNone#$Z-IO-Flags that control the querying behaviour of . For more information, see +https://tools.ietf.org/html/rfc3493#page-30Z-IOResolve a datagram-based service name. This is required only for the few protocols that have different port numbers for their datagram-based versions than for their stream-based versions.Z-IO;If the hostname cannot be looked up, an IO error is thrown.Z-IO>If a host is local, return only the hostname part of the FQDN.Z-IOThe name of the host is not looked up. Instead, a numeric representation of the host's address is returned. For an IPv4 address, this will be a dotted-quad string. For IPv6, it will be colon-separated hexadecimal.Z-IOThe name of the service is not looked up. Instead, a numeric representation of the service is returned.Z-IO Address infoZ-IO-Flags that control the querying behaviour of . For more information, see +https://tools.ietf.org/html/rfc3493#page-25Z-IOThe list of returned  values will only contain IPv4 addresses if the local system has at least one IPv4 interface configured, and likewise for IPv6. (Only some platforms support this.)Z-IOIf  is specified, return all matching IPv6 and IPv4 addresses. Otherwise, this flag has no effect. (Only some platforms support this.)Z-IOThe  field of the first returned / will contain the "canonical name" of the host.Z-IOThe  argument must be a numeric address in string form, and network name lookups will not be attempted.Z-IOThe  argument must be a port number in string form, and service name lookups will not be attempted. (Only some platforms support this.)Z-IOIf no 3 value is provided, the network address in each  will be left as a "wild card". This is useful for server applications that will accept connections from any client.Z-IOIf an IPv6 lookup is performed, and no IPv6 addresses are found, IPv6-mapped IPv4 addresses will be returned. (Only some platforms support this.)Z-IOEither a service name e.g., "http" or a numeric port number.Z-IOEither a host name e.g.,  "haskell.org" or a numeric host address string consisting of a dotted decimal IPv4 address or an IPv6 address e.g.,  "192.168.0.1".Z-IOIndicate whether the given % will have any effect on this system.Z-IO&Default hints for address lookup with .addrFlags defaultHints[]addrFamily defaultHints AF_UNSPECaddrSocketType defaultHints NoSocketTypeaddrProtocol defaultHints0Z-IO>Resolve a host or service name to one or more addresses. The + values that this function returns contain 1 values that you can use to init TCP connection.This function is protocol independent. It can return both IPv4 and IPv6 address information.The  argument specifies the preferred query behaviour, socket options, or protocol. You can override these conveniently using Haskell's record update syntax on , for example as follows:let hints = defaultHints { addrFlags = [AI_NUMERICHOST], addrSocketType = Stream }9You must provide non empty value for at least one of the  or  arguments.  can be either a numeric network address (dotted quad for IPv4, colon-separated hex for IPv6) or a hostname. In the latter case, its addresses will be looked up unless 3 is specified as a hint. If you do not provide a  value and do not set  as a hint, network addresses in the result will contain the address of the loopback interface.If the query fails, this function throws an IO exception instead of returning an empty list. Otherwise, it returns a non-empty list of  values.There are several reasons why a query might result in several values. For example, the queried-for host could be multihomed, or the service might be available via several protocols.Note: the order of arguments is slightly different to that defined for  getaddrinfo in RFC 2553. The ; parameter comes first to make partial application easier.5addr:_ <- getAddrInfo (Just hints) "127.0.0.1" "http"addrAddress addr 127.0.0.1:80Z-IOPeek addrinfo linked list.Z-IOResolve an address to a host or service name. This function is protocol independent. The list of ! values controls query behaviour.If a host or service's name cannot be looked up, then the numeric form of the address or service will be returned.9If the query fails, this function throws an IO exception.:>:?:?:@:@:A:A:B:B:C:C:D:D:E:F:G:H:I:J:K:LMNMOMPMQMRMSMTMUMVMWMXMYMZ[\[][^[]_`_a_b_c_d_e_f_g_h_i_j_kl_`mnopqrstuvwxyz{|}~                                                                                                                8 Z-IO-0.1.0.0-inplaceZ.IO.Exception Z.IO.UV.ErrnoZ.IO.Network.SocketAddrZ.IO.LowResTimer Z.IO.Resource Z.IO.Buffered Z.IO.UV.FFIZ.IO.FileSystemZ.IO.UV.ManagerZ.IO.StdStream Z.IO.LoggerZ.IO.Network.UDPZ.IO.Network.TCPZ.IO.Network.IPCZ.IO.FileSystem.Threaded Z.IO.UV.WinZ.IO.Network.DNSEResourceVanishedSystem.TimeouttimeoutZ.IOLogger Z.IO.NetworkbaseGHC.BaseassertGHC.Stack.Types CallStack GHC.Stack callStackControl.ExceptionallowInterruptcatchesHandlerControl.Exception.BasebracketOnErrorbracket_finallybracket onExceptiontryJusttry mapException handleJusthandle catchJustPatternMatchFail RecSelError RecConError RecUpdError NoMethodError TypeErrorNonTerminationNestedAtomically GHC.Conc.SyncthrowToGHC.IO.ExceptionioErrorasyncExceptionFromExceptionasyncExceptionToExceptionBlockedIndefinitelyOnMVarBlockedIndefinitelyOnSTMDeadlockAllocationLimitExceededCompactionFailedAssertionFailedSomeAsyncException UserInterrupt ThreadKilled HeapOverflow StackOverflowAsyncExceptionUndefinedElementIndexOutOfBoundsArrayExceptionGHC.IOevaluateuninterruptibleMaskuninterruptibleMask_maskmask_getMaskingState interruptiblethrowIOcatchMaskedUninterruptibleMaskedInterruptibleUnmasked MaskingState GHC.Exceptionthrow ErrorCallErrorCallWithLocationGHC.Exception.Type SomeExceptiondisplayException fromException toException ExceptionRatioZeroDenominatorDenormal DivideByZeroLossOfPrecision UnderflowOverflowArithException HasCallStack uv_err_name uv_strerror UV_EMLINKUV_ENXIOUV_EOF UV_UNKNOWNUV_EXDEV UV_ETXTBSY UV_ETIMEDOUTUV_ESRCH UV_ESPIPE UV_ESHUTDOWNUV_EROFS UV_ERANGE UV_EPROTOTYPEUV_EPROTONOSUPPORT UV_EPROTOUV_EPIPEUV_EPERM UV_ENOTSUP UV_ENOTSOCK UV_ENOTEMPTY UV_ENOTDIR UV_ENOTCONN UV_ENOSYS UV_ENOSPCUV_ENOPROTOOPT UV_ENONET UV_ENOMEM UV_ENOENT UV_ENODEV UV_ENOBUFS UV_ENFILEUV_ENETUNREACH UV_ENETDOWNUV_ENAMETOOLONG UV_EMSGSIZE UV_EMFILEUV_ELOOP UV_EISDIR UV_EISCONNUV_EIO UV_EINVALUV_EINTRUV_EHOSTUNREACHUV_EFBIG UV_EFAULT UV_EEXISTUV_EDESTADDRREQ UV_ECONNRESETUV_ECONNREFUSEDUV_ECONNABORTED UV_ECHARSET UV_ECANCELEDUV_EBUSYUV_EBADF UV_EALREADYUV_EAI_SOCKTYPEUV_EAI_SERVICEUV_EAI_PROTOCOLUV_EAI_OVERFLOW UV_EAI_NONAME UV_EAI_NODATA UV_EAI_MEMORY UV_EAI_FAMILY UV_EAI_FAILUV_EAI_CANCELEDUV_EAI_BADHINTSUV_EAI_BADFLAGS UV_EAI_AGAINUV_EAI_ADDRFAMILY UV_EAGAINUV_EAFNOSUPPORTUV_EADDRNOTAVAIL UV_EADDRINUSE UV_EACCESUV_E2BIG uvStdError uvErrNameIOEInfoioeNameioeDescription ioeCallStack Interrupted TimeExpiredUnsupportedOperation HardwareFaultInappropriateTypeInvalidArgument OtherError ProtocolError SystemErrorUnsatisfiedConstraintsPermissionDeniedIllegalOperationEOFResourceExhausted ResourceBusy NoSuchThing AlreadyExistsSomeIOExceptionioExceptionToExceptionioExceptionFromExceptionthrowOOMIfNullthrowUVIfMinusthrowUVIfMinus_ throwECLOSEDthrowECLOSEDSTM throwUVError$fExceptionSomeIOException$fShowSomeIOException $fShowIOEInfo$fExceptionInterrupted$fExceptionResourceVanished$fExceptionTimeExpired$fExceptionUnsupportedOperation$fExceptionHardwareFault$fExceptionInappropriateType$fExceptionInvalidArgument$fExceptionOtherError$fExceptionProtocolError$fExceptionSystemError!$fExceptionUnsatisfiedConstraints$fExceptionPermissionDenied$fExceptionIllegalOperation$fExceptionEOF$fExceptionResourceExhausted$fExceptionResourceBusy$fExceptionNoSuchThing$fExceptionAlreadyExists$fShowAlreadyExists$fShowNoSuchThing$fShowResourceBusy$fShowResourceExhausted $fShowEOF$fShowIllegalOperation$fShowPermissionDenied$fShowUnsatisfiedConstraints$fShowSystemError$fShowProtocolError$fShowOtherError$fShowInvalidArgument$fShowInappropriateType$fShowHardwareFault$fShowUnsupportedOperation$fShowTimeExpired$fShowResourceVanished$fShowInterruptedProtocolNumber SocketType SocketFamily PortNumber Inet6AddrInetAddrScopeIDFlowInfo SocketAddrSocketAddrInetSocketAddrInet6htonlntohlhtonsntohs IPPROTO_UDP IPPROTO_TCP IPPROTO_IPIPPROTO_DEFAULTSOCK_ANYSOCK_SEQPACKETSOCK_RDMSOCK_RAW SOCK_DGRAM SOCK_STREAMAF_INET6AF_INET AF_UNSPECsockAddrFamilyinetAny inetBroadcastinetNone inetLoopbackinetUnspecificGroupinetAllHostsGroupinetMaxLocalGroupinetAddrToTupletupleToInetAddrinet6Any inet6Loopbackinet6AddrToTupletupleToInet6AddrpeekSocketAddrwithSocketAddrsizeOfSocketAddrwithSocketAddrStoragesizeOfSocketAddrStorageportAny$fStorableInetAddr$fShowInetAddr$fStorableInet6Addr$fShowInet6Addr$fStorablePortNumber$fIntegralPortNumber$fRealPortNumber$fNumPortNumber$fEnumPortNumber$fReadPortNumber$fShowPortNumber$fShowSocketAddr$fStorableSocketFamily$fStorableSocketType$fStorableProtocolNumber$fShowProtocolNumber$fReadProtocolNumber$fEqProtocolNumber$fOrdProtocolNumber$fShowSocketType$fReadSocketType$fEqSocketType$fOrdSocketType$fShowSocketFamily$fReadSocketFamily$fEqSocketFamily$fOrdSocketFamily$fEqSocketAddr$fOrdSocketAddr$fEqPortNumber$fOrdPortNumber $fEqInet6Addr$fOrdInet6Addr $fEqInetAddr $fOrdInetAddr LowResTimerLowResTimerManager%lowResTimerManagerCapabilitiesChangedgetLowResTimerManagerisLowResTimerManagerRunningregisterLowResTimerregisterLowResTimer_registerLowResTimerOnqueryLowResTimercancelLowResTimercancelLowResTimer_ timeoutLowRestimeoutLowResExthrottle throttle_throttleTrailing_$fExceptionTimeOutException$fShowTimeOutExceptionPool PoolState PoolClosed PoolScanning PoolEmptyResourceacquire initResource initResource_ withResource withResource'initPoolstatPool initInPool$fMonadIOResource$fMonadResource$fApplicativeResource$fFunctorResource $fEqPoolState$fShowPoolStateZ-Data-0.1.1.0-4b4ee139de5142c9858f55f3a76fec0720be496611c4106934a3e86ee3c3b306Z.Data.Vector.BasedefaultChunkSizesmallChunkSizeShortReadExceptionBufferedOutput BufferedInputOutput writeOutputInput readInputnewBufferedInputnewBufferedOutput readBuffer readExactlyreadAllreadAll' unReadBuffer readParser readToMagic readToMagic'readLine readLine' writeBuffer writeBuilder flushBuffer$fExceptionShortReadException$fShowShortReadException UVHandleType UVSymlinkFlag AccessResult NoExistence NoPermissionAccessOK UVAccessModeUVCopyFileFlagUVStatstDevstModestNlinkstUidstGidstRdevstInostSize stBlksizestBlocksstFlagsstGenstAtimstMtimstCtim stBirthtim UVTimeSpec uvtSecond uvtNanoSecondUVDirEnt DirEntType DirEntUnknown DirEntFile DirEntDir DirEntLink DirEntFIFO DirEntSocket DirEntChar DirEntBlock UVDirEntTypeFileFlagFileMode UVTTYMode UVUDPFlag UVMembershipUVHandle UVRunMode UVLoopDataUVLoopUVFD UVSlotUnSafe unsafeGetSlotUVSlotuv_guess_handlehs_uv_fs_realpath_threadedhs_uv_fs_readlink_threadedhs_uv_fs_readlink_extra_cleanuphs_uv_fs_realpathhs_uv_fs_readlinkhs_uv_fs_readlink_cleanuphs_uv_fs_symlink_threadedhs_uv_fs_symlinkhs_uv_fs_link_threaded hs_uv_fs_linkhs_uv_fs_futime_threadedhs_uv_fs_futimehs_uv_fs_utime_threadedhs_uv_fs_utimehs_uv_fs_fchmod_threadedhs_uv_fs_fchmodhs_uv_fs_chmod_threadedhs_uv_fs_chmodhs_uv_fs_access_threadedhs_uv_fs_accesshs_uv_fs_copyfile_threadedhs_uv_fs_copyfilehs_uv_fs_ftruncate_threadedhs_uv_fs_fdatasync_threadedhs_uv_fs_fsync_threadedhs_uv_fs_rename_threadedhs_uv_fs_lstat_threadedhs_uv_fs_fstat_threadedhs_uv_fs_stat_threadedhs_uv_fs_ftruncatehs_uv_fs_fdatasynchs_uv_fs_fsynchs_uv_fs_renamehs_uv_fs_lstaths_uv_fs_fstat hs_uv_fs_staths_uv_fs_scandir_threadedhs_uv_fs_scandir_extra_cleanuphs_uv_fs_scandirhs_uv_fs_scandir_cleanuphs_uv_fs_mkdtemp_threadedhs_uv_fs_rmdir_threadedhs_uv_fs_mkdir_threadedhs_uv_fs_unlink_threadedhs_uv_fs_write_threadedhs_uv_fs_read_threadedhs_uv_fs_close_threadedhs_uv_fs_open_threadedhs_uv_fs_mkdtemphs_uv_fs_rmdirhs_uv_fs_mkdirhs_uv_fs_unlinkhs_uv_fs_write hs_uv_fs_readhs_uv_fs_close hs_uv_fs_openuv_tty_get_winsizeuv_tty_set_mode uv_tty_inituv_udp_getpeernameuv_udp_getsocknamehs_uv_udp_senduv_udp_recv_stophs_uv_udp_recv_startuv_udp_set_ttluv_udp_set_broadcastuv_udp_set_multicast_interfaceuv_udp_set_multicast_ttluv_udp_set_multicast_loopuv_udp_set_source_membershipuv_udp_set_membershipuv_udp_connect uv_udp_bind uv_udp_openuv_udp_init_ex uv_udp_iniths_uv_pipe_connect uv_pipe_bind uv_pipe_iniths_uv_pipe_openhs_set_socket_reusehs_uv_tcp_connect uv_tcp_binduv_tcp_keepaliveuv_tcp_nodelayuv_tcp_init_ex uv_tcp_iniths_uv_tcp_openhs_uv_accept_check_closehs_uv_accept_check_iniths_uv_accept_check_alloc hs_uv_write uv_read_stophs_uv_read_starths_uv_listen_resume hs_uv_listen hs_uv_cancelhs_uv_handle_closehs_uv_handle_freehs_uv_handle_alloc hs_uv_filenohs_uv_wake_up_asynchs_uv_wake_up_timer uv_loop_alive uv_run_safeuv_runhs_uv_loop_closehs_uv_loop_inituv_version_string uv_versionUV_FILE UV_SIGNALUV_UDPUV_TTYUV_TIMERUV_TCP UV_STREAM UV_PROCESS UV_PREPAREUV_POLL UV_NAMED_PIPEUV_IDLE UV_HANDLE UV_FS_POLL UV_FS_EVENTUV_CHECKUV_ASYNCUV_UNKNOWN_HANDLESYMLINK_JUNCTION SYMLINK_DIRSYMLINK_DEFAULTX_OKW_OKR_OKF_OKCOPYFILE_FICLONE COPYFILE_EXCLCOPYFILE_DEFAULTO_WRONLYO_TRUNC O_TEMPORARYO_SYNC O_SYMLINK O_SHORT_LIVED O_SEQUENTIALO_RDWRO_RDONLYO_RANDOM O_NONBLOCK O_NOFOLLOWO_NOCTTY O_NOATIMEO_EXLOCKO_EXCLO_DSYNC O_DIRECTORYO_DIRECTO_CREATO_APPEND DEFAULT_MODES_IXOTHS_IWOTHS_IROTHS_IRWXOS_IXGRPS_IWGRPS_IRGRPS_IRWXGS_IXUSRS_IWUSRS_IRUSRS_IRWXUUV_TTY_MODE_IOUV_TTY_MODE_RAWUV_TTY_MODE_NORMALUV_UDP_PARTIALUV_UDP_REUSEADDRUV_UDP_IPV6ONLYUV_UDP_DEFAULT UV_JOIN_GROUPUV_LEAVE_GROUP UV_RUN_NOWAIT UV_RUN_ONCEUV_RUN_DEFAULTINIT_LOOP_SIZESO_REUSEPORT_LOAD_BALANCEACCEPT_BUFFER_SIZEpeekUVEventQueueclearUVEventCounterpeekUVBufferTablepeekUVLoopDatapeekUVHandleDatauV_TCP_IPV6ONLYfromUVDirEntType uV__DT_FILE uV__DT_DIR uV__DT_LINK uV__DT_FIFO uV__DT_SOCKET uV__DT_CHAR uV__DT_BLOCK peekUVDirEnt uvStatSize peekUVStat$fStorableUVTimeSpec$fEqUVHandleType$fOrdUVHandleType$fReadUVHandleType$fShowUVHandleType$fStorableUVHandleType$fEqUVSymlinkFlag$fOrdUVSymlinkFlag$fReadUVSymlinkFlag$fShowUVSymlinkFlag$fFiniteBitsUVSymlinkFlag$fBitsUVSymlinkFlag$fStorableUVSymlinkFlag$fNumUVSymlinkFlag$fShowAccessResult$fEqAccessResult$fOrdAccessResult$fEqUVAccessMode$fOrdUVAccessMode$fReadUVAccessMode$fShowUVAccessMode$fFiniteBitsUVAccessMode$fBitsUVAccessMode$fStorableUVAccessMode$fNumUVAccessMode$fEqUVCopyFileFlag$fOrdUVCopyFileFlag$fReadUVCopyFileFlag$fShowUVCopyFileFlag$fFiniteBitsUVCopyFileFlag$fBitsUVCopyFileFlag$fStorableUVCopyFileFlag$fNumUVCopyFileFlag $fShowUVStat $fReadUVStat $fEqUVStat $fOrdUVStat$fGenericUVStat$fShowUVTimeSpec$fReadUVTimeSpec$fEqUVTimeSpec$fOrdUVTimeSpec$fGenericUVTimeSpec$fReadDirEntType$fShowDirEntType$fEqDirEntType$fOrdDirEntType$fGenericDirEntType$fEqUVDirEntType$fOrdUVDirEntType$fReadUVDirEntType$fShowUVDirEntType$fFiniteBitsUVDirEntType$fBitsUVDirEntType$fStorableUVDirEntType$fNumUVDirEntType $fEqFileFlag $fOrdFileFlag$fReadFileFlag$fShowFileFlag$fFiniteBitsFileFlag$fBitsFileFlag$fStorableFileFlag $fNumFileFlag $fEqFileMode $fOrdFileMode$fReadFileMode$fShowFileMode$fFiniteBitsFileMode$fBitsFileMode$fStorableFileMode $fNumFileMode $fEqUVTTYMode$fOrdUVTTYMode$fReadUVTTYMode$fShowUVTTYMode$fFiniteBitsUVTTYMode$fBitsUVTTYMode$fStorableUVTTYMode$fNumUVTTYMode$fShowUVUDPFlag $fEqUVUDPFlag$fOrdUVUDPFlag$fStorableUVUDPFlag$fBitsUVUDPFlag$fFiniteBitsUVUDPFlag$fNumUVUDPFlag$fShowUVMembership$fEqUVMembership$fOrdUVMembership $fEqUVRunMode$fOrdUVRunMode$fReadUVRunMode$fShowUVRunMode$fFiniteBitsUVRunMode$fBitsUVRunMode$fStorableUVRunMode$fNumUVRunModeFilereadFile writeFileinitFilemkdirunlinkmkdtemprmdirscandirstatlstatfstatrenamefsync fdatasync ftruncatecopyfileaccesschmodfchmodutimefutimelinksymlinkreadlinkrealpath $fOutputFile $fInputFileUVStream uvsHandleuvsSlot uvsManager uvsClosed UVManager getUVManager getBlockMVarpokeBufferTablepeekBufferTable withUVManagerwithUVManager' getUVSlot withUVRequestwithUVRequest_withUVRequest'withUVRequestExforkBa initUVStream $fEqUVManager$fShowUVManager$fOutputUVStream$fInputUVStream$fShowUVStream StdStreamisStdStreamTTYstdinstdoutstderrstdinBuf stdoutBuf stderrBufsetStdinTTYModegetStdoutWinSizeprintStdputStd putLineStd readLineStd$fOutputStdStream$fInputStdStream LoggerConfigloggerMinFlushInterval loggerTsCacheloggerLineBufSizeloggerShowDebug loggerShowTS loggerFlush newLogger setStdLogger getStdLogger withStdLoggerdebuginfowarnfatal otherLevel debugWithinfoWithwarnWith fatalWithotherLevelWith UDPRecvConfig recvMsgSize recvBatchSize ConnectedUDP UDPConfigudpSendMsgSize udpLocalAddrUDPdefaultUDPConfiginitUDP getSockName connectUDP disconnectUDP getPeerNamesendConnectedUDPsendUDPsetMulticastLoopsetMulticastTTLsetMulticastInterface setBroadcastsetTTL setMembershipsetSourceMembershipdefaultUDPRecvConfig recvUDPLooprecvUDP $fShowUDP$fShowConnectedUDP$fShowUDPConfig $fEqUDPConfig$fOrdUDPConfigTCPServerConfig tcpListenAddrtcpListenBacklogtcpServerWorkerNoDelaytcpServerWorkerTCPClientConfig tcpClientAddr tcpRemoteAddr tcpNoDelaydefaultTCPClientConfig initTCPClientdefaultTCPServerConfigstartTCPServerIPCServerConfig ipcListenNameipcListenBacklogipcServerWorkerIPCClientConfig ipcClientName ipcTargetNamedefaultIPCClientConfig initIPCClientdefaultIPCServerConfigstartIPCServerFileTcheckFileTClosed readFileT writeFileT initFileT $fOutputFileT $fInputFileT withUVInitDo NameInfoFlagNI_DGRAM NI_NAMEREQD NI_NOFQDNNI_NUMERICHOSTNI_NUMERICSERVAddrInfo addrFlags addrFamilyaddrSocketType addrProtocol addrAddress addrCanonName AddrInfoFlag AI_ADDRCONFIGAI_ALL AI_CANONNAMEAI_NUMERICHOSTAI_NUMERICSERV AI_PASSIVE AI_V4MAPPED ServiceNameHostNameaddrInfoFlagMappingaddrInfoFlagImplementednameInfoFlagMapping defaultHints getAddrInfofollowAddrInfo getNameInfo$fStorableAddrInfo$fEqNameInfoFlag$fReadNameInfoFlag$fShowNameInfoFlag $fEqAddrInfo$fShowAddrInfo$fEqAddrInfoFlag$fReadAddrInfoFlag$fShowAddrInfoFlagGHC.PtrnullPtrGHC.Real fromIntegralsetNumCapabilities Data.FunctorvoidTimeOutException GHC.MaybeNothingghc-prim GHC.TypesIOControl.Monad.IO.ClassMonadIOBytesDoubleGHC.MVarMVar cancelUVReqZ.Data.Text.BuilderToTextZ.Data.Builder.BaseBuilderFalseBool