Subject: Re: Aliasing assignment-ish words (aliases[x=y]=z)
From: Bart Schaefer <[email-masked]>
To: [email-masked]
Date: Mon, 11 Jan 2016 23:44:29 -0800
List-Id: Zsh Workers List <zsh-workers.zsh.org>

On Jan 10,  7:50pm, Daniel Shahaf wrote:
}
} I thought we might want to have 'alias -L' handle LHSes with '=' in them
} specially: omit them from the output with a warning, or maybe fail hard

Yeah, that probably wouldn't be too difficult (I'd go with the warning).

} For what it's worth, the real-world use-case behind this thread is
} a z-sy-h user whose zshrc has an alias "aliases[=]='noglob ='" and
} a function literally named '='.  (That alias works as expected, as
} does "aliases[=ls]='...'" even if EQUALS is set.)

Hm, it also ought to be possible to special case a word starting with
'=' (since it's not possible to alias the empty string to anything).

I find this interesting:

    torch% alias '==foo'
    zsh: bad assignment

"Bad assignment"?