Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: function definition with & operator



On 09/01/2017 04:46 PM, Bart Schaefer wrote:
> On Fri, Sep 1, 2017 at 11:09 AM, Eric Cook <llua@xxxxxxx> wrote:
>> The other week when messing around i noticed that you can define an function
>> in (what i thought would be) the background and it will remain in defined.
> 
> Background jobs are always run in a subshell, 

Exactly what i thought, but if that were the case, foo wouldn't be defined after
the first example since & was the terminator used instead of ;.

The second example behaves like i would expect.



Messages sorted by: Reverse Date, Date, Thread, Author