pgas mentioned ksh93 does [[ $foo ]] (ipv forced [[ -n $foo ]])
and it actually REDUCES code size to allow it as well; mention in the manpage that it’s merely unportable (and of course exe- cution time differs); sync clog
This commit is contained in:
6
funcs.c
6
funcs.c
@ -25,7 +25,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.108 2009/05/20 10:10:01 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.109 2009/05/21 14:28:33 tg Exp $");
|
||||
|
||||
/* A leading = means assignments before command are kept;
|
||||
* a leading * means a POSIX special builtin;
|
||||
@ -2825,10 +2825,6 @@ test_primary(Test_env *te, bool do_eval)
|
||||
|
||||
return (*te->eval)(te, op, opnd1, opnd2, do_eval);
|
||||
}
|
||||
if (te->flags & TEF_DBRACKET) {
|
||||
(*te->error)(te, -1, "missing expression operator");
|
||||
return 0;
|
||||
}
|
||||
return (*te->eval)(te, TO_STNZE, opnd1, NULL, do_eval);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user