mirror of
https://github.com/go-sylixos/elvish.git
synced 2024-12-15 03:37:52 +08:00
Builtin == now throws when given 0 argument.
This commit is contained in:
parent
d38f5feefc
commit
3fdd289105
|
@ -842,8 +842,7 @@ func boolFn(ec *EvalCtx, v Value) {
|
|||
func eq(ec *EvalCtx, args []Value, opts map[string]Value) {
|
||||
TakeNoOpt(opts)
|
||||
if len(args) == 0 {
|
||||
ec.falsify()
|
||||
return
|
||||
throw(ErrArgs)
|
||||
}
|
||||
for i := 0; i+1 < len(args); i++ {
|
||||
if args[i] != args[i+1] {
|
||||
|
|
Loading…
Reference in New Issue
Block a user