]> git.pld-linux.org Git - packages/vim.git/blame - 7.3.249
- new
[packages/vim.git] / 7.3.249
CommitLineData
e5642dac 1To: vim_dev@googlegroups.com
2Subject: Patch 7.3.249
3Fcc: outbox
4From: Bram Moolenaar <Bram@moolenaar.net>
5Mime-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
8------------
9
10Patch 7.3.249
11Problem: Wrong indenting for array initializer.
12Solution: Detect '}' in a better way. (Lech Lorens)
13Files: src/misc1.c, src/testdir/test3.in, src/testdir/test3.ok
14
15
16*** ../vim-7.3.248/src/misc1.c 2011-06-12 21:51:01.000000000 +0200
17--- src/misc1.c 2011-07-15 14:06:44.000000000 +0200
18***************
19*** 7945,7952 ****
20 * If we're at the end of a block, skip to the start of
21 * that block.
22 */
23! curwin->w_cursor.col = 0;
24! if (*cin_skipcomment(l) == '}'
25 && (trypos = find_start_brace(ind_maxcomment))
26 != NULL) /* XXX */
27 {
28--- 7945,7951 ----
29 * If we're at the end of a block, skip to the start of
30 * that block.
31 */
32! if (find_last_paren(l, '{', '}')
33 && (trypos = find_start_brace(ind_maxcomment))
34 != NULL) /* XXX */
35 {
36*** ../vim-7.3.248/src/testdir/test3.in 2011-06-12 21:51:01.000000000 +0200
37--- src/testdir/test3.in 2011-07-15 14:03:41.000000000 +0200
38***************
39*** 1452,1457 ****
40--- 1452,1487 ----
41
42 STARTTEST
43 :set cino&
44+ :set cino+=l1
45+ 2kdd=][
46+ ENDTEST
47+
48+ void func(void)
49+ {
50+ int tab[] =
51+ {
52+ 1, 2, 3,
53+ 4, 5, 6};
54+
55+ printf("Indent this line correctly!\n");
56+
57+ switch (foo)
58+ {
59+ case bar:
60+ printf("bar");
61+ break;
62+ case baz: {
63+ printf("baz");
64+ break;
65+ }
66+ case quux:
67+ printf("But don't break the indentation of this instruction\n");
68+ break;
69+ }
70+ }
71+
72+ STARTTEST
73+ :set cino&
74 2kdd=][
75 ENDTEST
76
77*** ../vim-7.3.248/src/testdir/test3.ok 2011-06-12 21:51:01.000000000 +0200
78--- src/testdir/test3.ok 2011-07-15 14:03:41.000000000 +0200
79***************
80*** 1310,1315 ****
81--- 1310,1340 ----
82
83 void func(void)
84 {
85+ int tab[] =
86+ {
87+ 1, 2, 3,
88+ 4, 5, 6};
89+
90+ printf("Indent this line correctly!\n");
91+
92+ switch (foo)
93+ {
94+ case bar:
95+ printf("bar");
96+ break;
97+ case baz: {
98+ printf("baz");
99+ break;
100+ }
101+ case quux:
102+ printf("But don't break the indentation of this instruction\n");
103+ break;
104+ }
105+ }
106+
107+
108+ void func(void)
109+ {
110 cout << "a"
111 << "b"
112 << ") :"
113*** ../vim-7.3.248/src/version.c 2011-07-15 13:51:57.000000000 +0200
114--- src/version.c 2011-07-15 14:12:05.000000000 +0200
115***************
116*** 711,712 ****
117--- 711,714 ----
118 { /* Add new patch number below this line */
119+ /**/
120+ 249,
121 /**/
122
123--
124 GALAHAD hurries to the door and pushes through it. As he leaves the room
125 we CUT TO the reverse to show that he is now in a room full of bathing
126 and romping GIRLIES, all innocent, wide-eyed and beautiful. They smile
127 enchantingly at him as he tries to keep walking without being diverted by
128 the lovely sights assaulting his eyeballs.
129 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
130
131 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
132/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
133\\\ an exciting new programming language -- http://www.Zimbu.org ///
134 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///
This page took 0.035416 seconds and 4 git commands to generate.