Home | History | Annotate | Line # | Download | only in lint1
msg_086.c revision 1.6
      1 /*	$NetBSD: msg_086.c,v 1.6 2023/03/28 14:44:34 rillig Exp $	*/
      2 # 3 "msg_086.c"
      3 
      4 // Test for message: automatic '%s' hides external declaration [86]
      5 
      6 /* lint1-flags: -S -g -h -w -X 351 */
      7 
      8 extern int identifier;
      9 
     10 int
     11 local_auto(void)
     12 {
     13 	/* expect+1: warning: automatic 'identifier' hides external declaration [86] */
     14 	int identifier = 3;
     15 	return identifier;
     16 }
     17 
     18 /* XXX: the function argument does not trigger the warning. */
     19 int
     20 arg_auto(int identifier)
     21 {
     22 	return identifier;
     23 }
     24