diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2018-11-02 09:09:40 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-02 09:09:40 +0100 |
commit | 87d67814e58b875a1cb4de4c39c252e028b5eafb (patch) | |
tree | 76d62b5a137b6ed1694da6bab6608c445b1968cf /src/nvim/edit.c | |
parent | 48398d61e422f74db4fa5c2e279692dd97347f41 (diff) | |
parent | a9b7debbbc7c0190324523710ea7e6ed6070222c (diff) | |
download | rneovim-87d67814e58b875a1cb4de4c39c252e028b5eafb.tar.gz rneovim-87d67814e58b875a1cb4de4c39c252e028b5eafb.tar.bz2 rneovim-87d67814e58b875a1cb4de4c39c252e028b5eafb.zip |
Merge #9184 from janlazo/vim-8.0.1758
Diffstat (limited to 'src/nvim/edit.c')
-rw-r--r-- | src/nvim/edit.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nvim/edit.c b/src/nvim/edit.c index f7ce0afd36..7a0487bb64 100644 --- a/src/nvim/edit.c +++ b/src/nvim/edit.c @@ -1096,7 +1096,7 @@ static int insert_handle_key(InsertState *s) cmdwin_result = CAR; return 0; } - if (ins_eol(s->c) && !p_im) { + if (!ins_eol(s->c) && !p_im) { return 0; // out of memory } auto_format(false, false); @@ -8356,14 +8356,14 @@ static bool ins_tab(void) /// Handle CR or NL in insert mode. /// -/// @return true when it can't undo. +/// @return false when it can't undo. static bool ins_eol(int c) { if (echeck_abbr(c + ABBR_OFF)) { - return false; + return true; } if (stop_arrow() == FAIL) { - return true; + return false; } undisplay_dollar(); @@ -8405,7 +8405,7 @@ static bool ins_eol(int c) // When inserting a line the cursor line must never be in a closed fold. foldOpenCursor(); - return !i; + return i; } /* |