libuv/src
Trevor Norris 70bbc093f1 include: add internal fields struct to uv_loop_t
Add struct `uv__loop_internal_fields_t` as a location for future
additions to `uv_loop_t` while also maintaining v1.x compatibility.

Currently `uv__loop_internal_fields_t` only contains the `flags` field.
The reason for adding the `flags` field is because the same field was
never added to `UV_LOOP_PRIVATE_FIELDS` in Windows as it was in Unix.

The idea for creating a struct and attaching it to `uv_loop_t` for
future API enhancements was taken from a comment by bnoordhuis in:
https://github.com/libuv/libuv/issues/2506#issuecomment-540050665

Also add `internal_fields` to `uv_loop_t` to store the pointer to
`uv__loop_internal_fields_t`. This naming makes more sense than just
using `active_reqs.unused[1]`. To maintain ABI compatibility, shrink the
`unused` array.

PR-URL: https://github.com/libuv/libuv/pull/2725
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Jameson Nash <vtjnash@gmail.com>
2020-08-04 10:31:18 -04:00
..
unix include: add internal fields struct to uv_loop_t 2020-08-04 10:31:18 -04:00
win include: add internal fields struct to uv_loop_t 2020-08-04 10:31:18 -04:00
fs-poll.c unix,win: fix uv_fs_poll_stop() when active 2019-05-06 15:02:01 +02:00
heap-inl.h heap: fix heap_remove() 2014-05-23 20:04:42 +04:00
idna.c unix,win: support IDNA 2008 in uv_getaddrinfo() 2018-10-30 20:50:23 +01:00
idna.h unix,win: support IDNA 2008 in uv_getaddrinfo() 2018-10-30 20:50:23 +01:00
inet.c unix: harden string copying, introduce strscpy() 2018-12-04 17:08:09 +01:00
queue.h unix: use QUEUE_MOVE when iterating over lists 2015-10-08 21:47:43 +02:00
random.c netbsd: use KERN_ARND sysctl to get entropy 2019-10-29 13:36:05 +01:00
strscpy.c unix: harden string copying, introduce strscpy() 2018-12-04 17:08:09 +01:00
strscpy.h unix: harden string copying, introduce strscpy() 2018-12-04 17:08:09 +01:00
threadpool.c unix,win: add uv_library_shutdown() 2020-04-22 12:24:36 +02:00
timer.c timer: remove redundant check in heap compare 2020-04-16 14:54:51 +02:00
uv-common.c unix: use relaxed loads/stores for feature checks 2020-06-16 11:42:51 +02:00
uv-common.h include: add internal fields struct to uv_loop_t 2020-08-04 10:31:18 -04:00
uv-data-getter-setters.c test,sunos: fix statement not reached warnings 2019-03-16 13:22:16 -04:00
version.c core: add UV_VERSION_HEX macro 2015-06-29 23:08:41 +02:00