Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: can combination of zstyle -e and -a cause infinite loop?



On Mar 4,  4:45pm, Amm wrote:
}
} Will any of the two cases above cause infinite loops?
} 
} Or zsh will detect these loops?

They'll be detected.  Testing either of the mutually recurisive styles
will always "fail":

    zstyle -a sets the array to empty but returns 0
    zstyle -s sets the scalar to empty but returns 0
    zstyle -b sets the scalar to "no" and returns 1
    zstyle -m returns 1
    zstyle -t returns 1
    zstyle -T returns 0

(This might differ if the recursive call is not the only part of one
of the eval'd strings that assigns to $reply.)

All of them print to stderr:

    zsh: job table full or recursion limit exceeded



Messages sorted by: Reverse Date, Date, Thread, Author