On Sat, 8 Jul 2017 15:23:39 +0100 Ciaran McCreesh <ciaran.mccre...@googlemail.com> wrote:
> On Sat, 8 Jul 2017 16:14:09 +0200 > Alexis Ballier <aball...@gentoo.org> wrote: > > On Sat, 8 Jul 2017 13:01:39 +0100 > > Ciaran McCreesh <ciaran.mccre...@googlemail.com> wrote: > > > On Sat, 8 Jul 2017 13:49:56 +0200 > > > Alexis Ballier <aball...@gentoo.org> wrote: > > > > On Sat, 8 Jul 2017 12:26:59 +0200 > > > > Ulrich Mueller <u...@gentoo.org> wrote: > > > > > | * An any-of group (||) evaluates to true if at least one of > > > > > the | items in it evaluates to true. > > > > > | * An exactly-one-of group (^^) evaluates to true if exactly > > > > > one of | the items in it evaluates to true, and all the > > > > > remaining items | evaluate to false. > > > > > | * An at-most-one-of group (??) evaluates to true if at most > > > > > one of | the items in it evaluates to true. > > > > > > > > > > It should be added that any empty group (|| or ^^ or ??) > > > > > evalutates to true, because that's what PMS specifies: > > > > > https://projects.gentoo.org/pms/6/pms.html#x1-780008.2 > > > > > > > > A bit OT, but that is *definitely* counter intuitive. What's the > > > > rationale and usecase behind this ? > > > > > > Annoying special cases like || ( foo? ( ... ) bar? ( ... ) ) . The > > > original reason was that old versions of Portage would simply > > > remove unmet "flag? ( )" blocks internally. It was kept in EAPI 0 > > > because stuff in the tree used it back then. > > > > Wasn't REQUIRED_USE something completely new with no prior usage in > > EAPI 3 ? > > Yes, but the spec defines dependency-like structures and their > meanings once and consistently, rather than all over the place and > inconsistently. > > As much as I hate the weird || ( use ? ( ) ) and empty block rules, it > would be worse to have them apply in some situations but not others. Indeed, makes sense. Would it also make sense to have some more logical meaning in a future EAPI ? I mean, in every context I've ever seen, applying a rule to the empty set is the neutral of that rule, so that it preserves associativity. That'd mean: || ( ) is false, && ( ) is true, ^^ ( ) is false, ?? ( ) is false. Alexis.