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: remove redundant '#' after 'argume...
details: https://anonhg.NetBSD.org/src/rev/9f485d436520
branches: trunk
changeset: 377369:9f485d436520
user: rillig <rillig%NetBSD.org@localhost>
date: Sun Jul 09 10:42:07 2023 +0000
description:
lint: remove redundant '#' after 'argument' in diagnostics
diffstat:
tests/usr.bin/xlint/lint1/d_c99_bool_strict.c | 22 ++++----
tests/usr.bin/xlint/lint1/d_c99_bool_strict_syshdr.c | 6 +-
tests/usr.bin/xlint/lint1/d_constant_conv2.c | 4 +-
tests/usr.bin/xlint/lint1/d_type_conv1.c | 4 +-
tests/usr.bin/xlint/lint1/d_type_conv2.c | 4 +-
tests/usr.bin/xlint/lint1/d_type_conv3.c | 4 +-
tests/usr.bin/xlint/lint1/msg_259.c | 50 ++++++++++----------
tests/usr.bin/xlint/lint1/msg_259_c90.c | 22 ++++----
tests/usr.bin/xlint/lint1/msg_259_ilp32.c | 4 +-
tests/usr.bin/xlint/lint1/msg_330.c | 6 +-
tests/usr.bin/xlint/lint1/msg_331.c | 6 +-
tests/usr.bin/xlint/lint1/msg_332.c | 6 +-
tests/usr.bin/xlint/lint1/msg_334.c | 8 +-
tests/usr.bin/xlint/lint1/msg_336.c | 4 +-
tests/usr.bin/xlint/lint1/msg_337.c | 4 +-
tests/usr.bin/xlint/lint1/platform_int.c | 4 +-
usr.bin/xlint/lint1/ckbool.c | 6 +-
usr.bin/xlint/lint1/err.c | 8 +-
usr.bin/xlint/lint1/tree.c | 6 +-
19 files changed, 89 insertions(+), 89 deletions(-)
diffs (truncated from 616 to 300 lines):
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/d_c99_bool_strict.c
--- a/tests/usr.bin/xlint/lint1/d_c99_bool_strict.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/d_c99_bool_strict.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: d_c99_bool_strict.c,v 1.41 2023/07/03 09:37:14 rillig Exp $ */
+/* $NetBSD: d_c99_bool_strict.c,v 1.42 2023/07/09 10:42:07 rillig Exp $ */
# 3 "d_c99_bool_strict.c"
/*
@@ -124,11 +124,11 @@ strict_bool_constant(void)
{
accept_bool(__lint_false);
accept_bool(__lint_true);
- /* expect+1: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+1: error: argument 1 expects '_Bool', gets passed 'int' [334] */
accept_bool(0);
- /* expect+1: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+1: error: argument 1 expects '_Bool', gets passed 'int' [334] */
accept_bool(1);
- /* expect+1: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+1: error: argument 1 expects '_Bool', gets passed 'int' [334] */
accept_bool(2);
}
@@ -334,17 +334,17 @@ strict_bool_conversion_function_argument
take_arguments(b, i, p);
/* Implicitly converting bool to other scalar types. */
- /* expect+2: error: argument #2 expects 'int', gets passed '_Bool' [334] */
- /* expect+1: error: argument #3 expects 'pointer', gets passed '_Bool' [334] */
+ /* expect+2: error: argument 2 expects 'int', gets passed '_Bool' [334] */
+ /* expect+1: error: argument 3 expects 'pointer', gets passed '_Bool' [334] */
take_arguments(b, b, b);
/* Implicitly converting int to bool (arg #1). */
- /* expect+2: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+2: error: argument 1 expects '_Bool', gets passed 'int' [334] */
/* expect+1: warning: illegal combination of pointer 'pointer to const char' and integer 'int', arg #3 [154] */
take_arguments(i, i, i);
/* Implicitly converting pointer to bool (arg #1). */
- /* expect+2: error: argument #1 expects '_Bool', gets passed 'pointer' [334] */
+ /* expect+2: error: argument 1 expects '_Bool', gets passed 'pointer' [334] */
/* expect+1: warning: illegal combination of integer 'int' and pointer 'pointer to const char', arg #2 [154] */
take_arguments(p, p, p);
@@ -359,11 +359,11 @@ strict_bool_conversion_function_argument
take_arguments(__lint_true, i, p);
/* Trying to pass integer constants. */
- /* expect+1: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+1: error: argument 1 expects '_Bool', gets passed 'int' [334] */
take_arguments(0, i, p);
- /* expect+1: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+1: error: argument 1 expects '_Bool', gets passed 'int' [334] */
take_arguments(1, i, p);
- /* expect+1: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+1: error: argument 1 expects '_Bool', gets passed 'int' [334] */
take_arguments(2, i, p);
}
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/d_c99_bool_strict_syshdr.c
--- a/tests/usr.bin/xlint/lint1/d_c99_bool_strict_syshdr.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/d_c99_bool_strict_syshdr.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: d_c99_bool_strict_syshdr.c,v 1.19 2023/03/28 14:44:34 rillig Exp $ */
+/* $NetBSD: d_c99_bool_strict_syshdr.c,v 1.20 2023/07/09 10:42:07 rillig Exp $ */
# 3 "d_c99_bool_strict_syshdr.c"
/*
@@ -221,7 +221,7 @@ void
pass_bool_to_function(void)
{
- /* expect+5: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+5: error: argument 1 expects '_Bool', gets passed 'int' [334] */
take_bool(
# 227 "d_c99_bool_strict_syshdr.c" 3 4
(/*CONSTCOND*/1)
@@ -234,7 +234,7 @@ pass_bool_to_function(void)
# 235 "d_c99_bool_strict_syshdr.c"
);
- /* expect+5: error: argument #1 expects '_Bool', gets passed 'int' [334] */
+ /* expect+5: error: argument 1 expects '_Bool', gets passed 'int' [334] */
take_bool(
# 240 "d_c99_bool_strict_syshdr.c" 3 4
(/*CONSTCOND*/0)
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/d_constant_conv2.c
--- a/tests/usr.bin/xlint/lint1/d_constant_conv2.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/d_constant_conv2.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: d_constant_conv2.c,v 1.6 2023/03/28 14:44:34 rillig Exp $ */
+/* $NetBSD: d_constant_conv2.c,v 1.7 2023/07/09 10:42:07 rillig Exp $ */
# 3 "d_constant_conv2.c"
/* Flag information-losing constant conversion in argument lists */
@@ -16,6 +16,6 @@ int f(unsigned int);
void
should_fail(void)
{
- /* expect+1: warning: argument #1 is converted from 'double' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'double' to 'unsigned int' due to prototype [259] */
f(2.1);
}
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/d_type_conv1.c
--- a/tests/usr.bin/xlint/lint1/d_type_conv1.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/d_type_conv1.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: d_type_conv1.c,v 1.6 2023/03/28 14:44:34 rillig Exp $ */
+/* $NetBSD: d_type_conv1.c,v 1.7 2023/07/09 10:42:07 rillig Exp $ */
# 3 "d_type_conv1.c"
/* Flag information-losing type conversion in argument lists */
@@ -18,6 +18,6 @@ should_fail(void)
{
long long x = 20;
- /* expect+1: warning: argument #1 is converted from 'long long' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long long' to 'unsigned int' due to prototype [259] */
f(x);
}
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/d_type_conv2.c
--- a/tests/usr.bin/xlint/lint1/d_type_conv2.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/d_type_conv2.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: d_type_conv2.c,v 1.6 2023/03/28 14:44:34 rillig Exp $ */
+/* $NetBSD: d_type_conv2.c,v 1.7 2023/07/09 10:42:07 rillig Exp $ */
# 3 "d_type_conv2.c"
/* Flag information-losing type conversion in argument lists */
@@ -18,6 +18,6 @@ should_fail(void)
{
double x = 2.0;
- /* expect+1: warning: argument #1 is converted from 'double' to 'float' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'double' to 'float' due to prototype [259] */
f(x);
}
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/d_type_conv3.c
--- a/tests/usr.bin/xlint/lint1/d_type_conv3.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/d_type_conv3.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: d_type_conv3.c,v 1.7 2023/03/28 14:44:34 rillig Exp $ */
+/* $NetBSD: d_type_conv3.c,v 1.8 2023/07/09 10:42:07 rillig Exp $ */
# 3 "d_type_conv3.c"
/* Flag information-losing type conversion in argument lists */
@@ -17,7 +17,7 @@ void
should_fail(void)
{
- /* expect+2: warning: argument #1 is converted from 'long long' to 'unsigned int' due to prototype [259] */
+ /* expect+2: warning: argument 1 is converted from 'long long' to 'unsigned int' due to prototype [259] */
/* expect+1: warning: conversion of 'long long' to 'unsigned int' is out of range, arg #1 [295] */
f(0x7fffffffffffffffLL);
}
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/msg_259.c
--- a/tests/usr.bin/xlint/lint1/msg_259.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/msg_259.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,7 +1,7 @@
-/* $NetBSD: msg_259.c,v 1.22 2023/03/28 14:44:35 rillig Exp $ */
+/* $NetBSD: msg_259.c,v 1.23 2023/07/09 10:42:07 rillig Exp $ */
# 3 "msg_259.c"
-// Test for message: argument #%d is converted from '%s' to '%s' due to prototype [259]
+// Test for message: argument %d is converted from '%s' to '%s' due to prototype [259]
/*
* This warning detects function calls that are translated in very different
@@ -136,13 +136,13 @@ small_integer_types(char c, signed char
void
signed_to_unsigned(int si, long sl, long long sll)
{
- /* expect+1: warning: argument #1 is converted from 'int' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'int' to 'unsigned int' due to prototype [259] */
unsigned_int(si);
- /* expect+1: warning: argument #1 is converted from 'long' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long' to 'unsigned int' due to prototype [259] */
unsigned_int(sl);
- /* expect+1: warning: argument #1 is converted from 'long long' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long long' to 'unsigned int' due to prototype [259] */
unsigned_int(sll);
/*
@@ -152,9 +152,9 @@ signed_to_unsigned(int si, long sl, long
*/
unsigned_long(si);
- /* expect+1: warning: argument #1 is converted from 'long' to 'unsigned long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long' to 'unsigned long' due to prototype [259] */
unsigned_long(sl);
- /* expect+1: warning: argument #1 is converted from 'long long' to 'unsigned long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long long' to 'unsigned long' due to prototype [259] */
unsigned_long(sll);
/*
@@ -165,31 +165,31 @@ signed_to_unsigned(int si, long sl, long
*/
unsigned_long_long(si);
- /* expect+1: warning: argument #1 is converted from 'long' to 'unsigned long long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long' to 'unsigned long long' due to prototype [259] */
unsigned_long_long(sl);
- /* expect+1: warning: argument #1 is converted from 'long long' to 'unsigned long long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long long' to 'unsigned long long' due to prototype [259] */
unsigned_long_long(sll);
}
void
unsigned_to_signed(unsigned int ui, unsigned long ul, unsigned long long ull)
{
- /* expect+1: warning: argument #1 is converted from 'unsigned int' to 'int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned int' to 'int' due to prototype [259] */
signed_int(ui);
- /* expect+1: warning: argument #1 is converted from 'unsigned long' to 'int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long' to 'int' due to prototype [259] */
signed_int(ul);
- /* expect+1: warning: argument #1 is converted from 'unsigned long long' to 'int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long long' to 'int' due to prototype [259] */
signed_int(ull);
signed_long(ui);
- /* expect+1: warning: argument #1 is converted from 'unsigned long' to 'long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long' to 'long' due to prototype [259] */
signed_long(ul);
- /* expect+1: warning: argument #1 is converted from 'unsigned long long' to 'long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long long' to 'long' due to prototype [259] */
signed_long(ull);
signed_long_long(ui);
- /* expect+1: warning: argument #1 is converted from 'unsigned long' to 'long long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long' to 'long long' due to prototype [259] */
signed_long_long(ul);
- /* expect+1: warning: argument #1 is converted from 'unsigned long long' to 'long long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long long' to 'long long' due to prototype [259] */
signed_long_long(ull);
}
@@ -197,16 +197,16 @@ void
signed_to_signed(signed int si, signed long sl, signed long long sll)
{
signed_int(si);
- /* expect+1: warning: argument #1 is converted from 'long' to 'int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long' to 'int' due to prototype [259] */
signed_int(sl);
- /* expect+1: warning: argument #1 is converted from 'long long' to 'int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long long' to 'int' due to prototype [259] */
signed_int(sll);
signed_long(si);
signed_long(sl);
- /* expect+1: warning: argument #1 is converted from 'long long' to 'long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long long' to 'long' due to prototype [259] */
signed_long(sll);
signed_long_long(si);
- /* expect+1: warning: argument #1 is converted from 'long' to 'long long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'long' to 'long long' due to prototype [259] */
signed_long_long(sl);
signed_long_long(sll);
}
@@ -215,16 +215,16 @@ void
unsigned_to_unsigned(unsigned int ui, unsigned long ul, unsigned long long ull)
{
unsigned_int(ui);
- /* expect+1: warning: argument #1 is converted from 'unsigned long' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long' to 'unsigned int' due to prototype [259] */
unsigned_int(ul);
- /* expect+1: warning: argument #1 is converted from 'unsigned long long' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long long' to 'unsigned int' due to prototype [259] */
unsigned_int(ull);
unsigned_long(ui);
unsigned_long(ul);
- /* expect+1: warning: argument #1 is converted from 'unsigned long long' to 'unsigned long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long long' to 'unsigned long' due to prototype [259] */
unsigned_long(ull);
unsigned_long_long(ui);
- /* expect+1: warning: argument #1 is converted from 'unsigned long' to 'unsigned long long' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long' to 'unsigned long long' due to prototype [259] */
unsigned_long_long(ul);
unsigned_long_long(ull);
}
@@ -244,6 +244,6 @@ pass_sizeof_as_smaller_type(void)
* constant, even though its value would fit in an unsigned int, is
* still passed as size_t.
*/
- /* expect+1: warning: argument #1 is converted from 'unsigned long' to 'unsigned int' due to prototype [259] */
+ /* expect+1: warning: argument 1 is converted from 'unsigned long' to 'unsigned int' due to prototype [259] */
unsigned_int(sizeof(int));
}
diff -r d4caa8e3a2d6 -r 9f485d436520 tests/usr.bin/xlint/lint1/msg_259_c90.c
--- a/tests/usr.bin/xlint/lint1/msg_259_c90.c Sun Jul 09 03:57:09 2023 +0000
+++ b/tests/usr.bin/xlint/lint1/msg_259_c90.c Sun Jul 09 10:42:07 2023 +0000
@@ -1,7 +1,7 @@
-/* $NetBSD: msg_259_c90.c,v 1.5 2023/03/28 14:44:35 rillig Exp $ */
+/* $NetBSD: msg_259_c90.c,v 1.6 2023/07/09 10:42:07 rillig Exp $ */
# 3 "msg_259_c90.c"
-/* Test for message: argument #%d is converted from '%s' to '%s' due to prototype [259] */
+/* Test for message: argument %d is converted from '%s' to '%s' due to prototype [259] */
Home |
Main Index |
Thread Index |
Old Index