1 /*-------------------------------------------------------------------------
2 SDCCattr.h - Header file for attributes.
4 Copyright (c) 2021 Philipp Klaus Krause pkk@spth.de
6 This program is free software; you can redistribute it and/or modify it
7 under the terms of the GNU General Public License as published by the
8 Free Software Foundation; either version 2, or (at your option) any
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19 -------------------------------------------------------------------------*/
25 typedef struct symbol symbol
;
29 ATTRIBUTE_NODISCARD
= 1,
30 ATTRIBUTE_MAYBE_UNUSED
,
32 ATTRIBUTE_FALLTHROUGH
,
36 typedef struct attribute
38 ATTRIBUTE_TOKEN token
;
39 char token_string
[32];
40 char argument_clause
[32];
42 struct attribute
*next
; // Next attribute in attribute list.
46 attribute
*newAttribute(const symbol
*token_sym
, const char *argument_clause
);