Skip to content

Instantly share code, notes, and snippets.

View h-east's full-sized avatar

h_east h-east

  • Osaka, Japan
  • 00:31 (UTC +09:00)
View GitHub Profile
diff -r 8cae3b61ce9e runtime/doc/eval.txt
--- a/runtime/doc/eval.txt Mon Dec 08 04:16:45 2014 +0100
+++ b/runtime/doc/eval.txt Wed Dec 10 18:26:51 2014 +0900
@@ -1158,7 +1158,7 @@
This kind of variable is deleted when the buffer is wiped out or deleted with
|:bdelete|.
-One local buffer variable is predefined:
+Two local buffer variables are predefined:
*b:changedtick* *changetick*
@h-east
h-east / 682_east.patch
Last active August 29, 2015 14:12
vim-jp/Issues/682 another patch
diff -r ec27922631d8 src/edit.c
--- a/src/edit.c Tue Feb 03 13:16:04 2015 +0100
+++ b/src/edit.c Wed Feb 04 00:23:31 2015 +0900
@@ -34,8 +34,10 @@
#define CTRL_X_OMNI 13
#define CTRL_X_SPELL 14
#define CTRL_X_LOCAL_MSG 15 /* only used in "ctrl_x_msgs" */
+#define CTRL_X_EVAL 16 /* for builtin function complete() */
#define CTRL_X_MSG(i) ctrl_x_msgs[(i) & ~CTRL_X_WANT_IDENT]
@h-east
h-east / gist:e0391bd78654766bfba8
Created February 2, 2015 10:14
specification inconsistency between 'complete()' and 'backspace'.
I found specification inconsistency between 'complete()' and 'backspace' option.
How to reproduce:
- cat test.vim
inoremap <F5> <C-R>=ListMonths()<CR>
func! ListMonths()
call complete(1, ['One', 'Three'])
return ''
endfunc
(function(){
var a = [
'a',
'b',
'c',
'd',
'e',
'f',
'g',
'h',
diff -r 03e6a768a028 src/misc1.c
--- a/src/misc1.c Sun Mar 08 14:48:49 2015 +0100
+++ b/src/misc1.c Tue Mar 10 00:57:53 2015 +0900
@@ -6670,20 +6670,43 @@
pos_T cursor_save;
pos_T *trypos;
static pos_T pos_copy;
+ int ind_maxp_wk;
cursor_save = curwin->w_cursor;
diff -r 03e6a768a028 src/ex_docmd.c
--- a/src/ex_docmd.c Sun Mar 08 14:48:49 2015 +0100
+++ b/src/ex_docmd.c Tue Mar 10 16:37:43 2015 +0900
@@ -8145,7 +8145,7 @@
ex_tabmove(eap)
exarg_T *eap;
{
- int tab_number = 9999;
+ int tab_number;
diff -r 3bd553b9e4bf runtime/doc/tabpage.txt
--- a/runtime/doc/tabpage.txt Sat Mar 14 15:35:52 2015 +0100
+++ b/runtime/doc/tabpage.txt Tue Mar 17 15:09:50 2015 +0900
@@ -202,23 +202,29 @@
Move the current tab page to after tab page N. Use zero to
make the current tab page the first one. Without N the tab
page is made the last one. >
+ :.tabmove " do nothing
:-tabmove " move the tab page to the left
- :tabmove " move the tab page to the right
0000000: 6469 6666 202d 7220 3362 6435 3533 6239 diff -r 3bd553b9
0000010: 6534 6266 2072 756e 7469 6d65 2f64 6f63 e4bf runtime/doc
0000020: 2f74 6162 7061 6765 2e74 7874 0a2d 2d2d /tabpage.txt.---
0000030: 2061 2f72 756e 7469 6d65 2f64 6f63 2f74 a/runtime/doc/t
0000040: 6162 7061 6765 2e74 7874 0953 6174 204d abpage.txt.Sat M
0000050: 6172 2031 3420 3135 3a33 353a 3532 2032 ar 14 15:35:52 2
0000060: 3031 3520 2b30 3130 300a 2b2b 2b20 622f 015 +0100.+++ b/
0000070: 7275 6e74 696d 652f 646f 632f 7461 6270 runtime/doc/tabp
0000080: 6167 652e 7478 7409 5475 6520 4d61 7220 age.txt.Tue Mar
0000090: 3137 2031 353a 3039 3a35 3020 3230 3135 17 15:09:50 2015
$ vim -N -u NONE -p 1 2 3 4 5 -c "tabnext"
1 [2] 3 4 5 " Now tab page status. [ ] is current tab page.
(1) :tabm " 1 3 4 5 [2] move to last
(2) :.tabm " do nothing
(3) :.+tabm " 1 3 [2] 4 5 Move to the right
(4) :.+1tabm " as above
(5) :+tabm " as above
(6) :+1tabm " as above
(7) :tabm + " as above
@h-east
h-east / 20.patch
Last active August 29, 2015 14:18
Patch for https://github.com/vim-jp/issues/issues/20 (Contain debug code)
diff -r 39e174e02dec src/misc1.c
--- a/src/misc1.c Thu Apr 09 22:08:22 2015 +0200
+++ b/src/misc1.c Sat Apr 11 08:26:08 2015 +0900
@@ -26,6 +26,11 @@
static garray_T ga_users;
#endif
+static FILE *sFp = NULL;
+
+#define VIM_DEBUG_LOG(fmt, ...) \