zsh-workers
 help / color / mirror / code / Atom feed
* Re: variable problem
  1999-03-25 17:08 variable problem Thomas Ziehmer
@ 1999-03-25 17:03 ` Bruce Stephens
  0 siblings, 0 replies; 2+ messages in thread
From: Bruce Stephens @ 1999-03-25 17:03 UTC (permalink / raw)
  To: zsh-workers

Thomas Ziehmer <ziehmer@rhrk.uni-kl.de> writes:

> I got into the following problem (only tested on zsh-3.1*)
> 
> thomas@digger [thomas]> a='echo x'
> thomas@digger [thomas]> echo $a
> echo x
> thomas@digger [thomas]> $a
> zsh: command not found: echo x
>  
> The correct output would be 'x'. I get the correct output in other shells
> (sh,ksh,bash).

No, you get the incorrect output in other shells.  This is the famous
SHWORDSPLIT issue mentioned in the FAQ (which says that all other
shells are broken).

If you use

        % a=(echo x)

instead, then things will work as you want.  Or setopt SHWORDSPLIT, or
use whatever magic it is to do SHWORDSPLIT on expansion (the $a line).


^ permalink raw reply	[flat|nested] 2+ messages in thread

* variable problem
@ 1999-03-25 17:08 Thomas Ziehmer
  1999-03-25 17:03 ` Bruce Stephens
  0 siblings, 1 reply; 2+ messages in thread
From: Thomas Ziehmer @ 1999-03-25 17:08 UTC (permalink / raw)
  To: zsh-workers

Hallo,
I got into the following problem (only tested on zsh-3.1*)

thomas@digger [thomas]> a='echo x'
thomas@digger [thomas]> echo $a
echo x
thomas@digger [thomas]> $a
zsh: command not found: echo x
 
The correct output would be 'x'. I get the correct output in other shells
(sh,ksh,bash).

Regards
Thomas Ziehmer


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1999-03-25 17:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-03-25 17:08 variable problem Thomas Ziehmer
1999-03-25 17:03 ` Bruce Stephens

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).