From 5796e44827ffcbeaf4a4170a286d6f64a382d58a Mon Sep 17 00:00:00 2001 From: Jiajie Hu Date: Mon, 24 Jul 2017 10:17:28 +0800 Subject: buffer: remove a wrongly added attribute specifier MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It doesn't seem to make much sense to have the mentioned typedef declaration equipped with NODE_EXTERN. In fact, when compiling with GCC, an attribute specifier like __attribute__((visibility("default"))) in such a typedef declaration will cause the following warning message: warning: ‘visibility’ attribute ignored [-Wattributes] The issue goes unnoticed because NODE_EXTERN is defined as nothing for GCC builds, but for correctness it's better to not specify it here at all. PR-URL: https://github.com/nodejs/node/pull/14466 Reviewed-By: Refael Ackermann Reviewed-By: Trevor Norris --- src/node_buffer.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/node_buffer.h') diff --git a/src/node_buffer.h b/src/node_buffer.h index 799d05a7aa6..acf9b23c3b3 100644 --- a/src/node_buffer.h +++ b/src/node_buffer.h @@ -34,7 +34,7 @@ namespace Buffer { static const unsigned int kMaxLength = sizeof(int32_t) == sizeof(intptr_t) ? 0x3fffffff : 0x7fffffff; -NODE_EXTERN typedef void (*FreeCallback)(char* data, void* hint); +typedef void (*FreeCallback)(char* data, void* hint); NODE_EXTERN bool HasInstance(v8::Local val); NODE_EXTERN bool HasInstance(v8::Local val); -- cgit v1.2.3