"find": AND/OR no longer equal precedence - Unix

This is a discussion on "find": AND/OR no longer equal precedence - Unix ; There was a time when I used HP-UX and Solaris, and the "find" command's AND (implied) and OR operators were of equal precedence. Basically, operators were evaluated from left to right. I am currently using GNU "find" version 4.3.8, and ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: "find": AND/OR no longer equal precedence

  1. "find": AND/OR no longer equal precedence

    There was a time when I used HP-UX and Solaris, and the "find"
    command's AND (implied) and OR operators were of equal precedence.
    Basically, operators were evaluated from left to right. I am
    currently using GNU "find" version 4.3.8, and the AND operator has
    greater precedence than the OR operator. When did this unequal
    precedence start to become standard (assuming that it is standard) It
    certainly is more intuitive, though we have to be careful of falling
    back on old ways, and maybe need to rework old scripts? Is it pretty
    well the way that *nix is going?

    Thanks.

    Fred

  2. Re: "find": AND/OR no longer equal precedence

    Mister.Fred.Ma wrote:

    > There was a time when I used HP-UX and Solaris, and the "find"
    > command's AND (implied) and OR operators were of equal precedence.
    > Basically, operators were evaluated from left to right. I am
    > currently using GNU "find" version 4.3.8, and the AND operator has
    > greater precedence than the OR operator. When did this unequal
    > precedence start to become standard (assuming that it is standard) It
    > certainly is more intuitive, though we have to be careful of falling
    > back on old ways, and maybe need to rework old scripts? Is it pretty
    > well the way that *nix is going?


    The precedence has been standard in POSIX since 1992 (when the first
    POSIX.2 standard was published), and before that in XPG3 (1988).
    It was almost certainly the same in XPG2, but I don't have a copy
    to hand. (The XPG3 change history says nothing about any change
    relating to precedence.)

    I would be very surprised if there has ever been a version of find
    where the precedence was different.

    --
    Geoff Clare

  3. Re: "find": AND/OR no longer equal precedence

    Geoff Clare wrote:

    > I would be very surprised if there has ever been a version of find
    > where the precedence was different.


    PS: ...especially because Version 7 already had the expected precedence.

+ Reply to Thread