lint: add test to demonstrate that PR bin/20264 has been fixed
This commit is contained in:
parent
d4dabb45ab
commit
3594934372
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: mi,v 1.1022 2021/02/21 21:26:26 rillig Exp $
|
||||
# $NetBSD: mi,v 1.1023 2021/02/28 20:17:13 rillig Exp $
|
||||
#
|
||||
# Note: don't delete entries from here - mark them as "obsolete" instead.
|
||||
#
|
||||
|
@ -5785,6 +5785,7 @@
|
|||
./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
|
||||
./usr/tests/usr.bin/xlint/lint1/d_c99_union_init4.c tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/xlint/lint1/d_c99_union_init5.c tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/xlint/lint1/d_c9x_array_init.c tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/xlint/lint1/d_c9x_recursive_init.c tests-usr.bin-tests compattestfile,atf
|
||||
./usr/tests/usr.bin/xlint/lint1/d_cast_fun_array_param.c tests-usr.bin-tests compattestfile,atf
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: Makefile,v 1.32 2021/02/21 08:05:51 rillig Exp $
|
||||
# $NetBSD: Makefile,v 1.33 2021/02/28 20:17:14 rillig Exp $
|
||||
|
||||
NOMAN= # defined
|
||||
|
||||
|
@ -39,6 +39,7 @@ FILES+= d_c99_union_init1.c
|
|||
FILES+= d_c99_union_init2.c
|
||||
FILES+= d_c99_union_init3.c
|
||||
FILES+= d_c99_union_init4.c
|
||||
FILES+= d_c99_union_init5.c
|
||||
FILES+= d_c9x_array_init.c
|
||||
FILES+= d_c9x_recursive_init.c
|
||||
FILES+= d_cast_fun_array_param.c
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
/* $NetBSD: d_c99_union_init5.c,v 1.1 2021/02/28 20:17:14 rillig Exp $ */
|
||||
# 3 "d_c99_union_init5.c"
|
||||
|
||||
/*
|
||||
* PR bin/20264: lint(1) has problems with named member initialization
|
||||
*
|
||||
* Has been fixed somewhere between 2005.12.24.20.47.56 and
|
||||
* 2006.12.19.19.06.44.
|
||||
*/
|
||||
|
||||
union mist {
|
||||
char *p;
|
||||
int a[1];
|
||||
};
|
||||
|
||||
union mist xx = {
|
||||
.a = { 7 }
|
||||
};
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: t_integration.sh,v 1.30 2021/02/21 08:05:51 rillig Exp $
|
||||
# $NetBSD: t_integration.sh,v 1.31 2021/02/28 20:17:14 rillig Exp $
|
||||
#
|
||||
# Copyright (c) 2008, 2010 The NetBSD Foundation, Inc.
|
||||
# All rights reserved.
|
||||
|
@ -102,6 +102,7 @@ test_case c99_init
|
|||
test_case c99_nested_struct
|
||||
test_case c99_union_cast
|
||||
test_case c99_union_init4
|
||||
test_case c99_union_init5
|
||||
test_case cast_fun_array_param
|
||||
test_case cast_typeof
|
||||
test_case decl_old_style_arguments
|
||||
|
|
Loading…
Reference in New Issue