Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Add PM_DECLARED and PM_DECLAREDNULL parameter flags. | Bart Schaefer | 2021-04-13 | 1 | -0/+1 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This addresses the issue that "typeset foo" creates $foo set to an empty string, which differs from typeset handling in bash and ksh. It does this by concealing the internal value rather than alter the way internal values are defaulted. This imposes the following changes: A typeset variable with no assignment triggers NO_UNSET warnings when the name is used in parameter expansion or math. The typeset -AEFHLRTZailux options are applied upon the first assignment to the variable. Explicit unset before the first assignment discards all of those properties. If any option is applied to an existing name, historic behavior is unchanged. Consequent to the foregoing, the (t) parameter expansion flag prints nothing until after the first assignment, and the (i) and (I) subscript flags also print nothing. The bash behavior of "unset foo; typeset -p foo" is NOT used. This is called out as an emulation distinction, not a change. The test cases have not been updated, so several now fail. The test harness has been updated to declare default values. | ||||
* | users/26509: fix for r -L | Peter Stephenson | 2021-02-18 | 1 | -2/+3 |
| | | | | | fc with the -L option should ignore remote entires, rather than reading them and treating them as an error. | ||||
* | 48073: Add fc -s as POSIX way of rerunning command without starting editor | Martijn Dekker | 2021-02-17 | 1 | -2/+2 |
| | |||||
* | 47895: Remove trailing spaces from "print -ac" output lines. | Bart Schaefer | 2021-02-04 | 1 | -1/+1 |
| | |||||
* | 47301: Fix print -v metafication | Jun-ichi Takimoto | 2020-10-25 | 1 | -1/+1 |
| | |||||
* | 46168: Update $PWD and call chpwd hook after normalizing path | Matthew Martin | 2020-07-03 | 1 | -18/+17 |
| | |||||
* | typeset: Fix leaving corrupted entries in paramtab | Mikael Magnusson | 2020-06-05 | 1 | -3/+9 |
| | |||||
* | 45729: internal: Add a second parameter to zlinklist2array(), analogously to ↵ | Daniel Shahaf | 2020-05-03 | 1 | -5/+5 |
| | | | | | | hlinklist2array(). Will be used in the next commit. | ||||
* | 45660: Fix crash setting vi or emacs mode on command line. | Peter Stephenson | 2020-04-09 | 1 | -1/+1 |
| | | | | Delay setting the option until the module system is set up. | ||||
* | 45487: Missing mod_export declarations for AIX | Peter Stephenson | 2020-02-24 | 1 | -1/+1 |
| | |||||
* | 45302: bin_umask(): Queue signals around umask(). | Daniel Shahaf | 2020-01-15 | 1 | -1/+4 |
| | | | | | Otherwise, a signal handler might create files while the temporary umask is in effect. | ||||
* | 45066: internal: Document forklevel, locallevel, and exit_pending. | Daniel Shahaf | 2019-12-18 | 1 | -1/+5 |
| | |||||
* | 45058: internal: Add symbolic names to possible values of zexit()'s ↵ | Daniel Shahaf | 2019-12-17 | 1 | -11/+13 |
| | | | | "from_where" parameter. No functional change. | ||||
* | unposted: Update comment to reflect variable rename in 41012 (= ↵ | Daniel Shahaf | 2019-12-17 | 1 | -1/+1 |
| | | | | zsh-5.3.1-182-gd7110d8f0). | ||||
* | 45009: POSIX_CD needs to suppress some forms of option. | Peter Stephenson | 2019-12-12 | 1 | -1/+1 |
| | | | | | Otherwise forms of argument allowed by POSIX are interpreted as options instead. | ||||
* | 45004: Fix typos in comments | Martijn Dekker | 2019-12-11 | 1 | -2/+2 |
| | |||||
* | unposted: functions -c: Fix typo | Daniel Shahaf | 2019-10-10 | 1 | -1/+1 |
| | |||||
* | Copy functions using functions -c old new. | Peter Stephenson | 2019-08-03 | 1 | -2/+41 |
| | | | | Documentation and test. | ||||
* | 44502: Quote function name for "autoload -X" | Bart Schaefer | 2019-07-08 | 1 | -1/+1 |
| | |||||
* | 44469: correct error on missing option argument | Martijn Dekker | 2019-07-01 | 1 | -5/+12 |
| | |||||
* | 44443: POSIX allows exporting readonly variables | Martijn Dekker | 2019-06-23 | 1 | -1/+1 |
| | |||||
* | 44284: combination of -T and -p to typeset crashed the shell. | Oliver Kiddle | 2019-05-14 | 1 | -4/+2 |
| | |||||
* | 44291: printf with argument specifier out of range for an int crashed the shell | Oliver Kiddle | 2019-05-14 | 1 | -2/+1 |
| | |||||
* | 44198: Add cd_silent option to suppress all cd output | dana | 2019-04-12 | 1 | -2/+2 |
| | |||||
* | 43669: ensure explicit exit status is used over implicit | Peter Stephenson | 2018-10-10 | 1 | -2/+2 |
| | |||||
* | 43660: extend 43653 when final exit is implicit. | Peter Stephenson | 2018-10-09 | 1 | -2/+38 |
| | | | | | | | Combine logic for case after committed to exit (shell_exiting) with case where exit occurred in a function we nee to unwind (exit_pending). Add sarky note for future generations to be confused at. | ||||
* | 43656: special tied arrays don't have tieddata | Peter Stephenson | 2018-10-09 | 1 | -1/+1 |
| | |||||
* | 43653: explicit exit from EXIT trap overrides exit status | Peter Stephenson | 2018-10-09 | 1 | -4/+10 |
| | |||||
* | 43616: Various parameter setting and display fixes. | Peter Stephenson | 2018-10-08 | 1 | -43/+112 |
| | | | | | | Mostly to do with typeset -p and tied variables and their interaction. Some general tied variable fixes. | ||||
* | GitHub #28: Add missing math.h include for builtins | Jörg Thalheim | 2018-09-10 | 1 | -0/+2 |
| | | | | math.h is required for isnan/isinf | ||||
* | 43077: Fix shift builtin status. | Peter Stephenson | 2018-06-20 | 1 | -1/+6 |
| | | | | | If the math evaulation to get the shift count failed the status wasn't passed back from the builtin. | ||||
* | 42785: Allow redefining math function to work silently. | Peter Stephenson | 2018-05-17 | 1 | -9/+4 |
| | | | | | | Previously it failed with an error message that the function was already defined. This is inconsistent with most other aspects of shell usage. | ||||
* | 42488: test cases for 42369 and address some issues in the code | Oliver Kiddle | 2018-05-13 | 1 | -2/+8 |
| | |||||
* | 42601: tidy up code for set -A/+A to not increment a NULL pointer and to be ↵ | Oliver Kiddle | 2018-04-07 | 1 | -6/+4 |
| | | | | more efficient | ||||
* | 42332: Special case unsigned printf formats. | Peter Stephenson | 2018-01-31 | 1 | -1/+4 |
| | | | | | For constants we can avoid a conversion to signed by examining the expression before passing to math eval. | ||||
* | 42156: new CHECK_RUNNING_JOBS option demanded by bash groupies | Peter Stephenson | 2017-12-22 | 1 | -1/+2 |
| | | | | | | | Also new job options. Also suppress debug error if rows or columns are reported as zero as this is normal without a physical terminal. | ||||
* | 42063: getopts errors now report "+" in front of option where appropriate | dana | 2017-12-01 | 1 | -2/+3 |
| | |||||
* | 41866: No error unsetting nonexistent function for POSIXBUILTINS | Martijn Dekker | 2017-11-02 | 1 | -1/+5 |
| | |||||
* | Add typeset -p1, like typeset -p with newlines | Peter Stephenson | 2017-10-01 | 1 | -7/+20 |
| | |||||
* | First go at var=([key]=value) syntax. | Peter Stephenson | 2017-09-13 | 1 | -22/+48 |
| | | | | | | | Works for both normal and typeset case, also var+=... Still to do: allow to be mixed with straight array assignment, improve typeset -p, implement [key]+=value. | ||||
* | 41668: New --emulate option on invocation. | Peter Stephenson | 2017-09-11 | 1 | -1/+1 |
| | | | | | | | | This sets the shell emulation mode similarly to ARGV0=... which doesn't work from other shells. Note that this gives more comprehensive emulation than running emulate within the shell. | ||||
* | 41284: Fix NULL dereference in cd. | Peter Stephenson | 2017-06-13 | 1 | -1/+10 |
| | | | | | This happened in sh compatiblity mode if HOME was not set and cd was used with no argument. | ||||
* | 41244: Add zmodload -s option. | Peter Stephenson | 2017-06-12 | 1 | -1/+1 |
| | | | | | | | | Doesn't complain if module is unavailable, but prints more obscure errors. Use existing low-level silent flag by passing through intermediate module loading hierarchy. | ||||
* | 41012: Fix premature exit from nested function in EXIT trap. | Peter Stephenson | 2017-04-27 | 1 | -7/+16 |
| | | | | | | Also add check so we don't delay an exit if we were already in an EXIT trap for the main shell, as we should in that case leave immediately. | ||||
* | 40622 with typos fixed: functions -Ms. | Peter Stephenson | 2017-03-01 | 1 | -3/+20 |
| | | | | | | This adds the capability for mathematical functions based on shell functions to have a string argument. Module functions have had this for a long time. | ||||
* | 40536: Prepend directory to $fpath. | Peter Stephenson | 2017-02-13 | 1 | -0/+36 |
| | | | | | | Used if parent function is autoloaded by absolute path so as to find functions in the same suite without shell code modification. | ||||
* | 40453: signal handler safety for callers of patcompile(PAT_STATIC), which is ↵ | Barton E. Schaefer | 2017-01-29 | 1 | -17/+20 |
| | | | | not re-entrant. | ||||
* | 40404: Only quote command in whence output with -v. | Peter Stephenson | 2017-01-24 | 1 | -4/+8 |
| | |||||
* | 40391: Add WARN_NESTED_VAR option and functions -W. | Peter Stephenson | 2017-01-23 | 1 | -4/+8 |
| | | | | | These are companions to WARN_CREATED_GLOBAL, warning when a variable from an enclosing scope is altered. | ||||
* | 40375: autoload with explicit path mustn't trash already loaded function. | Peter Stephenson | 2017-01-18 | 1 | -0/+25 |
| | | | | | Also remove unnecessary dupstring() on already duplicated string when expanding =cmd. |