From: Ralph Corderoy Date: Fri, 12 May 2017 22:14:43 +0000 (+0100) Subject: Replace `e ? 0 : 1' with `!e'. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/9674a6207f8a58010d560d60091a626b12ab0e3a?ds=inline Replace `e ? 0 : 1' with `!e'. Needs less thought to read. --- diff --git a/sbr/datetime.c b/sbr/datetime.c index 693c49ea..8b21e69b 100644 --- a/sbr/datetime.c +++ b/sbr/datetime.c @@ -451,7 +451,7 @@ format_datetime (tzdesc_t timezones, const contentline *node) { return NULL; } - dst = dt[1] > transition[0] ? 0 : 1; + dst = dt[1] <= transition[0]; } } diff --git a/uip/picksbr.c b/uip/picksbr.c index 02be1408..21777ed9 100644 --- a/uip/picksbr.c +++ b/uip/picksbr.c @@ -198,7 +198,7 @@ pcompile (char **vec, char *date) talked = 0; if ((head = parse ()) == NULL) - return (talked ? 0 : 1); + return !talked; if (*argp) { inform("%s unexpected", *argp); diff --git a/uip/refile.c b/uip/refile.c index 05a533e2..906eb893 100644 --- a/uip/refile.c +++ b/uip/refile.c @@ -382,7 +382,7 @@ m_file (struct msgs *mp, char *msgfile, int oldmsgnum, * therefore won't be assigned to be the current message. */ if ((msgnum = folder_addmsg (&fp->f_mp, msgfile, - mp == fp->f_mp ? 0 : 1, + mp != fp->f_mp, 0, preserve, nfolders == 1 && refile, maildir)) == -1) return 1; @@ -409,7 +409,7 @@ copy_seqs (struct msgs *oldmp, int oldmsgnum, struct msgs *newmp, int newmsgnum) assert ((int) seqnum == seq_getnum (oldmp, *seq)); if (in_sequence (oldmp, seqnum, oldmsgnum)) { seq_addmsg (newmp, *seq, newmsgnum, - is_seq_private (oldmp, seqnum) ? 0 : 1, 0); + !is_seq_private (oldmp, seqnum), 0); } } }