Received: by mail.netbsd.org (Postfix, from userid 605) id D903A84D9E; Fri, 26 Mar 2021 17:44:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 19B7E84D8A for ; Fri, 26 Mar 2021 17:44:53 +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 2YopHwgQBgtt for ; Fri, 26 Mar 2021 17:44:52 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.netbsd.org [199.233.217.197]) by mail.netbsd.org (Postfix) with ESMTP id A71ED84D1F for ; Fri, 26 Mar 2021 17:44:52 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id A3F77FA95; Fri, 26 Mar 2021 17:44:52 +0000 (UTC) Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" MIME-Version: 1.0 Date: Fri, 26 Mar 2021 17:44:52 +0000 From: "Roland Illig" Subject: CVS commit: src/usr.bin/xlint/lint1 To: source-changes@NetBSD.org X-Mailer: log_accum Message-Id: <20210326174452.A3F77FA95@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: Fri Mar 26 17:44:52 UTC 2021 Modified Files: src/usr.bin/xlint/lint1: cgram.y decl.c externs1.h Log Message: lint: rename pushdecl and popdecl to be more expressive The previous names were highly ambiguous. The 'decl' could have meant 'declaration', which would be the usual abbreviation. It could also be split into 'dec' and 'l', meaning 'declaration level', which would make more sense in this particular context. To avoid having to guess anything about these names, rename the functions. Instead of 'push' and 'pop', I renamed them to 'begin' and 'end' since these are the high-level operation that are of interest. That the hierarchy of declaration levels is implemented as a stack is nice to know but not as important to understand the whole situation. No functional change. To generate a diff of this commit: cvs rdiff -u -r1.201 -r1.202 src/usr.bin/xlint/lint1/cgram.y cvs rdiff -u -r1.159 -r1.160 src/usr.bin/xlint/lint1/decl.c cvs rdiff -u -r1.85 -r1.86 src/usr.bin/xlint/lint1/externs1.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.