From: Daiki Ueno Date: Fri, 31 May 2013 03:52:10 +0000 (+0900) Subject: Minor cleanup of JavaScript support. X-Git-Tag: v0.18.3~38 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=48a930996645c508a5cadac066d3056070960cac;p=thirdparty%2Fgettext.git Minor cleanup of JavaScript support. --- diff --git a/gettext-tools/src/x-javascript.c b/gettext-tools/src/x-javascript.c index 654235507..565d84ff0 100644 --- a/gettext-tools/src/x-javascript.c +++ b/gettext-tools/src/x-javascript.c @@ -1,5 +1,5 @@ /* xgettext JavaScript backend. - Copyright (C) 2002-2003, 2005-2009 Free Software Foundation, Inc. + Copyright (C) 2002-2003, 2005-2009, 2013 Free Software Foundation, Inc. This file was written by Andreas Stricker , 2010 It's based on x-python from Bruno Haible. @@ -1310,7 +1310,6 @@ phase5_get (token_ty *tp) /* Identify operators. The multiple character ones are simply ignored * as they are recognized here and are otherwise not relevant. */ - /* FALLTHROUGH */ case '-': case '*': /* '+' and '/' are not listed here! */ case '%': case '<': case '>': case '=': case '~': case '!': case '|': case '&': case '^': @@ -1346,12 +1345,12 @@ phase5_get (token_ty *tp) tp->type = last_token_type = token_type_comma; return; - case '[': case '{': - tp->type = last_token_type = (c == '[' ? token_type_lbracket : token_type_other); + case '[': + tp->type = last_token_type = token_type_lbracket; return; - case ']': case '}': - tp->type = last_token_type = (c == ']' ? token_type_rbracket : token_type_other); + case ']': + tp->type = last_token_type = token_type_rbracket; return; default: @@ -1592,7 +1591,6 @@ extract_balanced (message_list_ty *mlp, xgettext_current_source_encoding = xgettext_current_file_source_encoding; return true; - /* FALLTHROUGH */ case token_type_keyword: case token_type_plus: case token_type_regexp: diff --git a/gettext-tools/src/x-javascript.h b/gettext-tools/src/x-javascript.h index d6681365b..da40f71c1 100644 --- a/gettext-tools/src/x-javascript.h +++ b/gettext-tools/src/x-javascript.h @@ -1,5 +1,5 @@ -/* xgettext Python backend. - Copyright (C) 2002-2003, 2006 Free Software Foundation, Inc. +/* xgettext JavaScript backend. + Copyright (C) 2002-2003, 2006, 2013 Free Software Foundation, Inc. This file was written by Andreas Stricker , 2010. It's based on x-python from Bruno Haible.