Received: by mail.netbsd.org (Postfix, from userid 605) id 6A81F84DA2; Mon, 15 Mar 2021 12:15:05 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 9D0C384D9A for ; Mon, 15 Mar 2021 12:15:04 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([IPv6:::1]) by localhost (mail.netbsd.org [IPv6:::1]) (amavisd-new, port 10025) with ESMTP id GTspwbMfV0M1 for ; Mon, 15 Mar 2021 12:15:04 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.NetBSD.org [IPv6:2001:470:a085:999:28c:faff:fe03:5984]) by mail.netbsd.org (Postfix) with ESMTP id E2E0984D48 for ; Mon, 15 Mar 2021 12:15:03 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id D0C58FA95; Mon, 15 Mar 2021 12:15:03 +0000 (UTC) Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" MIME-Version: 1.0 Date: Mon, 15 Mar 2021 12:15:03 +0000 From: "Roland Illig" Subject: CVS commit: src/usr.bin/make To: source-changes@NetBSD.org X-Mailer: log_accum Message-Id: <20210315121503.D0C58FA95@cvs.NetBSD.org> Sender: source-changes-owner@NetBSD.org List-Id: Precedence: bulk Reply-To: source-changes-d@NetBSD.org Mail-Reply-To: "Roland Illig" Mail-Followup-To: source-changes-d@NetBSD.org List-Unsubscribe: Module Name: src Committed By: rillig Date: Mon Mar 15 12:15:03 UTC 2021 Modified Files: src/usr.bin/make: arch.c cond.c meta.c nonints.h parse.c suff.c var.c src/usr.bin/make/unit-tests: cond-func-empty.mk recursive.mk varmod-defined.mk varmod-ifelse.mk varmod-loop.mk varparse-errors.mk Log Message: make: replace enum bit-field with struct bit-field for VarEvalFlags This makes the code easier to read, especially in var.c. It also makes debugging sessions easier since some debuggers don't show enum bit-fields symbolically as soon as more than one bit is set. The code outside var.c is basically unchanged, except that instead of passing the individual flags, there are 4 predefined evaluation modes. These suffice for all practical use cases. Only in the implementation deep inside var.c, the value of the flags keepDollar and keepUndef differs. There is no way of passing the struct to EnumFlags_ToString, which means the ToString function has to be spelled out explicitly. This allows for fine-tuning the representation in the debug log, to reduce the amount of uppercae letters. No functional change. To generate a diff of this commit: cvs rdiff -u -r1.197 -r1.198 src/usr.bin/make/arch.c cvs rdiff -u -r1.258 -r1.259 src/usr.bin/make/cond.c cvs rdiff -u -r1.178 -r1.179 src/usr.bin/make/meta.c cvs rdiff -u -r1.204 -r1.205 src/usr.bin/make/nonints.h cvs rdiff -u -r1.551 -r1.552 src/usr.bin/make/parse.c cvs rdiff -u -r1.347 -r1.348 src/usr.bin/make/suff.c cvs rdiff -u -r1.884 -r1.885 src/usr.bin/make/var.c cvs rdiff -u -r1.12 -r1.13 src/usr.bin/make/unit-tests/cond-func-empty.mk cvs rdiff -u -r1.4 -r1.5 src/usr.bin/make/unit-tests/recursive.mk cvs rdiff -u -r1.9 -r1.10 src/usr.bin/make/unit-tests/varmod-defined.mk \ src/usr.bin/make/unit-tests/varmod-ifelse.mk cvs rdiff -u -r1.10 -r1.11 src/usr.bin/make/unit-tests/varmod-loop.mk cvs rdiff -u -r1.3 -r1.4 src/usr.bin/make/unit-tests/varparse-errors.mk Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.