[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Sat, 21 May 2016 20:31:07 +0800
$> a=‘one two three”
$> eval ‘b=$a’
$> printf “%s\n” “$b”
you will get “one two three”.
What’s confusing me is that why this is working this way. From my point of
view, after expansing, 'b=$a’ will become ‘b=one two three”, so the command
evaluated is ‘b=one two three’, but there is not a command called two, so it
will fail. But it does not. So what’s happening here?
- [Help-bash] eval,
Wu Shuangrong <=