Module Name: src Committed By: rillig Date: Mon Dec 28 12:47:39 UTC 2020
Modified Files: src/distrib/sets/lists/tests: mi src/tests/usr.bin/xlint/lint1: Makefile t_integration.sh Added Files: src/tests/usr.bin/xlint/lint1: d_c99_union_cast.exp d_gcc_extension.exp Log Message: lint1: add forgotten tests To generate a diff of this commit: cvs rdiff -u -r1.998 -r1.999 src/distrib/sets/lists/tests/mi cvs rdiff -u -r1.19 -r1.20 src/tests/usr.bin/xlint/lint1/Makefile cvs rdiff -u -r0 -r1.1 src/tests/usr.bin/xlint/lint1/d_c99_union_cast.exp \ src/tests/usr.bin/xlint/lint1/d_gcc_extension.exp cvs rdiff -u -r1.10 -r1.11 src/tests/usr.bin/xlint/lint1/t_integration.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/distrib/sets/lists/tests/mi diff -u src/distrib/sets/lists/tests/mi:1.998 src/distrib/sets/lists/tests/mi:1.999 --- src/distrib/sets/lists/tests/mi:1.998 Mon Dec 28 11:40:54 2020 +++ src/distrib/sets/lists/tests/mi Mon Dec 28 12:47:39 2020 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.998 2020/12/28 11:40:54 rillig Exp $ +# $NetBSD: mi,v 1.999 2020/12/28 12:47:39 rillig Exp $ # # Note: don't delete entries from here - mark them as "obsolete" instead. # @@ -5750,6 +5750,7 @@ ./usr/tests/usr.bin/xlint/lint1/d_c99_recursive_init.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_c99_struct_init.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_c99_union_cast.c tests-usr.bin-tests compattestfile,atf +./usr/tests/usr.bin/xlint/lint1/d_c99_union_cast.exp tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_c99_union_init1.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_c99_union_init2.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_c99_union_init3.c tests-usr.bin-tests compattestfile,atf @@ -5775,6 +5776,7 @@ ./usr/tests/usr.bin/xlint/lint1/d_gcc_compound_statements2.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_gcc_compound_statements3.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_gcc_extension.c tests-usr.bin-tests compattestfile,atf +./usr/tests/usr.bin/xlint/lint1/d_gcc_extension.exp tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_gcc_func.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_gcc_variable_array_init.c tests-usr.bin-tests compattestfile,atf ./usr/tests/usr.bin/xlint/lint1/d_incorrect_array_size.c tests-usr.bin-tests compattestfile,atf Index: src/tests/usr.bin/xlint/lint1/Makefile diff -u src/tests/usr.bin/xlint/lint1/Makefile:1.19 src/tests/usr.bin/xlint/lint1/Makefile:1.20 --- src/tests/usr.bin/xlint/lint1/Makefile:1.19 Mon Dec 28 11:19:01 2020 +++ src/tests/usr.bin/xlint/lint1/Makefile Mon Dec 28 12:47:39 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.19 2020/12/28 11:19:01 rillig Exp $ +# $NetBSD: Makefile,v 1.20 2020/12/28 12:47:39 rillig Exp $ NOMAN= # defined @@ -26,6 +26,7 @@ FILES+= d_c99_nested_struct.c FILES+= d_c99_recursive_init.c FILES+= d_c99_struct_init.c FILES+= d_c99_union_cast.c +FILES+= d_c99_union_cast.exp FILES+= d_c99_union_init1.c FILES+= d_c99_union_init2.c FILES+= d_c99_union_init3.c @@ -51,6 +52,7 @@ FILES+= d_gcc_compound_statements1.c FILES+= d_gcc_compound_statements2.c FILES+= d_gcc_compound_statements3.c FILES+= d_gcc_extension.c +FILES+= d_gcc_extension.exp FILES+= d_gcc_func.c FILES+= d_gcc_variable_array_init.c FILES+= d_incorrect_array_size.c Index: src/tests/usr.bin/xlint/lint1/t_integration.sh diff -u src/tests/usr.bin/xlint/lint1/t_integration.sh:1.10 src/tests/usr.bin/xlint/lint1/t_integration.sh:1.11 --- src/tests/usr.bin/xlint/lint1/t_integration.sh:1.10 Mon Dec 28 12:17:23 2020 +++ src/tests/usr.bin/xlint/lint1/t_integration.sh Mon Dec 28 12:47:39 2020 @@ -1,4 +1,4 @@ -# $NetBSD: t_integration.sh,v 1.10 2020/12/28 12:17:23 rillig Exp $ +# $NetBSD: t_integration.sh,v 1.11 2020/12/28 12:47:39 rillig Exp $ # # Copyright (c) 2008, 2010 The NetBSD Foundation, Inc. # All rights reserved. @@ -50,7 +50,9 @@ test_case() atf_test_case ${name} eval "${name}_head() { - atf_set \"descr\" \"${descr}\" + if [ \"${descr}\" ]; then + atf_set \"descr\" \"${descr}\" + fi atf_set \"require.progs\" \"${LINT1}\" }" eval "${name}_body() { @@ -60,6 +62,22 @@ test_case() Names="${Names} ${name}" } +test_case bltinoffsetof +test_case c99_anon_struct +test_case c99_anon_union +test_case c99_compound_literal_comma +test_case c99_decls_after_stmt2 +test_case c99_flex_array_packed +test_case c99_nested_struct +test_case c99_union_cast +test_case c99_union_init4 +test_case cast_fun_array_param +test_case cast_typeof +test_case gcc_extension +test_case type_question_colon +test_case typefun +test_case typename_as_var + test_case c99_struct_init "Checks C99 struct initialization" test_case c99_union_init1 "Checks C99 union initialization" test_case c99_union_init2 "Checks C99 union initialization" Added files: Index: src/tests/usr.bin/xlint/lint1/d_c99_union_cast.exp diff -u /dev/null src/tests/usr.bin/xlint/lint1/d_c99_union_cast.exp:1.1 --- /dev/null Mon Dec 28 12:47:39 2020 +++ src/tests/usr.bin/xlint/lint1/d_c99_union_cast.exp Mon Dec 28 12:47:39 2020 @@ -0,0 +1 @@ +(18): warning: a unused in function foo [192] Index: src/tests/usr.bin/xlint/lint1/d_gcc_extension.exp diff -u /dev/null src/tests/usr.bin/xlint/lint1/d_gcc_extension.exp:1.1 --- /dev/null Mon Dec 28 12:47:39 2020 +++ src/tests/usr.bin/xlint/lint1/d_gcc_extension.exp Mon Dec 28 12:47:39 2020 @@ -0,0 +1,2 @@ +(7): warning: conversion to 'long double' due to prototype, arg #1 [259] +(7): warning: conversion to 'long double' due to prototype, arg #1 [259]