handle "extern __attribute__((__gnu_inline__)) __inline"
This commit is contained in:
parent
986517611c
commit
29a071ed18
|
@ -1,5 +1,5 @@
|
|||
%{
|
||||
/* $NetBSD: cgram.y,v 1.76 2016/02/27 21:37:14 christos Exp $ */
|
||||
/* $NetBSD: cgram.y,v 1.77 2016/07/20 17:42:14 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.76 2016/02/27 21:37:14 christos Exp $");
|
||||
__RCSID("$NetBSD: cgram.y,v 1.77 2016/07/20 17:42:14 christos Exp $");
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
|
@ -117,7 +117,7 @@ anonymize(sym_t *s)
|
|||
}
|
||||
%}
|
||||
|
||||
%expect 80
|
||||
%expect 88
|
||||
|
||||
%union {
|
||||
int y_int;
|
||||
|
@ -200,6 +200,7 @@ anonymize(sym_t *s)
|
|||
%token <y_type> T_AT_ALIGNED
|
||||
%token <y_type> T_AT_DEPRECATED
|
||||
%token <y_type> T_AT_NORETURN
|
||||
%token <y_type> T_AT_GNU_INLINE
|
||||
%token <y_type> T_AT_MAY_ALIAS
|
||||
%token <y_type> T_AT_PACKED
|
||||
%token <y_type> T_AT_PURE
|
||||
|
@ -510,6 +511,7 @@ type_attribute_spec:
|
|||
}
|
||||
| T_AT_PURE
|
||||
| T_AT_TUNION
|
||||
| T_AT_GNU_INLINE
|
||||
| T_AT_FORMAT T_LPARN type_attribute_format_type T_COMMA
|
||||
constant T_COMMA constant T_RPARN
|
||||
| T_AT_UNUSED
|
||||
|
@ -552,7 +554,6 @@ declspecs:
|
|||
addtype($2);
|
||||
}
|
||||
| type_attribute declspecs
|
||||
| declspecs type_attribute
|
||||
| declspecs declmod
|
||||
| declspecs notype_typespec {
|
||||
addtype($2);
|
||||
|
@ -576,6 +577,7 @@ declmod:
|
|||
| T_SCLASS {
|
||||
addscl($1);
|
||||
}
|
||||
| type_attribute
|
||||
;
|
||||
|
||||
clrtyp_typespec:
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
%{
|
||||
/* $NetBSD: scan.l,v 1.65 2016/02/27 21:37:14 christos Exp $ */
|
||||
/* $NetBSD: scan.l,v 1.66 2016/07/20 17:42:14 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.65 2016/02/27 21:37:14 christos Exp $");
|
||||
__RCSID("$NetBSD: scan.l,v 1.66 2016/07/20 17:42:14 christos Exp $");
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
|
@ -215,6 +215,8 @@ static struct kwtab {
|
|||
{ "transparent_union",T_AT_TUNION,0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "__unused__", T_AT_UNUSED, 0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "unused", T_AT_UNUSED, 0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "__gnu_inline__",T_AT_GNU_INLINE,0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "gnu_inline", T_AT_GNU_INLINE,0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "__deprecated__",T_AT_DEPRECATED,0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "deprecated", T_AT_DEPRECATED,0, 0, 0, 0, 0, 1, 1 },
|
||||
{ "__may_alias__",T_AT_MAY_ALIAS,0, 0, 0, 0, 0, 1, 1 },
|
||||
|
|
Loading…
Reference in New Issue