]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Minor cleanup of JavaScript support.
authorDaiki Ueno <ueno@gnu.org>
Fri, 31 May 2013 03:52:10 +0000 (12:52 +0900)
committerDaiki Ueno <ueno@gnu.org>
Fri, 31 May 2013 05:01:16 +0000 (14:01 +0900)
gettext-tools/src/x-javascript.c
gettext-tools/src/x-javascript.h

index 654235507c1a2f618f2043b57f1d0665a4ae886d..565d84ff064d3da01191b197cbbe3873671371cc 100644 (file)
@@ -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 <andy@knitter.ch>, 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:
index d6681365b6f9fc12c1cf8c241910d07dc5c86281..da40f71c1a985cbcee26d3af21ad4f5fbc090b18 100644 (file)
@@ -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 <andy@knitter.ch>, 2010.
    It's based on x-python from Bruno Haible.