Welcome! Log In Create A New Profile

Advanced

[njs] Style fixes.

April 03, 2018 10:58AM
details: http://hg.nginx.org/njs/rev/39374a5d6cda
branches:
changeset: 489:39374a5d6cda
user: Igor Sysoev <igor@sysoev.ru>
date: Tue Apr 03 17:55:23 2018 +0300
description:
Style fixes.

diffstat:

njs/njs_parser.h | 4 ++--
njs/njs_parser_expression.c | 20 ++++++++++----------
njs/njs_vm.c | 4 +---
3 files changed, 13 insertions(+), 15 deletions(-)

diffs (66 lines):

diff -r addefc71957b -r 39374a5d6cda njs/njs_parser.h
--- a/njs/njs_parser.h Tue Apr 03 17:55:08 2018 +0300
+++ b/njs/njs_parser.h Tue Apr 03 17:55:23 2018 +0300
@@ -389,9 +389,9 @@ nxt_bool_t njs_parser_has_side_effect(nj
u_char *njs_parser_trace_handler(nxt_trace_t *trace, nxt_trace_data_t *td,
u_char *start);
void njs_parser_syntax_error(njs_vm_t *vm, njs_parser_t *parser,
- const char* fmt, ...);
+ const char* fmt, ...);
void njs_parser_ref_error(njs_vm_t *vm, njs_parser_t *parser, const char* fmt,
- ...);
+ ...);
nxt_int_t njs_generate_scope(njs_vm_t *vm, njs_parser_t *parser,
njs_parser_node_t *node);

diff -r addefc71957b -r 39374a5d6cda njs/njs_parser_expression.c
--- a/njs/njs_parser_expression.c Tue Apr 03 17:55:08 2018 +0300
+++ b/njs/njs_parser_expression.c Tue Apr 03 17:55:23 2018 +0300
@@ -873,11 +873,11 @@ njs_parser_inc_dec_expression(njs_vm_t *
node->left = parser->node;
parser->node = node;

- parser->code_size += (node->token == NJS_TOKEN_NAME) ?
- sizeof(njs_vmcode_3addr_t):
- sizeof(njs_vmcode_prop_get_t)
- + sizeof(njs_vmcode_3addr_t)
- + sizeof(njs_vmcode_prop_set_t);
+ parser->code_size += (token == NJS_TOKEN_NAME)
+ ? sizeof(njs_vmcode_3addr_t)
+ : sizeof(njs_vmcode_prop_get_t)
+ + sizeof(njs_vmcode_3addr_t)
+ + sizeof(njs_vmcode_prop_set_t);

return next;
}
@@ -929,11 +929,11 @@ njs_parser_post_inc_dec_expression(njs_v
node->left = parser->node;
parser->node = node;

- parser->code_size += (parser->node->token == NJS_TOKEN_NAME) ?
- sizeof(njs_vmcode_3addr_t):
- sizeof(njs_vmcode_prop_get_t)
- + sizeof(njs_vmcode_3addr_t)
- + sizeof(njs_vmcode_prop_set_t);
+ parser->code_size += (token == NJS_TOKEN_NAME)
+ ? sizeof(njs_vmcode_3addr_t)
+ : sizeof(njs_vmcode_prop_get_t)
+ + sizeof(njs_vmcode_3addr_t)
+ + sizeof(njs_vmcode_prop_set_t);

return njs_parser_token(parser);
}
diff -r addefc71957b -r 39374a5d6cda njs/njs_vm.c
--- a/njs/njs_vm.c Tue Apr 03 17:55:08 2018 +0300
+++ b/njs/njs_vm.c Tue Apr 03 17:55:23 2018 +0300
@@ -2394,9 +2394,7 @@ njs_vmcode_method_frame(njs_vm_t *vm, nj
break;

case NXT_ERROR:
-
- /* An exception was set in njs_property_query(). */
-
+ /* An exception was set in njs_property_query(). */
return NXT_ERROR;

default:
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[njs] Style fixes.

Igor Sysoev 575 April 03, 2018 10:58AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 54
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready