Oliver Kiddle
c2b7c5abbe
40269: handle option exclusion within current word for clumped options
...
This replaces the change made in 13999 with an alternative approach.
2017-01-05 13:31:13 +01:00
Oliver Kiddle
8be732cbcc
40227: handle _arguments sets and rest arguments starting with a dash
...
This is a new approach to the problem first covered by 39611: checking
to see if an option-like argument belongs to one of the other sets.
2017-01-04 14:50:56 +01:00
Oliver Kiddle
a69b19d215
40226: tidy up some of the _arguments set code
...
Remove old code for applying explicit exclusions between sets which
fixes some odd behaviour. Some struct members were unused. Also added
some comments and test cases.
2017-01-04 14:42:39 +01:00
Barton E. Schaefer
c4dba4f2e6
users/22319: ${ary1:^ary2} should not change isarr state of expansion of ary1
...
Unless ary1 is made from a scalar, semantics of (@) in double quotes is lost.
2017-01-03 14:44:12 -08:00
Barton E. Schaefer
d0f7a3b2d6
40248: suppress errors from zshaddhistoryhook
...
and do not call it if no history entry will be written
2017-01-03 14:43:32 -08:00
Peter Stephenson
e90a512aa6
40265: Fix problems with pure string in patterns with Meta.
...
Copy instead of relying on jiggery pokery with memory reallocation.
Problem was triggering with string ending with Dash converted to -.
2017-01-03 14:43:41 +00:00
Paulo Andrade
8d4c98540d
40260: zero new space allocated in prompt buffer
2017-01-03 12:00:18 +00:00
Sebastian Gniazdowski
4fb4ce190c
40231: Optimise setarrvalue().
2016-12-28 05:29:59 +00:00
Oliver Kiddle
02eb1595e8
40162: _arguments support for a match spec in combination with sets
2016-12-22 16:12:42 +01:00
Barton E. Schaefer
dc1f3aae60
40179: fix handling of "printf -" and "printf --"
...
unposted: regression test for 40179 / 37467
2016-12-14 11:01:09 -08:00
Barton E. Schaefer
efd3baf2a2
40134: silence spurious compiler warnings.
2016-12-10 19:13:53 -08:00
Daniel Shahaf
7e40a89053
40117: Revert a hunk of 40035 that changed semantics incorrectly.
2016-12-09 10:37:04 +00:00
Oliver Kiddle
8c4e1b6832
40129: revert 39611, add code comments and test cases for _arguments
2016-12-09 00:00:30 +01:00
Oliver Kiddle
7630215ba0
40119: correct typo in comment
2016-12-08 23:55:53 +01:00
Peter Stephenson
0e4aa6f2f6
Additional case for ERR_RETURN and ERR_EXIT.
...
Don't trigger just because status is non-zero at end of
current shell group.
2016-12-05 12:29:23 +00:00
Peter Stephenson
c03228f9ed
Extra case for ERR_RETURN and ERR_EXIT.
...
Don't trigger just because status is non-zero at end of
complex shell construct as this may be a case we've already
suppressed.
2016-12-05 11:21:01 +00:00
Barton E. Schaefer
a409adc33b
40071: change Dash back to "-" before evaluating named directory expansions
2016-12-03 15:00:46 -08:00
Daniel Shahaf
334ed65e27
40068: Abort execution when setuid/setgid fail.
...
The incumbent code would print an error message and continue execution
with the previous uid/gid values, not even setting lastval:
% UID=42 id -u; echo $?
zsh: failed to change user ID: operation not permitted
1000
0
%
2016-12-03 10:00:08 +00:00
Daniel Shahaf
fd2ca229dd
40067: internal: Document 'cmatcher', parse_cmatcher(), 'comptoend', unsetparam_pm(), and getindex().
2016-12-03 09:54:11 +00:00
Jun-ichi Takimoto
e8699613bc
40050: prepend /**/ to global functions and #ifdefs
2016-12-01 08:58:29 +09:00
Peter Stephenson
e8df1c7056
40043: fix computil.c indentation (cosmetic)
2016-11-30 16:19:21 +00:00
Barton E. Schaefer
3ba86f4db4
40034: clear badcshglob when ignoring errors
2016-11-29 12:35:57 -08:00
Barton E. Schaefer
a9fe87e18c
40032: consistency in handling of subscript slices outside the bounds of an array parameter
...
unposted: README: example describing 40032
2016-11-29 12:31:33 -08:00
Joshua Rubin
596ba302e6
40037: Unicode 9 character width support.
...
Enable with --enable-unicode9.
2016-11-29 17:19:53 +00:00
Eitan Adler
110ffae9fe
40035: Cosmetic fixes for comments and documentation.
...
Mostly fixes to doubled words.
2016-11-29 17:13:52 +00:00
Peter Stephenson
32daf2a0aa
40026: Fix for completion after redirection.
...
This could get confused about where we were in the command
line word array e.g. after the > of "!> .". Also take more care
if does confused, with debug output. Also neaten up one
obscure test.
2016-11-29 17:08:56 +00:00
Daniel Shahaf
a81f280bfa
40010: builtins: Say 'bad option: +x', not 'bad option: -x', when +x was passed.
2016-11-28 07:16:38 +00:00
Daniel Shahaf
3a8727dc6b
40009: alias -L: Emit aliases that begin with a plus sign correctly.
2016-11-28 07:16:37 +00:00
Oliver Kiddle
2e44ac72f6
unposted: fix to compile on Solaris where curses.h has a #define for reg to register
2016-11-24 16:11:52 +01:00
Oliver Kiddle
3570172d3b
40003: include "0-"9 vi buffers in the registers associative array
2016-11-24 16:05:00 +01:00
Daniel Shahaf
b3a88a53d3
39982: $SPROMPT: Don't accept a spelling correction at space/tab.
...
The patch also downscopes a couple of local variables, with no
functional change.
2016-11-24 08:18:28 +00:00
Bart Schaefer
c0f95d07e7
unposted: clear ERRFLAG_ERROR before invoking immortal widget (cf. 39934)
...
Updates commit cbb9ca3d
2016-11-23 18:15:17 -08:00
Oliver Kiddle
ee1222454e
unposted: fix printf -v to an array without format string reuse
2016-11-23 11:52:12 +01:00
Daniel Shahaf
1f5c734f5e
39981: Make compstate[to_end] skip suffix and hidden suffix, but not ignored suffix.
...
Motivated by 39930.
2016-11-21 05:40:09 +00:00
Oliver Kiddle
cb5f100bd3
39986, 39989: improve handling of vi-repeat-change
...
Save previous vi change and throw away a new change that fails.
Add zle -f vichange to allow shell widget to be a single change.
Fix repeat of command where numeric arguments were multiplied.
2016-11-20 23:59:48 +01:00
Guillaume Maudoux
dae21874d4
39900: Add TERMINFO_DIRS special like TERMINFO.
...
Although this is a colon-separated array there is no tied array.
2016-11-20 20:24:15 +00:00
Peter Stephenson
368884a3aa
39995 (from 39977): Optimise string parameter assignment.
...
If setter is the standard one and string length is unchnaged we can
copy into place.
2016-11-20 19:41:52 +00:00
Daniel Shahaf
f35198d837
39992: setarrvalue: Allocate a correctly-sized array.
...
No memory was lost; the array was allocated with room for one (char *) element
more than was required.
2016-11-20 11:56:02 +00:00
Daniel Shahaf
6e1684e332
unposted (after 39952): Restore C89 compatibility.
2016-11-20 08:09:33 +00:00
Peter Stephenson
a62e1640bc
39958: Add extra byte to PATH_MAX allocations.
...
This ensures we've got enough space for a null, although this
isn't always needed.
2016-11-17 19:49:17 +00:00
Daniel Shahaf
c392e6c620
39915: whence: Honor PATH_DIRS option for arguments that start with './' or '../'.
...
While here, add some docstrings.
2016-11-17 15:28:42 +00:00
Oliver Kiddle
0a6098a1d4
39962: bind vi case conversion widgets
...
u/U in visual mode and g~ from normal mode
2016-11-17 12:32:28 +01:00
Oliver Kiddle
48bdcd7713
39959: when repeating vi changes advance through the numbered killring registers
...
Also fix numeric arguments with vi-repeat-change: and argument passed
to the repeat replaces that previously saved with the change.
2016-11-17 12:28:08 +01:00
Oliver Kiddle
6d991ce177
39952: add registers special parameter to provide access to the vi register buffers from a zle widget function
2016-11-17 12:27:52 +01:00
Oliver Kiddle
7d2f805008
39945: allow further tab presses to move on to menu completion even when compstate[insert] is emptied
2016-11-16 09:42:49 +01:00
Barton E. Schaefer
98b7960c78
39943: no need to compute arrlen() in arrdup_max() when max == 0.
2016-11-15 10:04:14 -08:00
Peter Stephenson
921b39ac6b
39949: Special case for "-" in directory names.
...
It can be sh-tokenized to Dash to allow for appearing in ranges
after substitution, so needs to be turned back to "-" in that case.
2016-11-15 18:01:32 +00:00
Jun-ichi Takimoto
3fd50d06a1
39937: fix a problem introduced by 39886.
...
$a[i,j] should become an empty array if i>j.
2016-11-15 00:17:35 +09:00
Peter Stephenson
99acd1e7f4
39906: More multibyte optimisations for US-ASCII.
...
This treats characters 0 to 0x7f as single byte US-ASCII along
the lines we already do in other places in the code.
2016-11-14 10:12:04 +00:00
Barton E. Schaefer
56e3d23b98
unposted: comment in zlecallhook() points to redrawhook() just in case
2016-11-13 18:15:23 -08:00