Module Name: src Committed By: christos Date: Mon May 11 17:21:32 UTC 2015
Modified Files: src/tests/usr.bin/xlint/lint1: Makefile Added Files: src/tests/usr.bin/xlint/lint1: d_c99_compound_litteral_comma.c Log Message: add one more test To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/tests/usr.bin/xlint/lint1/Makefile cvs rdiff -u -r0 -r1.1 \ src/tests/usr.bin/xlint/lint1/d_c99_compound_litteral_comma.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/tests/usr.bin/xlint/lint1/Makefile diff -u src/tests/usr.bin/xlint/lint1/Makefile:1.6 src/tests/usr.bin/xlint/lint1/Makefile:1.7 --- src/tests/usr.bin/xlint/lint1/Makefile:1.6 Fri Apr 3 17:37:26 2015 +++ src/tests/usr.bin/xlint/lint1/Makefile Mon May 11 13:21:32 2015 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.6 2015/04/03 21:37:26 christos Exp $ +# $NetBSD: Makefile,v 1.7 2015/05/11 17:21:32 christos Exp $ NOMAN= # defined @@ -12,6 +12,7 @@ FILESDIR= ${TESTSDIR} FILES+= d_alignof.c FILES+= d_c99_complex_num.c FILES+= d_c99_complex_split.c +FILES+= d_c99_compound_literal_comma.c FILES+= d_c99_decls_after_stmt.c FILES+= d_c99_decls_after_stmt2.c FILES+= d_c99_decls_after_stmt3.c Added files: Index: src/tests/usr.bin/xlint/lint1/d_c99_compound_litteral_comma.c diff -u /dev/null src/tests/usr.bin/xlint/lint1/d_c99_compound_litteral_comma.c:1.1 --- /dev/null Mon May 11 13:21:32 2015 +++ src/tests/usr.bin/xlint/lint1/d_c99_compound_litteral_comma.c Mon May 11 13:21:32 2015 @@ -0,0 +1,14 @@ +struct bintime { + unsigned long long sec; + unsigned long long frac; +}; + +struct bintime +us2bintime(unsigned long long us) +{ + + return (struct bintime) { + .sec = us / 1000000U, + .frac = (((us % 1000000U) >> 32)/1000000U) >> 32, + }; +}