From: cuz Date: Fri, 17 Feb 2006 20:27:51 +0000 (+0000) Subject: Added the inline keyword X-Git-Tag: V2.12.0~147 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=31d99b4a9f96da5aa9df559d88f6b1092aca75bf;p=cc65 Added the inline keyword git-svn-id: svn://svn.cc65.org/cc65/trunk@3707 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- diff --git a/src/cc65/scanner.c b/src/cc65/scanner.c index b0bb8a9bc..6516a396c 100644 --- a/src/cc65/scanner.c +++ b/src/cc65/scanner.c @@ -94,6 +94,7 @@ static const struct Keyword { { "__attribute__", TOK_ATTRIBUTE, TT_C89 | TT_C99 | TT_CC65 }, { "__far__", TOK_FAR, TT_C89 | TT_C99 | TT_CC65 }, { "__fastcall__", TOK_FASTCALL, TT_C89 | TT_C99 | TT_CC65 }, + { "__inline__", TOK_INLINE, TT_C89 | TT_C99 | TT_CC65 }, { "__near__", TOK_NEAR, TT_C89 | TT_C99 | TT_CC65 }, { "asm", TOK_ASM, TT_CC65 }, { "auto", TOK_AUTO, TT_C89 | TT_C99 | TT_CC65 }, @@ -114,6 +115,7 @@ static const struct Keyword { { "for", TOK_FOR, TT_C89 | TT_C99 | TT_CC65 }, { "goto", TOK_GOTO, TT_C89 | TT_C99 | TT_CC65 }, { "if", TOK_IF, TT_C89 | TT_C99 | TT_CC65 }, + { "inline", TOK_INLINE, TT_C99 | TT_CC65 }, { "int", TOK_INT, TT_C89 | TT_C99 | TT_CC65 }, { "long", TOK_LONG, TT_C89 | TT_C99 | TT_CC65 }, { "near", TOK_NEAR, TT_CC65 }, diff --git a/src/cc65/scanner.h b/src/cc65/scanner.h index b35c5654a..8ebc240fd 100644 --- a/src/cc65/scanner.h +++ b/src/cc65/scanner.h @@ -55,6 +55,7 @@ typedef enum token_t { TOK_INVALID, TOK_CEOF, + /* Storage specifiers */ TOK_AUTO, TOK_EXTERN, TOK_REGISTER, @@ -68,6 +69,9 @@ typedef enum token_t { TOK_RESTRICT, TOK_LAST_TYPEQUAL = TOK_RESTRICT, + /* Function specifiers */ + TOK_INLINE, + /* Tokens denoting types */ TOK_FIRST_TYPE, TOK_ENUM = TOK_FIRST_TYPE,