]> granicus.if.org Git - vim/commitdiff
updated for version 7.3.076 v7.3.076
authorBram Moolenaar <Bram@vim.org>
Wed, 8 Dec 2010 12:11:21 +0000 (13:11 +0100)
committerBram Moolenaar <Bram@vim.org>
Wed, 8 Dec 2010 12:11:21 +0000 (13:11 +0100)
Problem:    Clang warnings for dead code.
Solution:   Remove it. (Carlo Teubner)

src/gui_gtk.c
src/if_ruby.c
src/misc2.c
src/netbeans.c
src/spell.c
src/version.c

index 326a30cff6526425f714e1689a478bcd96f6e8f1..b95f46a7f9c37bcac029559ed71a934b39308e68 100644 (file)
@@ -1798,7 +1798,6 @@ find_replace_cb(GtkWidget *widget UNUSED, gpointer data)
     char_u             *repl_text;
     gboolean           direction_down;
     SharedFindReplace  *sfr;
-    int                        rc;
 
     flags = (int)(long)data;       /* avoid a lint warning here */
 
@@ -1824,7 +1823,7 @@ find_replace_cb(GtkWidget *widget UNUSED, gpointer data)
 
     repl_text = CONVERT_FROM_UTF8(repl_text);
     find_text = CONVERT_FROM_UTF8(find_text);
-    rc = gui_do_findrepl(flags, find_text, repl_text, direction_down);
+    gui_do_findrepl(flags, find_text, repl_text, direction_down);
     CONVERT_FROM_UTF8_FREE(repl_text);
     CONVERT_FROM_UTF8_FREE(find_text);
 }
index 70f6046a34670acd8e06445de75720346fb5f6a5..18e43f481ea290c5ceded28d39f4426b9c67baa1 100644 (file)
@@ -586,9 +586,9 @@ void ex_rubydo(exarg_T *eap)
        if (u_save(eap->line1 - 1, eap->line2 + 1) != OK)
            return;
        for (i = eap->line1; i <= eap->line2; i++) {
-           VALUE line, oldline;
+           VALUE line;
 
-           line = oldline = vim_str2rb_enc_str((char *)ml_get(i));
+           line = vim_str2rb_enc_str((char *)ml_get(i));
            rb_lastline_set(line);
            eval_enc_string_protect((char *) eap->arg, &state);
            if (state) {
index 2db4b663ff48390139f59d21837cd288b64cd67e..c6f4f112d2cf0c183f0d454383f4f340ee96475c 100644 (file)
@@ -200,7 +200,6 @@ coladvance2(pos, addspaces, finetune, wcol)
        }
 #endif
 
-       idx = -1;
        ptr = line;
        while (col <= wcol && *ptr != NUL)
        {
@@ -1223,7 +1222,7 @@ free_all_mem()
 #endif
 
 /*
- * copy a string into newly allocated memory
+ * Copy "string" into newly allocated memory.
  */
     char_u *
 vim_strsave(string)
@@ -1239,6 +1238,12 @@ vim_strsave(string)
     return p;
 }
 
+/*
+ * Copy up to "len" bytes of "string" into newly allocated memory and
+ * terminate with a NUL.
+ * The allocated memory always has size "len + 1", also when "string" is
+ * shorter.
+ */
     char_u *
 vim_strnsave(string, len)
     char_u     *string;
index 3134db9d238262bc2bba9f0feba5b08c8ce158b1..853df364affc393a6afc9d51c208b2bc969c5b0c 100644 (file)
@@ -960,7 +960,6 @@ nb_free()
     keyQ_T *key_node = keyHead.next;
     queue_T *cmd_node = head.next;
     nbbuf_T buf;
-    buf_T *bufp;
     int i;
 
     /* free the netbeans buffer list */
@@ -969,7 +968,7 @@ nb_free()
        buf = buf_list[i];
        vim_free(buf.displayname);
        vim_free(buf.signmap);
-       if ((bufp=buf.bufp) != NULL)
+       if (buf.bufp != NULL)
        {
            buf.bufp->b_netbeans_file = FALSE;
            buf.bufp->b_was_netbeans_file = FALSE;
index d34cc945926d25ddcf31d18b8f191547260954dc..ca881ec49e5584afed6a6ec7f9bd66ebaf8f1787 100644 (file)
@@ -9839,10 +9839,7 @@ spell_iswordp(p, wp)
        {
            /* be quick for ASCII */
            if (wp->w_s->b_spell_ismw[*p])
-           {
                s = p + 1;              /* skip a mid-word character */
-               l = MB_BYTE2LEN(*s);
-           }
        }
        else
        {
@@ -9850,10 +9847,7 @@ spell_iswordp(p, wp)
            if (c < 256 ? wp->w_s->b_spell_ismw[c]
                    : (wp->w_s->b_spell_ismw_mb != NULL
                           && vim_strchr(wp->w_s->b_spell_ismw_mb, c) != NULL))
-           {
                s = p + l;
-               l = MB_BYTE2LEN(*s);
-           }
        }
 
        c = mb_ptr2char(s);
@@ -13813,11 +13807,8 @@ add_suggestion(su, gap, goodword, badlenarg, score, altscore, had_bonus,
                    su->su_sfmaxscore = cleanup_suggestions(gap,
                                      su->su_sfmaxscore, SUG_CLEAN_COUNT(su));
                else
-               {
-                   i = su->su_maxscore;
                    su->su_maxscore = cleanup_suggestions(gap,
                                        su->su_maxscore, SUG_CLEAN_COUNT(su));
-               }
            }
        }
     }
index 489e59e398c97a6489db41cd96315ed9d84b558a..f1bd0ab6de25b54196f522595f639c3daf8b2994 100644 (file)
@@ -714,6 +714,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    76,
 /**/
     75,
 /**/