unix: remove always_inline attribute
Fixes the following gcc 4.7+ warning: ../src/unix/internal.h:105:13: warning: always_inline function might not be inlinable [-Wattributes] gcc wants the always_inline function to be annotated with the 'inline' keyword which we can't do because we compile in C89 mode. Using __inline is not an option because that makes clang generate warnings when -Wlanguage-extension-token is enabled. Therefore, remove the always_inline attribute altogether and hope that the compiler is smart enough to inline the functions.
This commit is contained in:
parent
d8de4fbd13
commit
fd136da04a
@ -30,7 +30,6 @@ static int uv__async_init(uv_loop_t* loop);
|
||||
static void uv__async_io(uv_loop_t* loop, uv__io_t* handle, int events);
|
||||
|
||||
|
||||
__attribute__((always_inline))
|
||||
static int uv__async_make_pending(volatile sig_atomic_t* ptr) {
|
||||
/* Do a cheap read first. */
|
||||
if (*ptr)
|
||||
|
||||
@ -101,7 +101,6 @@ enum {
|
||||
};
|
||||
|
||||
__attribute__((unused))
|
||||
__attribute__((always_inline))
|
||||
static void uv__req_init(uv_loop_t* loop, uv_req_t* req, uv_req_type type) {
|
||||
req->type = type;
|
||||
uv__req_register(loop, req);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user