File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1704,7 +1704,10 @@ ex_let_one(
17041704 & stringval , opt_flags );
17051705 if ((opt_type == 1 && * op == '.' )
17061706 || (opt_type == 0 && * op != '.' ))
1707+ {
17071708 EMSG2 (_ (e_letwrong ), op );
1709+ s = NULL ; /* don't set the value */
1710+ }
17081711 else
17091712 {
17101713 if (opt_type == 1 ) /* number */
Original file line number Diff line number Diff line change @@ -29,3 +29,17 @@ func Test_let_termcap()
2929 let &t_xx = " "
3030 call assert_fails (' let x = &t_xx' , ' E15' )
3131endfunc
32+
33+ func Test_let_option_error ()
34+ let _w = &tw
35+ let &tw = 80
36+ call assert_fails (' let &tw .= 1' , ' E734' )
37+ call assert_equal (80 , &tw )
38+ let &tw = _w
39+
40+ let _w = &fillchars
41+ let &fillchars = " vert:|"
42+ call assert_fails (' let &fillchars += "diff:-"' , ' E734' )
43+ call assert_equal (" vert:|" , &fillchars )
44+ let &fillchars = _w
45+ endfunc
Original file line number Diff line number Diff line change @@ -761,6 +761,8 @@ static char *(features[]) =
761761
762762static int included_patches [] =
763763{ /* Add new patch number below this line */
764+ /**/
765+ 1172 ,
764766/**/
765767 1171 ,
766768/**/
You can’t perform that action at this time.
0 commit comments