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 add gnu_printf



details:   https://anonhg.NetBSD.org/src/rev/7500f0f63c34
branches:  trunk
changeset: 449342:7500f0f63c34
user:      christos <christos%NetBSD.org@localhost>
date:      Mon Mar 04 15:26:18 2019 +0000

description:
add gnu_printf

diffstat:

 usr.bin/xlint/lint1/cgram.y |  8 +++++---
 usr.bin/xlint/lint1/scan.l  |  5 +++--
 2 files changed, 8 insertions(+), 5 deletions(-)

diffs (64 lines):

diff -r cc3dca1fd358 -r 7500f0f63c34 usr.bin/xlint/lint1/cgram.y
--- a/usr.bin/xlint/lint1/cgram.y       Mon Mar 04 14:31:26 2019 +0000
+++ b/usr.bin/xlint/lint1/cgram.y       Mon Mar 04 15:26:18 2019 +0000
@@ -1,5 +1,5 @@
 %{
-/* $NetBSD: cgram.y,v 1.101 2019/03/03 23:06:08 christos Exp $ */
+/* $NetBSD: cgram.y,v 1.102 2019/03/04 15:26:18 christos Exp $ */
 
 /*
  * Copyright (c) 1996 Christopher G. Demetriou.  All Rights Reserved.
@@ -35,7 +35,7 @@
 
 #include <sys/cdefs.h>
 #if defined(__RCSID) && !defined(lint)
-__RCSID("$NetBSD: cgram.y,v 1.101 2019/03/03 23:06:08 christos Exp $");
+__RCSID("$NetBSD: cgram.y,v 1.102 2019/03/04 15:26:18 christos Exp $");
 #endif
 
 #include <stdlib.h>
@@ -212,6 +212,7 @@
 %token <y_type>                T_AT_DESTRUCTOR
 %token <y_type>                T_AT_FORMAT
 %token <y_type>                T_AT_FORMAT_ARG
+%token <y_type>                T_AT_FORMAT_GNU_PRINTF
 %token <y_type>                T_AT_FORMAT_PRINTF
 %token <y_type>                T_AT_FORMAT_SCANF
 %token <y_type>                T_AT_FORMAT_STRFMON
@@ -515,7 +516,8 @@
        ;
 
 type_attribute_format_type:
-         T_AT_FORMAT_PRINTF
+         T_AT_FORMAT_GNU_PRINTF
+       | T_AT_FORMAT_PRINTF
        | T_AT_FORMAT_SCANF
        | T_AT_FORMAT_STRFMON
        | T_AT_FORMAT_STRFTIME
diff -r cc3dca1fd358 -r 7500f0f63c34 usr.bin/xlint/lint1/scan.l
--- a/usr.bin/xlint/lint1/scan.l        Mon Mar 04 14:31:26 2019 +0000
+++ b/usr.bin/xlint/lint1/scan.l        Mon Mar 04 15:26:18 2019 +0000
@@ -1,5 +1,5 @@
 %{
-/* $NetBSD: scan.l,v 1.87 2019/03/03 23:06:08 christos Exp $ */
+/* $NetBSD: scan.l,v 1.88 2019/03/04 15:26:18 christos Exp $ */
 
 /*
  * Copyright (c) 1996 Christopher G. Demetriou.  All Rights Reserved.
@@ -35,7 +35,7 @@
 
 #include <sys/cdefs.h>
 #if defined(__RCSID) && !defined(lint)
-__RCSID("$NetBSD: scan.l,v 1.87 2019/03/03 23:06:08 christos Exp $");
+__RCSID("$NetBSD: scan.l,v 1.88 2019/03/04 15:26:18 christos Exp $");
 #endif
 
 #include <stdlib.h>
@@ -245,6 +245,7 @@
        { "format",     T_AT_FORMAT,    0,      0,      0,        0,0,1,1,5 },
        { "format_arg", T_AT_FORMAT_ARG,0,      0,      0,        0,0,1,1,5 },
        { "gnu_inline", T_AT_GNU_INLINE,0,      0,      0,        0,0,1,1,5 },
+       { "gnu_printf", T_AT_FORMAT_GNU_PRINTF,0,0,     0,        0,0,1,1,5 },
        { "goto",       T_GOTO,         0,      0,      0,        0,0,0,0,1 },
        { "if",         T_IF,           0,      0,      0,        0,0,0,0,1 },
        { "imag",       T_IMAG,         0,      0,      0,        0,1,0,0,4 },



Home | Main Index | Thread Index | Old Index