Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/xlint/lint1 lint: inline local variable in declarato...
details: https://anonhg.NetBSD.org/src/rev/6702a253e4de
branches: trunk
changeset: 1019822:6702a253e4de
user: rillig <rillig%NetBSD.org@localhost>
date: Sun Mar 21 10:16:12 2021 +0000
description:
lint: inline local variable in declarator_1_struct_union
No functional change.
diffstat:
usr.bin/xlint/lint1/decl.c | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
diffs (37 lines):
diff -r 195411b00d07 -r 6702a253e4de usr.bin/xlint/lint1/decl.c
--- a/usr.bin/xlint/lint1/decl.c Sun Mar 21 10:08:01 2021 +0000
+++ b/usr.bin/xlint/lint1/decl.c Sun Mar 21 10:16:12 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: decl.c,v 1.152 2021/03/20 13:25:31 rillig Exp $ */
+/* $NetBSD: decl.c,v 1.153 2021/03/21 10:16:12 rillig Exp $ */
/*
* Copyright (c) 1996 Christopher G. Demetriou. All Rights Reserved.
@@ -38,7 +38,7 @@
#include <sys/cdefs.h>
#if defined(__RCSID) && !defined(lint)
-__RCSID("$NetBSD: decl.c,v 1.152 2021/03/20 13:25:31 rillig Exp $");
+__RCSID("$NetBSD: decl.c,v 1.153 2021/03/21 10:16:12 rillig Exp $");
#endif
#include <sys/param.h>
@@ -1159,13 +1159,14 @@
tspec_t t;
int sz;
int o = 0; /* Appease GCC */
- scl_t sc;
-
- lint_assert((sc = dsym->s_scl) == MOS || sc == MOU);
+
+ lint_assert(dsym->s_scl == MOS || dsym->s_scl == MOU);
if (dcs->d_rdcsym != NULL) {
/* should be ensured by storesym() */
- lint_assert((sc = dcs->d_rdcsym->s_scl) == MOS || sc == MOU);
+ lint_assert(dcs->d_rdcsym->s_scl == MOS ||
+ dcs->d_rdcsym->s_scl == MOU);
+
if (dsym->s_styp == dcs->d_rdcsym->s_styp) {
/* duplicate member name: %s */
error(33, dsym->s_name);
Home |
Main Index |
Thread Index |
Old Index