[U-Boot] [PATCH V4 06/12] cmd_test: implement ! on sub-expressions

Tom Rini trini at ti.com
Tue Feb 4 23:07:32 CET 2014


On Mon, Feb 03, 2014 at 01:21:04PM -0700, Stephen Warren wrote:

> From: Stephen Warren <swarren at nvidia.com>
> 
> Currently, ! can only be parsed as the first operator in an expression.
> This prevents the following from working:
> 
> $ if test ! ! 1 -eq 1; then echo yes; else echo no; fi
> yes
> $ if test ! 1 -eq 2 -a ! 3 -eq 4; then echo yes; else echo no; fi
> yes
> 
> Fix this by parsing ! like any other operator, and and handling it
> similarly to -a and -o.
> 
> Signed-off-by: Stephen Warren <swarren at nvidia.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140204/4547f5cd/attachment.pgp>


More information about the U-Boot mailing list