diff --git a/ChangeLog b/ChangeLog index 983bbe70b68786c8ec83f2b713424f47b74beab9..3bf75d4ab08e396bfb7870a057299b94c57127e8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,7 @@ only when it contains a multicolumn character, to spare all regular text this significant slowdown. This fixes Savannah bug #45684 reported by Wyatt Ward. + * src/move.c (do_prev_word): Drop a return value that is never used. 2015-09-04 Benno Schulenberg <bensberg@justemail.net> * src/chars.c: Reverting r5354 from August 12. This fixes Savannah diff --git a/src/move.c b/src/move.c index 520cf4a91f43b17f0ece0ce59b739658bb0db957..b88980020fbc9e686664189afb91ae4396561bf8 100644 --- a/src/move.c +++ b/src/move.c @@ -312,15 +312,14 @@ void do_next_word_void(void) /* Move to the previous word in the file. If allow_punct is TRUE, treat * punctuation as part of a word. If allow_update is TRUE, update the - * screen afterwards. Return TRUE if we started on a word, and FALSE - * otherwise. */ -bool do_prev_word(bool allow_punct, bool allow_update) + * screen afterwards. */ +void do_prev_word(bool allow_punct, bool allow_update) { size_t pww_save = openfile->placewewant; filestruct *current_save = openfile->current; char *char_mb; int char_mb_len; - bool begin_line = FALSE, started_on_word = FALSE; + bool begin_line = FALSE; assert(openfile->current != NULL && openfile->current->data != NULL); @@ -337,10 +336,6 @@ bool do_prev_word(bool allow_punct, bool allow_update) if (!is_word_mbchar(char_mb, allow_punct)) break; - /* If we haven't found it, then we've started on a word, so set - * started_on_word to TRUE. */ - started_on_word = TRUE; - if (openfile->current_x == 0) begin_line = TRUE; else @@ -428,9 +423,6 @@ bool do_prev_word(bool allow_punct, bool allow_update) /* If allow_update is TRUE, update the screen. */ if (allow_update) edit_redraw(current_save, pww_save); - - /* Return whether we started on a word. */ - return started_on_word; } /* Move to the previous word in the file, treating punctuation as part diff --git a/src/proto.h b/src/proto.h index 5083b21be404318979de8cd9df66fce57f557bd9..f6d1709947d82932b677747b1a5d6cd54c04f88b 100644 --- a/src/proto.h +++ b/src/proto.h @@ -394,7 +394,7 @@ void do_para_end_void(void); #ifndef NANO_TINY bool do_next_word(bool allow_punct, bool allow_update); void do_next_word_void(void); -bool do_prev_word(bool allow_punct, bool allow_update); +void do_prev_word(bool allow_punct, bool allow_update); void do_prev_word_void(void); #endif void do_home(void);