On Wed, Jul 29, 2015 at 12:08 PM, Mikolaj Izdebski <mizdebsk@xxxxxxxxxx> wrote: > On 07/28/2015 11:37 AM, Florian Festi wrote: >> >> Also we still need to settle to a final syntax for the operators [1]. >> Unfortunately there is no consensus among the other packaging formats >> what to use. Right now rpm accepts 3 different styles: >> * AND OR IF ELSE >> * & | ? : >> * && || ? : >> But the final release will only support on of them. As soon as the alpha >> stops eating babies that's a discussion we need to have. > > I think that C-style operators (&, &&) are better than verbose > COBOL-style ones because they are consistent with relation operators (>, >>= and so on) already used by rpm. Secondly, they don't introduce > conflict with existing meaning - "Requires: foo AND bar" is valid syntax > in rpm <= 4.12, equivalent to requiring three packages separately. > > From C-style operators I would prefer single-character ones for two reasons: > > 1) Two-character operators may suggest short-circuit evaluation - > "Requires: foo || bar" can be misunderstood as "require foo, or bar if > and only if foo is not available", which is not how that works. There is > no such problem with single-character operators. In other words, > "|" and "&" operators are commutative, but "||" and "&&" are not. > > 2) Debian uses single-character operators. Cross-distro consistency and > less confusion for people working on both Fedora and Debian is a plus. Well put, seconded. -- devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxxx https://admin.fedoraproject.org/mailman/listinfo/devel Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct