Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make make(1): write s2Boolean in a more compact form
details: https://anonhg.NetBSD.org/src/rev/ca48452affec
branches: trunk
changeset: 945475:ca48452affec
user: rillig <rillig%NetBSD.org@localhost>
date: Sat Oct 31 09:23:38 2020 +0000
description:
make(1): write s2Boolean in a more compact form
diffstat:
usr.bin/make/main.c | 21 +++++----------------
1 files changed, 5 insertions(+), 16 deletions(-)
diffs (45 lines):
diff -r 91901b2d6ea3 -r ca48452affec usr.bin/make/main.c
--- a/usr.bin/make/main.c Sat Oct 31 09:20:07 2020 +0000
+++ b/usr.bin/make/main.c Sat Oct 31 09:23:38 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: main.c,v 1.414 2020/10/31 09:20:07 rillig Exp $ */
+/* $NetBSD: main.c,v 1.415 2020/10/31 09:23:38 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -118,7 +118,7 @@
#include "trace.h"
/* "@(#)main.c 8.3 (Berkeley) 3/19/94" */
-MAKE_RCSID("$NetBSD: main.c,v 1.414 2020/10/31 09:20:07 rillig Exp $");
+MAKE_RCSID("$NetBSD: main.c,v 1.415 2020/10/31 09:23:38 rillig Exp $");
#if defined(MAKE_NATIVE) && !defined(lint)
__COPYRIGHT("@(#) Copyright (c) 1988, 1989, 1990, 1993 "
"The Regents of the University of California. "
@@ -2215,23 +2215,12 @@
case 'f':
case 'N':
case 'n':
- bf = FALSE;
- break;
+ return FALSE;
case 'O':
case 'o':
- switch (s[1]) {
- case 'F':
- case 'f':
- bf = FALSE;
- break;
- default:
- bf = TRUE;
- break;
- }
- break;
+ return s[1] != 'F' && s[1] != 'f';
default:
- bf = TRUE;
- break;
+ return TRUE;
}
}
return bf;
Home |
Main Index |
Thread Index |
Old Index