From cbc3dd997eb90d629d1b9912b7a5a40eb82343df Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Wed, 16 May 2018 11:50:48 +0200 Subject: src, tools: add check for left leaning pointers This commit adds a rule to cpplint to check that pointers in the code base lean to the left and not right, and also fixes the violations reported. PR-URL: https://github.com/nodejs/node/pull/21010 Reviewed-By: Ben Noordhuis Reviewed-By: Anna Henningsen Reviewed-By: Ruben Bridgewater Reviewed-By: James M Snell --- src/node_api_types.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/node_api_types.h') diff --git a/src/node_api_types.h b/src/node_api_types.h index 76f38802e8..f7f3ee6275 100644 --- a/src/node_api_types.h +++ b/src/node_api_types.h @@ -10,16 +10,16 @@ // JSVM API types are all opaque pointers for ABI stability // typedef undefined structs instead of void* for compile time type safety -typedef struct napi_env__ *napi_env; -typedef struct napi_value__ *napi_value; -typedef struct napi_ref__ *napi_ref; -typedef struct napi_handle_scope__ *napi_handle_scope; -typedef struct napi_escapable_handle_scope__ *napi_escapable_handle_scope; -typedef struct napi_callback_scope__ *napi_callback_scope; -typedef struct napi_callback_info__ *napi_callback_info; -typedef struct napi_async_context__ *napi_async_context; -typedef struct napi_async_work__ *napi_async_work; -typedef struct napi_deferred__ *napi_deferred; +typedef struct napi_env__* napi_env; +typedef struct napi_value__* napi_value; +typedef struct napi_ref__* napi_ref; +typedef struct napi_handle_scope__* napi_handle_scope; +typedef struct napi_escapable_handle_scope__* napi_escapable_handle_scope; +typedef struct napi_callback_scope__* napi_callback_scope; +typedef struct napi_callback_info__* napi_callback_info; +typedef struct napi_async_context__* napi_async_context; +typedef struct napi_async_work__* napi_async_work; +typedef struct napi_deferred__* napi_deferred; typedef enum { napi_default = 0, -- cgit v1.2.3