diff options
author | Brad King <brad.king@kitware.com> | 2015-11-06 19:58:06 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2015-11-06 19:58:06 (GMT) |
commit | 08b8fef254f4fb705046e5c59c1b8e2f4f3afe22 (patch) | |
tree | 8fc34698511c8c401b2a5e9e35a47609799ea34b /Source | |
parent | 13dc7bdb5e3a0eaaf3607b154bba77a01404a788 (diff) | |
parent | 73f255e29d2ac9b45106e9ba7c9bb20ff2ab4349 (diff) | |
download | CMake-08b8fef254f4fb705046e5c59c1b8e2f4f3afe22.zip CMake-08b8fef254f4fb705046e5c59c1b8e2f4f3afe22.tar.gz CMake-08b8fef254f4fb705046e5c59c1b8e2f4f3afe22.tar.bz2 |
Merge topic 'fortran-line-directives'
73f255e2 cmFortranLexer: Populate empty doxygen @param comments
ba819f49 cmFortranParser: Parse #line directives
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmFortranLexer.cxx | 592 | ||||
-rw-r--r-- | Source/cmFortranLexer.h | 16 | ||||
-rw-r--r-- | Source/cmFortranLexer.in.l | 3 | ||||
-rw-r--r-- | Source/cmFortranParser.cxx | 473 | ||||
-rw-r--r-- | Source/cmFortranParser.h | 2 | ||||
-rw-r--r-- | Source/cmFortranParser.y | 10 | ||||
-rw-r--r-- | Source/cmFortranParserImpl.cxx | 26 | ||||
-rw-r--r-- | Source/cmFortranParserTokens.h | 108 |
8 files changed, 656 insertions, 574 deletions
diff --git a/Source/cmFortranLexer.cxx b/Source/cmFortranLexer.cxx index b727f0e..6779c1a 100644 --- a/Source/cmFortranLexer.cxx +++ b/Source/cmFortranLexer.cxx @@ -1,6 +1,6 @@ /*============================================================================ CMake - Cross Platform Makefile Generator - Copyright 2000-2009 Kitware, Inc., Insight Software Consortium + Copyright 2000-2015 Kitware, Inc., Insight Software Consortium Distributed under the OSI-approved BSD License (the "License"); see accompanying file Copyright.txt for details. @@ -20,7 +20,7 @@ #define FLEX_SCANNER #define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MINOR_VERSION 5 -#define YY_FLEX_SUBMINOR_VERSION 35 +#define YY_FLEX_SUBMINOR_VERSION 39 #if YY_FLEX_SUBMINOR_VERSION > 0 #define FLEX_BETA #endif @@ -190,11 +190,17 @@ typedef void* yyscan_t; typedef struct yy_buffer_state *YY_BUFFER_STATE; #endif +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + #define EOB_ACT_CONTINUE_SCAN 0 #define EOB_ACT_END_OF_FILE 1 #define EOB_ACT_LAST_MATCH 2 #define YY_LESS_LINENO(n) + #define YY_LINENO_REWIND_TO(ptr) /* Return all but the first "n" matched characters back to the input stream. */ #define yyless(n) \ @@ -212,11 +218,6 @@ typedef struct yy_buffer_state *YY_BUFFER_STATE; #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner ) -#ifndef YY_TYPEDEF_YY_SIZE_T -#define YY_TYPEDEF_YY_SIZE_T -typedef size_t yy_size_t; -#endif - #ifndef YY_STRUCT_YY_BUFFER_STATE #define YY_STRUCT_YY_BUFFER_STATE struct yy_buffer_state @@ -234,7 +235,7 @@ struct yy_buffer_state /* Number of characters read into yy_ch_buf, not including EOB * characters. */ - int yy_n_chars; + yy_size_t yy_n_chars; /* Whether we "own" the buffer - i.e., we know we created it, * and can realloc() it to grow it, and should free() it to @@ -313,7 +314,7 @@ static void cmFortran_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yys YY_BUFFER_STATE cmFortran_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner ); YY_BUFFER_STATE cmFortran_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner ); -YY_BUFFER_STATE cmFortran_yy_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner ); +YY_BUFFER_STATE cmFortran_yy_scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner ); void *cmFortran_yyalloc (yy_size_t ,yyscan_t yyscanner ); void *cmFortran_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner ); @@ -345,7 +346,7 @@ void cmFortran_yyfree (void * ,yyscan_t yyscanner ); /* Begin user sect3 */ -#define cmFortran_yywrap(n) 1 +#define cmFortran_yywrap(yyscanner) 1 #define YY_SKIP_YYWRAP typedef unsigned char YY_CHAR; @@ -369,8 +370,8 @@ static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner ); *yy_cp = '\0'; \ yyg->yy_c_buf_p = yy_cp; -#define YY_NUM_RULES 44 -#define YY_END_OF_BUFFER 45 +#define YY_NUM_RULES 45 +#define YY_END_OF_BUFFER 46 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -378,26 +379,27 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[165] = +static yyconst flex_int16_t yy_accept[173] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 45, 39, 41, 40, 43, 1, 39, 32, 2, 34, - 39, 40, 37, 39, 38, 39, 38, 41, 39, 40, - 39, 38, 9, 8, 9, 4, 3, 39, 0, 10, - 0, 0, 0, 0, 0, 32, 32, 33, 35, 37, - 39, 38, 0, 42, 38, 0, 0, 0, 0, 0, - 0, 0, 0, 39, 0, 11, 38, 0, 0, 5, - 0, 0, 0, 28, 0, 0, 32, 32, 32, 32, - 0, 0, 0, 0, 0, 22, 0, 0, 0, 0, - 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, + 46, 40, 42, 41, 44, 1, 40, 33, 2, 35, + 40, 41, 38, 40, 39, 40, 39, 42, 40, 41, + 40, 39, 9, 8, 9, 4, 3, 40, 0, 10, + 0, 0, 0, 0, 0, 33, 33, 34, 36, 38, + 40, 39, 0, 43, 39, 0, 0, 0, 12, 0, + 0, 0, 0, 0, 0, 40, 0, 11, 39, 0, + 0, 5, 0, 0, 0, 29, 0, 0, 33, 33, + 33, 33, 0, 0, 12, 12, 0, 0, 0, 23, + 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 29, 30, 0, 0, 0, 0, 0, 0, - 0, 23, 24, 0, 0, 0, 0, 0, 0, 0, - 0, 31, 26, 0, 0, 19, 0, 0, 25, 20, - 0, 0, 18, 0, 0, 17, 27, 0, 0, 16, - 21, 0, 7, 36, 7, 14, 0, 13, 15, 0, - 0, 0, 12, 0 + 0, 0, 0, 0, 0, 0, 0, 0, 30, 31, + 0, 0, 0, 0, 0, 0, 0, 24, 25, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 32, 27, + 0, 0, 20, 0, 0, 26, 21, 0, 0, 0, + 19, 0, 0, 18, 28, 0, 0, 17, 22, 0, + 7, 37, 7, 15, 0, 14, 16, 0, 0, 0, + 13, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -441,178 +443,186 @@ static yyconst flex_int32_t yy_meta[42] = 7 } ; -static yyconst flex_int16_t yy_base[174] = +static yyconst flex_int16_t yy_base[182] = { 0, - 0, 40, 0, 41, 188, 48, 44, 54, 56, 65, - 186, 0, 505, 505, 171, 505, 81, 74, 505, 505, - 158, 505, 151, 137, 0, 85, 122, 87, 153, 145, - 194, 226, 505, 143, 91, 505, 505, 0, 142, 505, - 266, 34, 70, 74, 34, 122, 141, 505, 0, 505, - 112, 0, 98, 505, 0, 154, 306, 0, 43, 133, - 139, 46, 130, 347, 130, 505, 0, 121, 163, 179, - 104, 156, 129, 176, 147, 178, 214, 267, 273, 292, - 279, 179, 249, 280, 257, 265, 288, 289, 116, 107, - 317, 505, 287, 289, 291, 302, 307, 310, 307, 311, - - 316, 326, 329, 333, 332, 336, 347, 345, 349, 101, - 86, 346, 505, 505, 350, 351, 353, 350, 357, 362, - 362, 505, 505, 367, 369, 371, 366, 372, 56, 47, - 374, 505, 505, 374, 379, 505, 374, 387, 505, 505, - 387, 391, 505, 117, 0, 505, 505, 392, 394, 505, - 505, 394, 505, 505, 505, 505, 395, 419, 505, 429, - 0, 25, 505, 505, 446, 453, 459, 462, 469, 476, - 483, 490, 497 + 0, 40, 0, 41, 220, 48, 44, 54, 56, 65, + 220, 0, 535, 535, 216, 535, 81, 74, 535, 535, + 186, 535, 153, 145, 0, 85, 122, 87, 154, 155, + 195, 227, 535, 147, 91, 535, 535, 0, 147, 535, + 267, 34, 70, 74, 34, 122, 141, 535, 0, 535, + 112, 0, 98, 535, 0, 156, 307, 0, 143, 43, + 155, 151, 48, 101, 130, 348, 130, 535, 0, 121, + 197, 165, 172, 244, 182, 183, 191, 248, 273, 293, + 308, 314, 321, 246, 275, 216, 269, 299, 304, 327, + 307, 304, 312, 116, 107, 367, 535, 327, 334, 347, + + 347, 350, 352, 349, 354, 359, 357, 363, 366, 365, + 369, 372, 369, 373, 374, 101, 86, 372, 535, 535, + 378, 380, 386, 382, 388, 388, 389, 535, 535, 393, + 394, 396, 392, 430, 400, 56, 47, 403, 535, 535, + 409, 414, 535, 409, 416, 535, 535, 416, 419, 441, + 535, 117, 0, 535, 535, 423, 426, 535, 535, 430, + 535, 535, 535, 535, 432, 457, 535, 459, 0, 25, + 535, 535, 476, 483, 489, 492, 499, 506, 513, 520, + 527 } ; -static yyconst flex_int16_t yy_def[174] = +static yyconst flex_int16_t yy_def[182] = { 0, - 164, 1, 1, 1, 1, 1, 165, 165, 165, 165, - 164, 166, 164, 164, 167, 164, 166, 164, 164, 164, - 166, 164, 164, 166, 168, 166, 168, 164, 166, 164, - 169, 164, 164, 164, 164, 164, 164, 166, 167, 164, - 164, 164, 164, 164, 164, 164, 170, 164, 166, 164, - 166, 168, 164, 164, 27, 164, 164, 57, 164, 164, - 164, 164, 164, 169, 169, 164, 32, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 170, 170, 170, 170, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 171, 172, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 173, 173, 164, 0, 164, 164, 164, 164, 164, 164, - 164, 164, 164 + 172, 1, 1, 1, 1, 1, 173, 173, 173, 173, + 172, 174, 172, 172, 175, 172, 174, 172, 172, 172, + 174, 172, 172, 174, 176, 174, 176, 172, 172, 172, + 177, 172, 172, 172, 172, 172, 172, 174, 175, 172, + 172, 172, 172, 172, 172, 172, 178, 172, 174, 172, + 174, 176, 172, 172, 27, 172, 172, 57, 174, 172, + 172, 172, 172, 172, 172, 177, 177, 172, 32, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 178, 178, + 178, 178, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 179, 180, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 181, 181, + 172, 0, 172, 172, 172, 172, 172, 172, 172, 172, + 172 } ; -static yyconst flex_int16_t yy_nxt[547] = +static yyconst flex_int16_t yy_nxt[577] = { 0, 12, 13, 14, 13, 13, 15, 16, 12, 17, 18, 19, 12, 20, 12, 21, 22, 12, 23, 12, 24, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 26, 27, 25, 25, 25, 25, 25, 25, 25, 25, - 25, 28, 28, 163, 28, 28, 34, 29, 29, 28, - 30, 145, 28, 35, 36, 29, 34, 71, 34, 31, - 144, 76, 37, 35, 36, 35, 83, 34, 71, 32, - 32, 37, 76, 88, 35, 46, 46, 83, 46, 47, - 32, 32, 41, 48, 88, 41, 53, 54, 56, 53, - 130, 56, 69, 70, 57, 69, 72, 73, 74, 53, - - 54, 75, 53, 42, 43, 129, 44, 72, 73, 74, - 45, 111, 75, 81, 42, 43, 81, 44, 154, 154, - 110, 45, 38, 46, 46, 90, 46, 47, 93, 38, - 38, 48, 66, 38, 89, 55, 38, 82, 38, 93, - 38, 38, 78, 46, 40, 78, 79, 68, 82, 63, - 80, 96, 38, 55, 58, 56, 51, 58, 56, 84, - 85, 57, 96, 86, 69, 70, 87, 69, 99, 50, - 84, 85, 49, 40, 86, 59, 60, 87, 61, 99, - 91, 94, 62, 91, 95, 164, 59, 60, 92, 61, - 30, 164, 94, 62, 64, 95, 66, 164, 97, 164, - - 100, 64, 64, 98, 164, 64, 101, 64, 64, 97, - 64, 100, 64, 64, 98, 78, 46, 101, 78, 79, - 164, 164, 164, 80, 64, 64, 65, 65, 66, 65, - 65, 65, 65, 65, 65, 65, 65, 65, 65, 67, - 65, 65, 65, 65, 65, 65, 67, 67, 67, 67, - 67, 67, 67, 67, 67, 67, 65, 67, 67, 67, - 67, 67, 67, 67, 67, 67, 67, 41, 78, 46, - 41, 78, 79, 102, 78, 46, 80, 78, 79, 105, - 81, 164, 80, 81, 102, 164, 164, 106, 42, 43, - 105, 44, 107, 78, 46, 45, 78, 79, 106, 42, - - 43, 80, 44, 107, 82, 103, 45, 58, 104, 108, - 58, 109, 112, 113, 114, 82, 103, 164, 91, 104, - 108, 91, 109, 112, 113, 114, 92, 115, 59, 60, - 116, 61, 117, 118, 119, 62, 164, 120, 115, 59, - 60, 116, 61, 117, 118, 119, 62, 64, 120, 66, - 164, 121, 164, 122, 64, 64, 123, 124, 64, 125, - 64, 64, 121, 64, 122, 64, 64, 123, 124, 126, - 125, 127, 128, 131, 132, 133, 134, 64, 64, 135, - 126, 136, 127, 128, 131, 132, 133, 134, 137, 138, - 135, 139, 136, 140, 141, 142, 143, 146, 147, 137, - - 138, 148, 139, 149, 140, 141, 142, 143, 146, 147, - 150, 151, 148, 152, 149, 156, 157, 158, 159, 164, - 160, 150, 151, 160, 152, 164, 156, 157, 158, 159, - 160, 164, 164, 160, 164, 161, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 161, 33, 33, 33, 33, - 33, 33, 33, 38, 164, 164, 164, 38, 38, 39, - 39, 39, 39, 39, 39, 39, 52, 164, 52, 65, - 65, 65, 65, 65, 65, 65, 77, 77, 77, 77, - 77, 77, 77, 153, 153, 153, 164, 153, 153, 153, - 155, 164, 155, 164, 155, 155, 155, 162, 162, 162, - - 162, 162, 164, 162, 11, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164 + 25, 28, 28, 171, 28, 28, 34, 29, 29, 28, + 30, 153, 28, 35, 36, 29, 34, 73, 34, 31, + 152, 78, 37, 35, 36, 35, 87, 34, 73, 32, + 32, 37, 78, 92, 35, 46, 46, 87, 46, 47, + 32, 32, 41, 48, 92, 41, 53, 54, 56, 53, + 137, 56, 71, 72, 57, 71, 74, 75, 76, 53, + + 54, 77, 53, 42, 43, 136, 44, 74, 75, 76, + 45, 117, 77, 83, 42, 43, 83, 44, 162, 162, + 116, 45, 38, 46, 46, 95, 46, 47, 93, 38, + 38, 48, 68, 38, 94, 55, 38, 84, 38, 93, + 38, 38, 80, 46, 86, 80, 81, 86, 84, 40, + 82, 70, 38, 55, 38, 58, 59, 56, 58, 65, + 56, 38, 38, 57, 51, 38, 96, 59, 38, 96, + 38, 50, 38, 38, 97, 90, 60, 61, 91, 62, + 63, 88, 89, 64, 38, 38, 90, 60, 61, 91, + 62, 63, 88, 89, 64, 66, 98, 68, 71, 72, + + 49, 71, 66, 66, 101, 102, 66, 98, 66, 66, + 103, 66, 104, 66, 66, 101, 102, 86, 40, 172, + 86, 103, 30, 104, 172, 66, 66, 67, 67, 68, + 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, + 69, 67, 67, 67, 67, 67, 67, 69, 69, 69, + 69, 69, 69, 69, 69, 69, 69, 67, 69, 69, + 69, 69, 69, 69, 69, 69, 69, 69, 41, 99, + 105, 41, 100, 106, 80, 46, 86, 80, 81, 86, + 99, 105, 82, 100, 106, 172, 172, 172, 85, 42, + 43, 172, 44, 107, 80, 46, 45, 80, 81, 172, + + 42, 43, 82, 44, 107, 172, 172, 45, 58, 80, + 46, 58, 80, 81, 172, 80, 46, 82, 80, 81, + 85, 172, 83, 82, 108, 83, 110, 109, 113, 60, + 61, 114, 62, 63, 115, 108, 64, 110, 109, 113, + 60, 61, 114, 62, 63, 115, 84, 64, 66, 111, + 68, 172, 118, 172, 112, 66, 66, 84, 119, 66, + 111, 66, 66, 118, 66, 112, 66, 66, 96, 119, + 120, 96, 121, 122, 123, 124, 97, 125, 66, 66, + 126, 120, 127, 121, 122, 123, 124, 128, 125, 129, + 130, 126, 131, 127, 132, 133, 134, 135, 128, 138, + + 129, 130, 139, 131, 140, 132, 133, 134, 135, 141, + 138, 142, 143, 139, 144, 140, 145, 146, 147, 148, + 141, 149, 142, 143, 151, 144, 154, 145, 146, 147, + 148, 150, 149, 155, 150, 151, 156, 154, 157, 158, + 159, 160, 150, 85, 155, 150, 164, 156, 165, 157, + 158, 159, 160, 166, 85, 167, 172, 164, 168, 165, + 168, 168, 172, 168, 166, 172, 167, 172, 172, 172, + 172, 172, 172, 169, 172, 169, 33, 33, 33, 33, + 33, 33, 33, 38, 172, 172, 172, 38, 38, 39, + 39, 39, 39, 39, 39, 39, 52, 172, 52, 67, + + 67, 67, 67, 67, 67, 67, 79, 79, 79, 79, + 79, 79, 79, 161, 161, 161, 172, 161, 161, 161, + 163, 172, 163, 172, 163, 163, 163, 170, 170, 170, + 170, 170, 172, 170, 11, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172 } ; -static yyconst flex_int16_t yy_chk[547] = +static yyconst flex_int16_t yy_chk[577] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 2, 4, 162, 2, 4, 7, 2, 4, 6, - 6, 130, 6, 7, 7, 6, 8, 42, 9, 6, - 129, 45, 9, 8, 8, 9, 59, 10, 42, 6, - 6, 10, 45, 62, 10, 18, 18, 59, 18, 18, - 6, 6, 17, 18, 62, 17, 26, 26, 28, 26, - 111, 28, 35, 35, 28, 35, 43, 43, 44, 53, - - 53, 44, 53, 17, 17, 110, 17, 43, 43, 44, - 17, 90, 44, 51, 17, 17, 51, 17, 144, 144, - 89, 17, 27, 46, 46, 68, 46, 46, 71, 27, - 27, 46, 65, 27, 63, 27, 27, 51, 27, 71, - 27, 27, 47, 47, 39, 47, 47, 34, 51, 30, - 47, 73, 27, 27, 29, 56, 24, 29, 56, 60, - 60, 56, 73, 61, 69, 69, 61, 69, 75, 23, - 60, 60, 21, 15, 61, 29, 29, 61, 29, 75, - 70, 72, 29, 70, 72, 11, 29, 29, 70, 29, - 5, 0, 72, 29, 31, 72, 31, 0, 74, 0, - - 76, 31, 31, 74, 0, 31, 82, 31, 31, 74, - 31, 76, 31, 31, 74, 77, 77, 82, 77, 77, - 0, 0, 0, 77, 31, 31, 32, 32, 32, 32, + 1, 2, 4, 170, 2, 4, 7, 2, 4, 6, + 6, 137, 6, 7, 7, 6, 8, 42, 9, 6, + 136, 45, 9, 8, 8, 9, 60, 10, 42, 6, + 6, 10, 45, 63, 10, 18, 18, 60, 18, 18, + 6, 6, 17, 18, 63, 17, 26, 26, 28, 26, + 117, 28, 35, 35, 28, 35, 43, 43, 44, 53, + + 53, 44, 53, 17, 17, 116, 17, 43, 43, 44, + 17, 95, 44, 51, 17, 17, 51, 17, 152, 152, + 94, 17, 27, 46, 46, 70, 46, 46, 64, 27, + 27, 46, 67, 27, 65, 27, 27, 51, 27, 64, + 27, 27, 47, 47, 59, 47, 47, 59, 51, 39, + 47, 34, 27, 27, 29, 29, 59, 56, 29, 30, + 56, 29, 29, 56, 24, 29, 72, 29, 29, 72, + 29, 23, 29, 29, 72, 62, 29, 29, 62, 29, + 29, 61, 61, 29, 29, 29, 62, 29, 29, 62, + 29, 29, 61, 61, 29, 31, 73, 31, 71, 71, + + 21, 71, 31, 31, 75, 76, 31, 73, 31, 31, + 76, 31, 77, 31, 31, 75, 76, 86, 15, 11, + 86, 76, 5, 77, 0, 31, 31, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 41, 78, 78, - 41, 78, 78, 83, 79, 79, 78, 79, 79, 85, - 81, 0, 79, 81, 83, 0, 0, 86, 41, 41, - 85, 41, 86, 80, 80, 41, 80, 80, 86, 41, - - 41, 80, 41, 86, 81, 84, 41, 57, 84, 87, - 57, 88, 93, 94, 95, 81, 84, 0, 91, 84, - 87, 91, 88, 93, 94, 95, 91, 96, 57, 57, - 97, 57, 98, 99, 100, 57, 0, 101, 96, 57, - 57, 97, 57, 98, 99, 100, 57, 64, 101, 64, - 0, 102, 0, 103, 64, 64, 104, 105, 64, 106, - 64, 64, 102, 64, 103, 64, 64, 104, 105, 107, - 106, 108, 109, 112, 115, 116, 117, 64, 64, 118, - 107, 119, 108, 109, 112, 115, 116, 117, 120, 121, - 118, 124, 119, 125, 126, 127, 128, 131, 134, 120, - - 121, 135, 124, 137, 125, 126, 127, 128, 131, 134, - 138, 141, 135, 142, 137, 148, 149, 152, 157, 0, - 158, 138, 141, 158, 142, 0, 148, 149, 152, 157, - 160, 0, 0, 160, 0, 158, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 160, 165, 165, 165, 165, - 165, 165, 165, 166, 0, 0, 0, 166, 166, 167, - 167, 167, 167, 167, 167, 167, 168, 0, 168, 169, - 169, 169, 169, 169, 169, 169, 170, 170, 170, 170, - 170, 170, 170, 171, 171, 171, 0, 171, 171, 171, - 172, 0, 172, 0, 172, 172, 172, 173, 173, 173, - - 173, 173, 0, 173, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 164, 164, 164, 164, 164, 164 + 32, 32, 32, 32, 32, 32, 32, 32, 41, 74, + 78, 41, 74, 84, 79, 79, 85, 79, 79, 85, + 74, 78, 79, 74, 84, 0, 0, 0, 85, 41, + 41, 0, 41, 87, 80, 80, 41, 80, 80, 0, + + 41, 41, 80, 41, 87, 0, 0, 41, 57, 81, + 81, 57, 81, 81, 0, 82, 82, 81, 82, 82, + 57, 0, 83, 82, 88, 83, 89, 88, 91, 57, + 57, 92, 57, 57, 93, 88, 57, 89, 88, 91, + 57, 57, 92, 57, 57, 93, 83, 57, 66, 90, + 66, 0, 98, 0, 90, 66, 66, 83, 99, 66, + 90, 66, 66, 98, 66, 90, 66, 66, 96, 99, + 100, 96, 101, 102, 103, 104, 96, 105, 66, 66, + 106, 100, 107, 101, 102, 103, 104, 108, 105, 109, + 110, 106, 111, 107, 112, 113, 114, 115, 108, 118, + + 109, 110, 121, 111, 122, 112, 113, 114, 115, 123, + 118, 124, 125, 121, 126, 122, 127, 130, 131, 132, + 123, 133, 124, 125, 135, 126, 138, 127, 130, 131, + 132, 134, 133, 141, 134, 135, 142, 138, 144, 145, + 148, 149, 150, 134, 141, 150, 156, 142, 157, 144, + 145, 148, 149, 160, 150, 165, 0, 156, 166, 157, + 168, 166, 0, 168, 160, 0, 165, 0, 0, 0, + 0, 0, 0, 166, 0, 168, 173, 173, 173, 173, + 173, 173, 173, 174, 0, 0, 0, 174, 174, 175, + 175, 175, 175, 175, 175, 175, 176, 0, 176, 177, + + 177, 177, 177, 177, 177, 177, 178, 178, 178, 178, + 178, 178, 178, 179, 179, 179, 0, 179, 179, 179, + 180, 0, 180, 0, 180, 180, 180, 181, 181, 181, + 181, 181, 0, 181, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, + 172, 172, 172, 172, 172, 172 } ; /* The intent behind this definition is that it'll catch @@ -655,6 +665,7 @@ Run flex like this: Modify cmFortranLexer.cxx: - remove TABs + - remove use of the 'register' storage class specifier - remove "yyscanner" argument from these methods: yy_fatal_error, cmFortran_yyalloc, cmFortran_yyrealloc, cmFortran_yyfree - remove "yyscanner = NULL" from end of cmFortran_yylex_destroy @@ -685,7 +696,7 @@ Modify cmFortranLexer.h: /*--------------------------------------------------------------------------*/ -#line 678 "cmFortranLexer.cxx" +#line 689 "cmFortranLexer.cxx" #define INITIAL 0 #define free_fmt 1 @@ -718,8 +729,8 @@ struct yyguts_t size_t yy_buffer_stack_max; /**< capacity of stack. */ YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */ char yy_hold_char; - int yy_n_chars; - int yyleng_r; + yy_size_t yy_n_chars; + yy_size_t yyleng_r; char *yy_c_buf_p; int yy_init; int yy_start; @@ -766,7 +777,7 @@ FILE *cmFortran_yyget_out (yyscan_t yyscanner ); void cmFortran_yyset_out (FILE * out_str ,yyscan_t yyscanner ); -int cmFortran_yyget_leng (yyscan_t yyscanner ); +yy_size_t cmFortran_yyget_leng (yyscan_t yyscanner ); char *cmFortran_yyget_text (yyscan_t yyscanner ); @@ -774,6 +785,10 @@ int cmFortran_yyget_lineno (yyscan_t yyscanner ); void cmFortran_yyset_lineno (int line_number ,yyscan_t yyscanner ); +int cmFortran_yyget_column (yyscan_t yyscanner ); + +void cmFortran_yyset_column (int column_no ,yyscan_t yyscanner ); + /* Macros after this point can all be overridden by user definitions in * section 1. */ @@ -918,11 +933,6 @@ YY_DECL int yy_act; struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; -#line 71 "cmFortranLexer.in.l" - - -#line 914 "cmFortranLexer.cxx" - if ( !yyg->yy_init ) { yyg->yy_init = 1; @@ -949,6 +959,12 @@ YY_DECL cmFortran_yy_load_buffer_state(yyscanner ); } + { +#line 72 "cmFortranLexer.in.l" + + +#line 956 "cmFortranLexer.cxx" + for(;;) /* loops until end-of-file is reached */ { yy_cp = yyg->yy_c_buf_p; @@ -966,7 +982,7 @@ YY_DECL yy_match: do { - YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ; if ( yy_accept[yy_current_state] ) { yyg->yy_last_accepting_state = yy_current_state; @@ -975,13 +991,13 @@ yy_match: while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 165 ) + if ( yy_current_state >= 173 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; ++yy_cp; } - while ( yy_base[yy_current_state] != 505 ); + while ( yy_base[yy_current_state] != 535 ); yy_find_action: yy_act = yy_accept[yy_current_state]; @@ -1007,7 +1023,7 @@ do_action: /* This label is used only to access EOF actions. */ case 1: YY_RULE_SETUP -#line 73 "cmFortranLexer.in.l" +#line 74 "cmFortranLexer.in.l" { cmFortranParser_StringStart(yyextra); cmFortranParser_SetOldStartcond(yyextra, YY_START); @@ -1016,7 +1032,7 @@ YY_RULE_SETUP YY_BREAK case 2: YY_RULE_SETUP -#line 79 "cmFortranLexer.in.l" +#line 80 "cmFortranLexer.in.l" { cmFortranParser_StringStart(yyextra); cmFortranParser_SetOldStartcond(yyextra, YY_START); @@ -1024,10 +1040,10 @@ YY_RULE_SETUP } YY_BREAK case 3: -#line 86 "cmFortranLexer.in.l" +#line 87 "cmFortranLexer.in.l" case 4: YY_RULE_SETUP -#line 86 "cmFortranLexer.in.l" +#line 87 "cmFortranLexer.in.l" { BEGIN(cmFortranParser_GetOldStartcond(yyextra) ); yylvalp->string = strdup(cmFortranParser_StringEnd(yyextra)); @@ -1035,17 +1051,17 @@ YY_RULE_SETUP } case 5: /* rule 5 can match eol */ -#line 93 "cmFortranLexer.in.l" +#line 94 "cmFortranLexer.in.l" case 6: /* rule 6 can match eol */ YY_RULE_SETUP -#line 93 "cmFortranLexer.in.l" +#line 94 "cmFortranLexer.in.l" /* Ignore (continued strings, free fmt) */ YY_BREAK case 7: /* rule 7 can match eol */ YY_RULE_SETUP -#line 95 "cmFortranLexer.in.l" +#line 96 "cmFortranLexer.in.l" { if (cmFortranParser_GetOldStartcond(yyextra) == fixed_fmt) ; /* Ignore (cont. strings, fixed fmt) */ @@ -1058,7 +1074,7 @@ YY_RULE_SETUP case 8: /* rule 8 can match eol */ YY_RULE_SETUP -#line 105 "cmFortranLexer.in.l" +#line 106 "cmFortranLexer.in.l" { unput ('\n'); BEGIN(INITIAL); @@ -1066,7 +1082,7 @@ YY_RULE_SETUP } case 9: YY_RULE_SETUP -#line 111 "cmFortranLexer.in.l" +#line 112 "cmFortranLexer.in.l" { cmFortranParser_StringAppend(yyextra, yytext[0]); } @@ -1074,165 +1090,169 @@ YY_RULE_SETUP case 10: /* rule 10 can match eol */ YY_RULE_SETUP -#line 115 "cmFortranLexer.in.l" +#line 116 "cmFortranLexer.in.l" { return EOSTMT; } /* Treat comments like */ case 11: /* rule 11 can match eol */ YY_RULE_SETUP -#line 116 "cmFortranLexer.in.l" +#line 117 "cmFortranLexer.in.l" { return EOSTMT; } /* empty lines */ case 12: -/* rule 12 can match eol */ YY_RULE_SETUP -#line 118 "cmFortranLexer.in.l" +#line 119 "cmFortranLexer.in.l" +{ return CPP_LINE_DIRECTIVE; } +case 13: +/* rule 13 can match eol */ +YY_RULE_SETUP +#line 120 "cmFortranLexer.in.l" { yytext[yyleng-1] = 0; yylvalp->string = strdup(strchr(yytext, '<')+1); return CPP_INCLUDE_ANGLE; } -case 13: -YY_RULE_SETUP -#line 123 "cmFortranLexer.in.l" -{ return CPP_INCLUDE; } case 14: YY_RULE_SETUP -#line 124 "cmFortranLexer.in.l" -{ return F90PPR_INCLUDE; } +#line 125 "cmFortranLexer.in.l" +{ return CPP_INCLUDE; } case 15: YY_RULE_SETUP -#line 125 "cmFortranLexer.in.l" -{ return COCO_INCLUDE; } +#line 126 "cmFortranLexer.in.l" +{ return F90PPR_INCLUDE; } case 16: YY_RULE_SETUP #line 127 "cmFortranLexer.in.l" -{ return CPP_DEFINE; } +{ return COCO_INCLUDE; } case 17: YY_RULE_SETUP -#line 128 "cmFortranLexer.in.l" -{ return F90PPR_DEFINE; } +#line 129 "cmFortranLexer.in.l" +{ return CPP_DEFINE; } case 18: YY_RULE_SETUP #line 130 "cmFortranLexer.in.l" -{ return CPP_UNDEF; } +{ return F90PPR_DEFINE; } case 19: YY_RULE_SETUP -#line 131 "cmFortranLexer.in.l" -{ return F90PPR_UNDEF; } +#line 132 "cmFortranLexer.in.l" +{ return CPP_UNDEF; } case 20: YY_RULE_SETUP #line 133 "cmFortranLexer.in.l" -{ return CPP_IFDEF; } +{ return F90PPR_UNDEF; } case 21: YY_RULE_SETUP -#line 134 "cmFortranLexer.in.l" -{ return CPP_IFNDEF; } +#line 135 "cmFortranLexer.in.l" +{ return CPP_IFDEF; } case 22: YY_RULE_SETUP -#line 135 "cmFortranLexer.in.l" -{ return CPP_IF; } +#line 136 "cmFortranLexer.in.l" +{ return CPP_IFNDEF; } case 23: YY_RULE_SETUP -#line 136 "cmFortranLexer.in.l" -{ return CPP_ELIF; } +#line 137 "cmFortranLexer.in.l" +{ return CPP_IF; } case 24: YY_RULE_SETUP -#line 137 "cmFortranLexer.in.l" -{ return CPP_ELSE; } +#line 138 "cmFortranLexer.in.l" +{ return CPP_ELIF; } case 25: YY_RULE_SETUP -#line 138 "cmFortranLexer.in.l" -{ return CPP_ENDIF; } +#line 139 "cmFortranLexer.in.l" +{ return CPP_ELSE; } case 26: YY_RULE_SETUP #line 140 "cmFortranLexer.in.l" -{ return F90PPR_IFDEF; } +{ return CPP_ENDIF; } case 27: YY_RULE_SETUP -#line 141 "cmFortranLexer.in.l" -{ return F90PPR_IFNDEF; } +#line 142 "cmFortranLexer.in.l" +{ return F90PPR_IFDEF; } case 28: YY_RULE_SETUP -#line 142 "cmFortranLexer.in.l" -{ return F90PPR_IF; } +#line 143 "cmFortranLexer.in.l" +{ return F90PPR_IFNDEF; } case 29: YY_RULE_SETUP -#line 143 "cmFortranLexer.in.l" -{ return F90PPR_ELIF; } +#line 144 "cmFortranLexer.in.l" +{ return F90PPR_IF; } case 30: YY_RULE_SETUP -#line 144 "cmFortranLexer.in.l" -{ return F90PPR_ELSE; } +#line 145 "cmFortranLexer.in.l" +{ return F90PPR_ELIF; } case 31: YY_RULE_SETUP -#line 145 "cmFortranLexer.in.l" -{ return F90PPR_ENDIF; } -/* Line continuations, possible involving comments. */ +#line 146 "cmFortranLexer.in.l" +{ return F90PPR_ELSE; } case 32: -/* rule 32 can match eol */ YY_RULE_SETUP -#line 148 "cmFortranLexer.in.l" - - YY_BREAK +#line 147 "cmFortranLexer.in.l" +{ return F90PPR_ENDIF; } +/* Line continuations, possible involving comments. */ case 33: /* rule 33 can match eol */ YY_RULE_SETUP -#line 149 "cmFortranLexer.in.l" +#line 150 "cmFortranLexer.in.l" YY_BREAK case 34: +/* rule 34 can match eol */ YY_RULE_SETUP #line 151 "cmFortranLexer.in.l" -{ return COMMA; } + + YY_BREAK case 35: YY_RULE_SETUP #line 153 "cmFortranLexer.in.l" -{ return DCOLON; } +{ return COMMA; } case 36: -/* rule 36 can match eol */ YY_RULE_SETUP #line 155 "cmFortranLexer.in.l" -{ return GARBAGE; } +{ return DCOLON; } case 37: +/* rule 37 can match eol */ YY_RULE_SETUP #line 157 "cmFortranLexer.in.l" -{ return ASSIGNMENT_OP; } +{ return GARBAGE; } case 38: YY_RULE_SETUP #line 159 "cmFortranLexer.in.l" +{ return ASSIGNMENT_OP; } +case 39: +YY_RULE_SETUP +#line 161 "cmFortranLexer.in.l" { yylvalp->string = strdup(yytext); return WORD; } -case 39: -YY_RULE_SETUP -#line 164 "cmFortranLexer.in.l" -{ return GARBAGE; } case 40: -/* rule 40 can match eol */ YY_RULE_SETUP #line 166 "cmFortranLexer.in.l" -{ return EOSTMT; } +{ return GARBAGE; } case 41: +/* rule 41 can match eol */ YY_RULE_SETUP -#line 169 "cmFortranLexer.in.l" -/* Ignore */ - YY_BREAK +#line 168 "cmFortranLexer.in.l" +{ return EOSTMT; } case 42: -/* rule 42 can match eol */ YY_RULE_SETUP -#line 170 "cmFortranLexer.in.l" -/* Ignore line-endings preceeded by \ */ +#line 171 "cmFortranLexer.in.l" +/* Ignore */ YY_BREAK case 43: +/* rule 43 can match eol */ YY_RULE_SETUP #line 172 "cmFortranLexer.in.l" +/* Ignore line-endings preceeded by \ */ + YY_BREAK +case 44: +YY_RULE_SETUP +#line 174 "cmFortranLexer.in.l" { return *yytext; } case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(free_fmt): case YY_STATE_EOF(fixed_fmt): case YY_STATE_EOF(str_sq): case YY_STATE_EOF(str_dq): -#line 174 "cmFortranLexer.in.l" +#line 176 "cmFortranLexer.in.l" { if(!cmFortranParser_FilePop(yyextra) ) { @@ -1240,12 +1260,12 @@ case YY_STATE_EOF(str_dq): } } YY_BREAK -case 44: +case 45: YY_RULE_SETUP -#line 181 "cmFortranLexer.in.l" +#line 183 "cmFortranLexer.in.l" ECHO; YY_BREAK -#line 1270 "cmFortranLexer.cxx" +#line 1291 "cmFortranLexer.cxx" case YY_END_OF_BUFFER: { @@ -1374,6 +1394,7 @@ ECHO; "fatal flex scanner internal error--no action found" ); } /* end of action switch */ } /* end of scanning one token */ + } /* end of user's declarations */ } /* end of cmFortran_yylex */ /* yy_get_next_buffer - try to read in a new buffer @@ -1430,21 +1451,21 @@ static int yy_get_next_buffer (yyscan_t yyscanner) else { - int num_to_read = + yy_size_t num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; while ( num_to_read <= 0 ) { /* Not enough room in the buffer - grow it. */ /* just a shorter name for the current buffer */ - YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE; int yy_c_buf_p_offset = (int) (yyg->yy_c_buf_p - b->yy_ch_buf); if ( b->yy_is_our_buffer ) { - int new_size = b->yy_buf_size * 2; + yy_size_t new_size = b->yy_buf_size * 2; if ( new_size <= 0 ) b->yy_buf_size += b->yy_buf_size / 8; @@ -1475,7 +1496,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) /* Read in more data. */ YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), - yyg->yy_n_chars, (size_t) num_to_read ); + yyg->yy_n_chars, num_to_read ); YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars; } @@ -1538,7 +1559,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 165 ) + if ( yy_current_state >= 173 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -1567,12 +1588,13 @@ static int yy_get_next_buffer (yyscan_t yyscanner) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 165 ) + if ( yy_current_state >= 173 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; - yy_is_jam = (yy_current_state == 164); + yy_is_jam = (yy_current_state == 172); + (void)yyg; return yy_is_jam ? 0 : yy_current_state; } @@ -1589,7 +1611,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 ) { /* need to shift things up to make room */ /* +2 for EOB chars. */ - int number_to_move = yyg->yy_n_chars + 2; + yy_size_t number_to_move = yyg->yy_n_chars + 2; char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[ YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2]; char *source = @@ -1639,7 +1661,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) else { /* need more input */ - int offset = yyg->yy_c_buf_p - yyg->yytext_ptr; + yy_size_t offset = yyg->yy_c_buf_p - yyg->yytext_ptr; ++yyg->yy_c_buf_p; switch ( yy_get_next_buffer( yyscanner ) ) @@ -1805,10 +1827,6 @@ static void cmFortran_yy_load_buffer_state (yyscan_t yyscanner) cmFortran_yyfree((void *) b ,yyscanner ); } -#ifndef __cplusplus -extern int isatty (int ); -#endif /* __cplusplus */ - /* Initializes or reinitializes a buffer. * This function is sometimes called more than once on the same buffer, * such as during a cmFortran_yyrestart() or at EOF. @@ -1925,7 +1943,7 @@ void cmFortran_yypop_buffer_state (yyscan_t yyscanner) */ static void cmFortran_yyensure_buffer_stack (yyscan_t yyscanner) { - int num_to_alloc; + yy_size_t num_to_alloc; struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; if (!yyg->yy_buffer_stack) { @@ -2023,12 +2041,12 @@ YY_BUFFER_STATE cmFortran_yy_scan_string (yyconst char * yystr , yyscan_t yyscan * @param yyscanner The scanner object. * @return the newly allocated buffer state object. */ -YY_BUFFER_STATE cmFortran_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner) +YY_BUFFER_STATE cmFortran_yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len , yyscan_t yyscanner) { YY_BUFFER_STATE b; char *buf; yy_size_t n; - int i; + yy_size_t i; /* Get memory for full buffer, including space for trailing EOB's. */ n = _yybytes_len + 2; @@ -2138,7 +2156,7 @@ FILE *cmFortran_yyget_out (yyscan_t yyscanner) /** Get the length of the current token. * @param yyscanner The scanner object. */ -int cmFortran_yyget_leng (yyscan_t yyscanner) +yy_size_t cmFortran_yyget_leng (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yyleng; @@ -2174,7 +2192,7 @@ void cmFortran_yyset_lineno (int line_number , yyscan_t yyscanner) /* lineno is only valid if an input buffer exists. */ if (! YY_CURRENT_BUFFER ) - yy_fatal_error( "cmFortran_yyset_lineno called with no buffer" , yyscanner); + YY_FATAL_ERROR( "cmFortran_yyset_lineno called with no buffer" ); yylineno = line_number; } @@ -2189,7 +2207,7 @@ void cmFortran_yyset_column (int column_no , yyscan_t yyscanner) /* column is only valid if an input buffer exists. */ if (! YY_CURRENT_BUFFER ) - yy_fatal_error( "cmFortran_yyset_column called with no buffer" , yyscanner); + YY_FATAL_ERROR( "cmFortran_yyset_column called with no buffer" ); yycolumn = column_no; } @@ -2400,7 +2418,7 @@ void cmFortran_yyfree (void * ptr , yyscan_t) #define YYTABLES_NAME "yytables" -#line 181 "cmFortranLexer.in.l" +#line 182 "cmFortranLexer.in.l" diff --git a/Source/cmFortranLexer.h b/Source/cmFortranLexer.h index c67e332..b9ff0dc 100644 --- a/Source/cmFortranLexer.h +++ b/Source/cmFortranLexer.h @@ -1,6 +1,6 @@ /*============================================================================ CMake - Cross Platform Makefile Generator - Copyright 2000-2009 Kitware, Inc., Insight Software Consortium + Copyright 2000-2015 Kitware, Inc., Insight Software Consortium Distributed under the OSI-approved BSD License (the "License"); see accompanying file Copyright.txt for details. @@ -20,7 +20,7 @@ #define FLEX_SCANNER #define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MINOR_VERSION 5 -#define YY_FLEX_SUBMINOR_VERSION 35 +#define YY_FLEX_SUBMINOR_VERSION 39 #if YY_FLEX_SUBMINOR_VERSION > 0 #define FLEX_BETA #endif @@ -177,7 +177,7 @@ struct yy_buffer_state /* Number of characters read into yy_ch_buf, not including EOB * characters. */ - int yy_n_chars; + yy_size_t yy_n_chars; /* Whether we "own" the buffer - i.e., we know we created it, * and can realloc() it to grow it, and should free() it to @@ -221,7 +221,7 @@ void cmFortran_yypop_buffer_state (yyscan_t yyscanner ); YY_BUFFER_STATE cmFortran_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner ); YY_BUFFER_STATE cmFortran_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner ); -YY_BUFFER_STATE cmFortran_yy_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner ); +YY_BUFFER_STATE cmFortran_yy_scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner ); void *cmFortran_yyalloc (yy_size_t ,yyscan_t yyscanner ); void *cmFortran_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner ); @@ -229,7 +229,7 @@ void cmFortran_yyfree (void * ,yyscan_t yyscanner ); /* Begin user sect3 */ -#define cmFortran_yywrap(n) 1 +#define cmFortran_yywrap(yyscanner) 1 #define YY_SKIP_YYWRAP #define yytext_ptr yytext_r @@ -272,7 +272,7 @@ FILE *cmFortran_yyget_out (yyscan_t yyscanner ); void cmFortran_yyset_out (FILE * out_str ,yyscan_t yyscanner ); -int cmFortran_yyget_leng (yyscan_t yyscanner ); +yy_size_t cmFortran_yyget_leng (yyscan_t yyscanner ); char *cmFortran_yyget_text (yyscan_t yyscanner ); @@ -280,6 +280,10 @@ int cmFortran_yyget_lineno (yyscan_t yyscanner ); void cmFortran_yyset_lineno (int line_number ,yyscan_t yyscanner ); +int cmFortran_yyget_column (yyscan_t yyscanner ); + +void cmFortran_yyset_column (int column_no ,yyscan_t yyscanner ); + /* Macros after this point can all be overridden by user definitions in * section 1. */ diff --git a/Source/cmFortranLexer.in.l b/Source/cmFortranLexer.in.l index 03fa90c..53984bb 100644 --- a/Source/cmFortranLexer.in.l +++ b/Source/cmFortranLexer.in.l @@ -1,7 +1,7 @@ %{ /*============================================================================ CMake - Cross Platform Makefile Generator - Copyright 2000-2009 Kitware, Inc., Insight Software Consortium + Copyright 2000-2015 Kitware, Inc., Insight Software Consortium Distributed under the OSI-approved BSD License (the "License"); see accompanying file Copyright.txt for details. @@ -116,6 +116,7 @@ Modify cmFortranLexer.h: !.*\n { return EOSTMT; } /* Treat comments like */ <fixed_fmt>^[cC*dD].*\n { return EOSTMT; } /* empty lines */ +^[ \t]*#([ \t]*line)?[ \t]*[0-9]+[ \t]* { return CPP_LINE_DIRECTIVE; } ^[ \t]*#[ \t]*include[ \t]*<[^>]+> { yytext[yyleng-1] = 0; yylvalp->string = strdup(strchr(yytext, '<')+1); diff --git a/Source/cmFortranParser.cxx b/Source/cmFortranParser.cxx index 0230f02..21a6443 100644 --- a/Source/cmFortranParser.cxx +++ b/Source/cmFortranParser.cxx @@ -72,7 +72,7 @@ /*============================================================================ CMake - Cross Platform Makefile Generator - Copyright 2000-2009 Kitware, Inc., Insight Software Consortium + Copyright 2000-2015 Kitware, Inc., Insight Software Consortium Distributed under the OSI-approved BSD License (the "License"); see accompanying file Copyright.txt for details. @@ -177,64 +177,66 @@ extern int cmFortran_yydebug; EOSTMT = 258, ASSIGNMENT_OP = 259, GARBAGE = 260, - CPP_INCLUDE = 261, - F90PPR_INCLUDE = 262, - COCO_INCLUDE = 263, - F90PPR_DEFINE = 264, - CPP_DEFINE = 265, - F90PPR_UNDEF = 266, - CPP_UNDEF = 267, - CPP_IFDEF = 268, - CPP_IFNDEF = 269, - CPP_IF = 270, - CPP_ELSE = 271, - CPP_ELIF = 272, - CPP_ENDIF = 273, - F90PPR_IFDEF = 274, - F90PPR_IFNDEF = 275, - F90PPR_IF = 276, - F90PPR_ELSE = 277, - F90PPR_ELIF = 278, - F90PPR_ENDIF = 279, - COMMA = 280, - DCOLON = 281, - CPP_TOENDL = 282, - UNTERMINATED_STRING = 283, - STRING = 284, - WORD = 285, - CPP_INCLUDE_ANGLE = 286 + CPP_LINE_DIRECTIVE = 261, + CPP_INCLUDE = 262, + F90PPR_INCLUDE = 263, + COCO_INCLUDE = 264, + F90PPR_DEFINE = 265, + CPP_DEFINE = 266, + F90PPR_UNDEF = 267, + CPP_UNDEF = 268, + CPP_IFDEF = 269, + CPP_IFNDEF = 270, + CPP_IF = 271, + CPP_ELSE = 272, + CPP_ELIF = 273, + CPP_ENDIF = 274, + F90PPR_IFDEF = 275, + F90PPR_IFNDEF = 276, + F90PPR_IF = 277, + F90PPR_ELSE = 278, + F90PPR_ELIF = 279, + F90PPR_ENDIF = 280, + COMMA = 281, + DCOLON = 282, + CPP_TOENDL = 283, + UNTERMINATED_STRING = 284, + STRING = 285, + WORD = 286, + CPP_INCLUDE_ANGLE = 287 }; #endif /* Tokens. */ #define EOSTMT 258 #define ASSIGNMENT_OP 259 #define GARBAGE 260 -#define CPP_INCLUDE 261 -#define F90PPR_INCLUDE 262 -#define COCO_INCLUDE 263 -#define F90PPR_DEFINE 264 -#define CPP_DEFINE 265 -#define F90PPR_UNDEF 266 -#define CPP_UNDEF 267 -#define CPP_IFDEF 268 -#define CPP_IFNDEF 269 -#define CPP_IF 270 -#define CPP_ELSE 271 -#define CPP_ELIF 272 -#define CPP_ENDIF 273 -#define F90PPR_IFDEF 274 -#define F90PPR_IFNDEF 275 -#define F90PPR_IF 276 -#define F90PPR_ELSE 277 -#define F90PPR_ELIF 278 -#define F90PPR_ENDIF 279 -#define COMMA 280 -#define DCOLON 281 -#define CPP_TOENDL 282 -#define UNTERMINATED_STRING 283 -#define STRING 284 -#define WORD 285 -#define CPP_INCLUDE_ANGLE 286 +#define CPP_LINE_DIRECTIVE 261 +#define CPP_INCLUDE 262 +#define F90PPR_INCLUDE 263 +#define COCO_INCLUDE 264 +#define F90PPR_DEFINE 265 +#define CPP_DEFINE 266 +#define F90PPR_UNDEF 267 +#define CPP_UNDEF 268 +#define CPP_IFDEF 269 +#define CPP_IFNDEF 270 +#define CPP_IF 271 +#define CPP_ELSE 272 +#define CPP_ELIF 273 +#define CPP_ENDIF 274 +#define F90PPR_IFDEF 275 +#define F90PPR_IFNDEF 276 +#define F90PPR_IF 277 +#define F90PPR_ELSE 278 +#define F90PPR_ELIF 279 +#define F90PPR_ENDIF 280 +#define COMMA 281 +#define DCOLON 282 +#define CPP_TOENDL 283 +#define UNTERMINATED_STRING 284 +#define STRING 285 +#define WORD 286 +#define CPP_INCLUDE_ANGLE 287 /* Value type. */ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED @@ -245,7 +247,7 @@ union YYSTYPE char* string; -#line 249 "cmFortranParser.cxx" /* yacc.c:355 */ +#line 251 "cmFortranParser.cxx" /* yacc.c:355 */ }; # define YYSTYPE_IS_TRIVIAL 1 # define YYSTYPE_IS_DECLARED 1 @@ -259,7 +261,7 @@ int cmFortran_yyparse (yyscan_t yyscanner); /* Copy the second part of user declarations. */ -#line 263 "cmFortranParser.cxx" /* yacc.c:358 */ +#line 265 "cmFortranParser.cxx" /* yacc.c:358 */ #ifdef short # undef short @@ -501,21 +503,21 @@ union yyalloc /* YYFINAL -- State number of the termination state. */ #define YYFINAL 2 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 276 +#define YYLAST 290 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 32 +#define YYNTOKENS 33 /* YYNNTS -- Number of nonterminals. */ #define YYNNTS 16 /* YYNRULES -- Number of rules. */ -#define YYNRULES 53 +#define YYNRULES 54 /* YYNSTATES -- Number of states. */ -#define YYNSTATES 97 +#define YYNSTATES 101 /* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned by yylex, with out-of-bounds checking. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 286 +#define YYMAXUTOK 287 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -552,19 +554,19 @@ static const yytype_uint8 yytranslate[] = 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31 + 25, 26, 27, 28, 29, 30, 31, 32 }; #if YYDEBUG /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 103, 103, 103, 105, 105, 107, 113, 123, 153, - 164, 177, 188, 195, 202, 208, 214, 220, 226, 231, - 236, 241, 246, 250, 251, 252, 257, 257, 257, 258, - 258, 259, 259, 260, 260, 261, 261, 262, 262, 263, - 263, 264, 264, 265, 265, 266, 266, 269, 270, 271, - 272, 273, 274, 275 + 0, 104, 104, 104, 106, 106, 108, 114, 124, 154, + 165, 178, 189, 196, 203, 210, 216, 222, 228, 234, + 239, 244, 249, 254, 258, 259, 260, 265, 265, 265, + 266, 266, 267, 267, 268, 268, 269, 269, 270, 270, + 271, 271, 272, 272, 273, 273, 274, 274, 277, 278, + 279, 280, 281, 282, 283 }; #endif @@ -574,14 +576,15 @@ static const yytype_uint16 yyrline[] = static const char *const yytname[] = { "$end", "error", "$undefined", "EOSTMT", "ASSIGNMENT_OP", "GARBAGE", - "CPP_INCLUDE", "F90PPR_INCLUDE", "COCO_INCLUDE", "F90PPR_DEFINE", - "CPP_DEFINE", "F90PPR_UNDEF", "CPP_UNDEF", "CPP_IFDEF", "CPP_IFNDEF", - "CPP_IF", "CPP_ELSE", "CPP_ELIF", "CPP_ENDIF", "F90PPR_IFDEF", - "F90PPR_IFNDEF", "F90PPR_IF", "F90PPR_ELSE", "F90PPR_ELIF", - "F90PPR_ENDIF", "COMMA", "DCOLON", "CPP_TOENDL", "UNTERMINATED_STRING", - "STRING", "WORD", "CPP_INCLUDE_ANGLE", "$accept", "code", "stmt", - "assignment_stmt", "keyword_stmt", "include", "define", "undef", "ifdef", - "ifndef", "if", "elif", "else", "endif", "other", "misc_code", YY_NULLPTR + "CPP_LINE_DIRECTIVE", "CPP_INCLUDE", "F90PPR_INCLUDE", "COCO_INCLUDE", + "F90PPR_DEFINE", "CPP_DEFINE", "F90PPR_UNDEF", "CPP_UNDEF", "CPP_IFDEF", + "CPP_IFNDEF", "CPP_IF", "CPP_ELSE", "CPP_ELIF", "CPP_ENDIF", + "F90PPR_IFDEF", "F90PPR_IFNDEF", "F90PPR_IF", "F90PPR_ELSE", + "F90PPR_ELIF", "F90PPR_ENDIF", "COMMA", "DCOLON", "CPP_TOENDL", + "UNTERMINATED_STRING", "STRING", "WORD", "CPP_INCLUDE_ANGLE", "$accept", + "code", "stmt", "assignment_stmt", "keyword_stmt", "include", "define", + "undef", "ifdef", "ifndef", "if", "elif", "else", "endif", "other", + "misc_code", YY_NULLPTR }; #endif @@ -593,14 +596,14 @@ static const yytype_uint16 yytoknum[] = 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, - 285, 286 + 285, 286, 287 }; # endif -#define YYPACT_NINF -29 +#define YYPACT_NINF -30 #define yypact_value_is_default(Yystate) \ - (!!((Yystate) == (-29))) + (!!((Yystate) == (-30))) #define YYTABLE_NINF -1 @@ -611,16 +614,17 @@ static const yytype_uint16 yytoknum[] = STATE-NUM. */ static const yytype_int16 yypact[] = { - -29, 39, -29, -29, -29, -29, -29, -29, -29, -29, - -29, -29, -29, -29, -29, -29, -29, -29, -29, -29, - -29, -29, -29, -29, -29, 246, -29, -29, -29, -29, - -28, -27, -22, -17, -16, -29, -29, -29, -29, 2, - -29, -29, -29, -13, -12, -29, -29, 61, -29, -29, - -29, -29, -29, 68, 74, 80, 108, -29, -29, -29, - -29, -29, -29, -29, -29, -29, 114, 120, -24, -29, - 126, 154, -29, 160, 166, 172, 200, 206, -29, -29, - -29, -29, -29, -29, -9, 212, -29, -29, -29, -29, - -29, -29, -29, -29, -29, 218, -29 + -30, 41, -30, -30, -30, -30, -29, -30, -30, -30, + -30, -30, -30, -30, -30, -30, -30, -30, -30, -30, + -30, -30, -30, -30, -30, -30, 259, -30, -30, -30, + -30, -28, -23, -18, -16, -13, -30, -30, -30, -30, + 2, -30, -30, -30, -30, -12, -9, -30, -30, 64, + -30, -30, -30, -30, -30, 71, 77, 83, 112, -30, + -30, -30, -30, -30, -30, -30, -30, -30, 118, 124, + 130, -24, -30, 159, 165, -30, 171, 177, 206, 212, + 218, -30, -30, -30, -30, -30, -30, -30, -1, 224, + -30, -30, -30, -30, -30, -30, -30, -30, -30, 253, + -30 }; /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. @@ -628,30 +632,31 @@ static const yytype_int16 yypact[] = means the default is an error. */ static const yytype_uint8 yydefact[] = { - 2, 0, 1, 25, 24, 45, 26, 27, 28, 30, - 29, 32, 31, 33, 35, 37, 41, 39, 43, 34, - 36, 38, 42, 40, 44, 0, 45, 3, 5, 4, - 0, 0, 0, 0, 0, 45, 45, 45, 45, 0, - 7, 45, 45, 0, 0, 45, 45, 0, 45, 45, - 45, 45, 45, 0, 0, 0, 0, 23, 50, 49, - 52, 51, 53, 48, 47, 46, 0, 0, 0, 45, - 0, 0, 12, 0, 0, 0, 0, 0, 18, 19, - 20, 21, 6, 22, 0, 0, 11, 8, 13, 14, - 15, 16, 17, 45, 9, 0, 10 + 2, 0, 1, 26, 25, 46, 0, 27, 28, 29, + 31, 30, 33, 32, 34, 36, 38, 42, 40, 44, + 35, 37, 39, 43, 41, 45, 0, 46, 3, 5, + 4, 0, 0, 0, 0, 0, 46, 46, 46, 46, + 0, 46, 7, 46, 46, 0, 0, 46, 46, 0, + 46, 46, 46, 46, 46, 0, 0, 0, 0, 24, + 51, 50, 53, 52, 54, 49, 48, 47, 0, 0, + 0, 0, 46, 0, 0, 13, 0, 0, 0, 0, + 0, 19, 20, 21, 22, 12, 6, 23, 0, 0, + 11, 8, 14, 15, 16, 17, 18, 46, 9, 0, + 10 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int8 yypgoto[] = { - -29, -29, -29, -29, -29, -29, -29, -29, -29, -29, - -29, -29, -29, -29, -26, -29 + -30, -30, -30, -30, -30, -30, -30, -30, -30, -30, + -30, -30, -30, -30, -27, -30 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int8 yydefgoto[] = { - -1, 1, 27, 28, 29, 30, 31, 32, 33, 34, - 35, 36, 37, 38, 39, 65 + -1, 1, 28, 29, 30, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, 67 }; /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If @@ -659,104 +664,109 @@ static const yytype_int8 yydefgoto[] = number is the opposite. If YYTABLE_NINF, syntax error. */ static const yytype_uint8 yytable[] = { - 47, 48, 84, 49, 0, 57, 58, 59, 50, 53, - 54, 55, 56, 51, 52, 66, 67, 68, 69, 70, - 71, 93, 73, 74, 75, 76, 77, 60, 61, 0, - 62, 63, 64, 0, 0, 0, 0, 0, 0, 2, - 3, 0, 4, 85, 5, 6, 7, 8, 9, 10, - 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - 21, 22, 23, 24, 72, 58, 59, 95, 0, 25, - 26, 78, 58, 59, 0, 0, 0, 79, 58, 59, - 0, 0, 0, 80, 58, 59, 60, 61, 0, 62, - 63, 64, 0, 60, 61, 0, 62, 63, 64, 60, - 61, 0, 62, 63, 64, 60, 61, 0, 62, 63, - 64, 81, 58, 59, 0, 0, 0, 82, 58, 59, - 0, 0, 0, 83, 58, 59, 0, 0, 0, 86, - 58, 59, 0, 60, 61, 0, 62, 63, 64, 60, - 61, 0, 62, 63, 64, 60, 61, 0, 62, 63, - 64, 60, 61, 0, 62, 63, 64, 87, 58, 59, - 0, 0, 0, 88, 58, 59, 0, 0, 0, 89, - 58, 59, 0, 0, 0, 90, 58, 59, 0, 60, - 61, 0, 62, 63, 64, 60, 61, 0, 62, 63, - 64, 60, 61, 0, 62, 63, 64, 60, 61, 0, - 62, 63, 64, 91, 58, 59, 0, 0, 0, 92, - 58, 59, 0, 0, 0, 94, 58, 59, 0, 0, - 0, 96, 58, 59, 0, 60, 61, 0, 62, 63, - 64, 60, 61, 0, 62, 63, 64, 60, 61, 0, - 62, 63, 64, 60, 61, 0, 62, 63, 64, 40, - 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 43, 44, 0, 0, 45, 46 + 49, 41, 50, 88, 0, 59, 60, 61, 51, 55, + 56, 57, 58, 52, 68, 53, 69, 70, 54, 71, + 73, 74, 72, 76, 77, 78, 79, 80, 62, 63, + 97, 64, 65, 66, 0, 0, 0, 0, 0, 0, + 0, 2, 3, 0, 4, 89, 5, 6, 7, 8, + 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, 75, 60, 61, + 99, 0, 26, 27, 81, 60, 61, 0, 0, 0, + 82, 60, 61, 0, 0, 0, 83, 60, 61, 0, + 62, 63, 0, 64, 65, 66, 0, 62, 63, 0, + 64, 65, 66, 62, 63, 0, 64, 65, 66, 62, + 63, 0, 64, 65, 66, 84, 60, 61, 0, 0, + 0, 85, 60, 61, 0, 0, 0, 86, 60, 61, + 0, 0, 0, 87, 60, 61, 0, 0, 62, 63, + 0, 64, 65, 66, 62, 63, 0, 64, 65, 66, + 62, 63, 0, 64, 65, 66, 62, 63, 0, 64, + 65, 66, 90, 60, 61, 0, 0, 0, 91, 60, + 61, 0, 0, 0, 92, 60, 61, 0, 0, 0, + 93, 60, 61, 0, 0, 62, 63, 0, 64, 65, + 66, 62, 63, 0, 64, 65, 66, 62, 63, 0, + 64, 65, 66, 62, 63, 0, 64, 65, 66, 94, + 60, 61, 0, 0, 0, 95, 60, 61, 0, 0, + 0, 96, 60, 61, 0, 0, 0, 98, 60, 61, + 0, 0, 62, 63, 0, 64, 65, 66, 62, 63, + 0, 64, 65, 66, 62, 63, 0, 64, 65, 66, + 62, 63, 0, 64, 65, 66, 100, 60, 61, 0, + 0, 0, 42, 43, 44, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 62, + 63, 0, 64, 65, 66, 45, 46, 0, 0, 47, + 48 }; static const yytype_int8 yycheck[] = { - 26, 29, 26, 30, -1, 3, 4, 5, 30, 35, - 36, 37, 38, 30, 30, 41, 42, 30, 30, 45, - 46, 30, 48, 49, 50, 51, 52, 25, 26, -1, - 28, 29, 30, -1, -1, -1, -1, -1, -1, 0, - 1, -1, 3, 69, 5, 6, 7, 8, 9, 10, - 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - 21, 22, 23, 24, 3, 4, 5, 93, -1, 30, - 31, 3, 4, 5, -1, -1, -1, 3, 4, 5, - -1, -1, -1, 3, 4, 5, 25, 26, -1, 28, - 29, 30, -1, 25, 26, -1, 28, 29, 30, 25, - 26, -1, 28, 29, 30, 25, 26, -1, 28, 29, - 30, 3, 4, 5, -1, -1, -1, 3, 4, 5, - -1, -1, -1, 3, 4, 5, -1, -1, -1, 3, - 4, 5, -1, 25, 26, -1, 28, 29, 30, 25, - 26, -1, 28, 29, 30, 25, 26, -1, 28, 29, - 30, 25, 26, -1, 28, 29, 30, 3, 4, 5, - -1, -1, -1, 3, 4, 5, -1, -1, -1, 3, - 4, 5, -1, -1, -1, 3, 4, 5, -1, 25, - 26, -1, 28, 29, 30, 25, 26, -1, 28, 29, - 30, 25, 26, -1, 28, 29, 30, 25, 26, -1, - 28, 29, 30, 3, 4, 5, -1, -1, -1, 3, + 27, 30, 30, 27, -1, 3, 4, 5, 31, 36, + 37, 38, 39, 31, 41, 31, 43, 44, 31, 31, + 47, 48, 31, 50, 51, 52, 53, 54, 26, 27, + 31, 29, 30, 31, -1, -1, -1, -1, -1, -1, + -1, 0, 1, -1, 3, 72, 5, 6, 7, 8, + 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, 3, 4, 5, + 97, -1, 31, 32, 3, 4, 5, -1, -1, -1, + 3, 4, 5, -1, -1, -1, 3, 4, 5, -1, + 26, 27, -1, 29, 30, 31, -1, 26, 27, -1, + 29, 30, 31, 26, 27, -1, 29, 30, 31, 26, + 27, -1, 29, 30, 31, 3, 4, 5, -1, -1, + -1, 3, 4, 5, -1, -1, -1, 3, 4, 5, + -1, -1, -1, 3, 4, 5, -1, -1, 26, 27, + -1, 29, 30, 31, 26, 27, -1, 29, 30, 31, + 26, 27, -1, 29, 30, 31, 26, 27, -1, 29, + 30, 31, 3, 4, 5, -1, -1, -1, 3, 4, + 5, -1, -1, -1, 3, 4, 5, -1, -1, -1, + 3, 4, 5, -1, -1, 26, 27, -1, 29, 30, + 31, 26, 27, -1, 29, 30, 31, 26, 27, -1, + 29, 30, 31, 26, 27, -1, 29, 30, 31, 3, 4, 5, -1, -1, -1, 3, 4, 5, -1, -1, - -1, 3, 4, 5, -1, 25, 26, -1, 28, 29, - 30, 25, 26, -1, 28, 29, 30, 25, 26, -1, - 28, 29, 30, 25, 26, -1, 28, 29, 30, 3, - 4, 5, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 25, 26, -1, -1, 29, 30 + -1, 3, 4, 5, -1, -1, -1, 3, 4, 5, + -1, -1, 26, 27, -1, 29, 30, 31, 26, 27, + -1, 29, 30, 31, 26, 27, -1, 29, 30, 31, + 26, 27, -1, 29, 30, 31, 3, 4, 5, -1, + -1, -1, 3, 4, 5, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 26, + 27, -1, 29, 30, 31, 26, 27, -1, -1, 30, + 31 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing symbol of state STATE-NUM. */ static const yytype_uint8 yystos[] = { - 0, 33, 0, 1, 3, 5, 6, 7, 8, 9, + 0, 34, 0, 1, 3, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - 20, 21, 22, 23, 24, 30, 31, 34, 35, 36, + 20, 21, 22, 23, 24, 25, 31, 32, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, - 3, 4, 5, 25, 26, 29, 30, 46, 29, 30, - 30, 30, 30, 46, 46, 46, 46, 3, 4, 5, - 25, 26, 28, 29, 30, 47, 46, 46, 30, 30, - 46, 46, 3, 46, 46, 46, 46, 46, 3, 3, - 3, 3, 3, 3, 26, 46, 3, 3, 3, 3, - 3, 3, 3, 30, 3, 46, 3 + 47, 30, 3, 4, 5, 26, 27, 30, 31, 47, + 30, 31, 31, 31, 31, 47, 47, 47, 47, 3, + 4, 5, 26, 27, 29, 30, 31, 48, 47, 47, + 47, 31, 31, 47, 47, 3, 47, 47, 47, 47, + 47, 3, 3, 3, 3, 3, 3, 3, 27, 47, + 3, 3, 3, 3, 3, 3, 3, 31, 3, 47, + 3 }; /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint8 yyr1[] = { - 0, 32, 33, 33, 34, 34, 35, 36, 36, 36, - 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, - 36, 36, 36, 36, 36, 36, 37, 37, 37, 38, - 38, 39, 39, 40, 40, 41, 41, 42, 42, 43, - 43, 44, 44, 45, 45, 46, 46, 47, 47, 47, - 47, 47, 47, 47 + 0, 33, 34, 34, 35, 35, 36, 37, 37, 37, + 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, + 37, 37, 37, 37, 37, 37, 37, 38, 38, 38, + 39, 39, 40, 40, 41, 41, 42, 42, 43, 43, + 44, 44, 45, 45, 46, 46, 47, 47, 48, 48, + 48, 48, 48, 48, 48 }; /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ static const yytype_uint8 yyr2[] = { 0, 2, 0, 2, 1, 1, 4, 2, 4, 5, - 7, 4, 3, 4, 4, 4, 4, 4, 3, 3, - 3, 3, 4, 3, 1, 1, 1, 1, 1, 1, + 7, 4, 4, 3, 4, 4, 4, 4, 4, 3, + 3, 3, 3, 4, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 0, 2, 1, 1, 1, - 1, 1, 1, 1 + 1, 1, 1, 1, 1, 1, 0, 2, 1, 1, + 1, 1, 1, 1, 1 }; @@ -1439,15 +1449,15 @@ yyreduce: switch (yyn) { case 6: -#line 108 "cmFortranParser.y" /* yacc.c:1646 */ +#line 109 "cmFortranParser.y" /* yacc.c:1646 */ { free((yyvsp[-3].string)); } -#line 1447 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1457 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 7: -#line 114 "cmFortranParser.y" /* yacc.c:1646 */ +#line 115 "cmFortranParser.y" /* yacc.c:1646 */ { if (cmFortranParserIsKeyword((yyvsp[-1].string), "interface")) { @@ -1457,11 +1467,11 @@ yyreduce: } free((yyvsp[-1].string)); } -#line 1461 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1471 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 8: -#line 124 "cmFortranParser.y" /* yacc.c:1646 */ +#line 125 "cmFortranParser.y" /* yacc.c:1646 */ { if (cmFortranParserIsKeyword((yyvsp[-3].string), "use")) { @@ -1491,11 +1501,11 @@ yyreduce: free((yyvsp[-3].string)); free((yyvsp[-2].string)); } -#line 1495 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1505 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 9: -#line 154 "cmFortranParser.y" /* yacc.c:1646 */ +#line 155 "cmFortranParser.y" /* yacc.c:1646 */ { if (cmFortranParserIsKeyword((yyvsp[-4].string), "use")) { @@ -1506,11 +1516,11 @@ yyreduce: free((yyvsp[-4].string)); free((yyvsp[-2].string)); } -#line 1510 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1520 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 10: -#line 165 "cmFortranParser.y" /* yacc.c:1646 */ +#line 166 "cmFortranParser.y" /* yacc.c:1646 */ { if (cmFortranParserIsKeyword((yyvsp[-6].string), "use") && cmFortranParserIsKeyword((yyvsp[-4].string), "non_intrinsic") ) @@ -1523,11 +1533,11 @@ yyreduce: free((yyvsp[-4].string)); free((yyvsp[-2].string)); } -#line 1527 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1537 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 11: -#line 178 "cmFortranParser.y" /* yacc.c:1646 */ +#line 179 "cmFortranParser.y" /* yacc.c:1646 */ { if (cmFortranParserIsKeyword((yyvsp[-3].string), "include")) { @@ -1538,129 +1548,140 @@ yyreduce: free((yyvsp[-3].string)); free((yyvsp[-2].string)); } -#line 1542 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1552 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 12: -#line 189 "cmFortranParser.y" /* yacc.c:1646 */ +#line 190 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); - cmFortranParser_RuleInclude(parser, (yyvsp[-2].string)); + cmFortranParser_RuleLineDirective(parser, (yyvsp[-2].string)); free((yyvsp[-2].string)); } -#line 1553 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1563 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 13: -#line 196 "cmFortranParser.y" /* yacc.c:1646 */ +#line 197 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleInclude(parser, (yyvsp[-2].string)); free((yyvsp[-2].string)); } -#line 1564 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1574 "cmFortranParser.cxx" /* yacc.c:1646 */ break; case 14: -#line 203 "cmFortranParser.y" /* yacc.c:1646 */ +#line 204 "cmFortranParser.y" /* yacc.c:1646 */ + { + cmFortranParser* parser = + cmFortran_yyget_extra(yyscanner); + cmFortranParser_RuleInclude(parser, (yyvsp[-2].string)); + free((yyvsp[-2].string)); + } +#line 1585 "cmFortranParser.cxx" /* yacc.c:1646 */ + break; + + case 15: +#line 211 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleDefine(parser, (yyvsp[-2].string)); free((yyvsp[-2].string)); } -#line 1574 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1595 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 15: -#line 209 "cmFortranParser.y" /* yacc.c:1646 */ + case 16: +#line 217 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleUndef(parser, (yyvsp[-2].string)); free((yyvsp[-2].string)); } -#line 1584 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1605 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 16: -#line 215 "cmFortranParser.y" /* yacc.c:1646 */ + case 17: +#line 223 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleIfdef(parser, (yyvsp[-2].string)); free((yyvsp[-2].string)); } -#line 1594 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1615 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 17: -#line 221 "cmFortranParser.y" /* yacc.c:1646 */ + case 18: +#line 229 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleIfndef(parser, (yyvsp[-2].string)); free((yyvsp[-2].string)); } -#line 1604 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1625 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 18: -#line 227 "cmFortranParser.y" /* yacc.c:1646 */ + case 19: +#line 235 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleIf(parser); } -#line 1613 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1634 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 19: -#line 232 "cmFortranParser.y" /* yacc.c:1646 */ + case 20: +#line 240 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleElif(parser); } -#line 1622 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1643 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 20: -#line 237 "cmFortranParser.y" /* yacc.c:1646 */ + case 21: +#line 245 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleElse(parser); } -#line 1631 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1652 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 21: -#line 242 "cmFortranParser.y" /* yacc.c:1646 */ + case 22: +#line 250 "cmFortranParser.y" /* yacc.c:1646 */ { cmFortranParser* parser = cmFortran_yyget_extra(yyscanner); cmFortranParser_RuleEndif(parser); } -#line 1640 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1661 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 22: -#line 247 "cmFortranParser.y" /* yacc.c:1646 */ + case 23: +#line 255 "cmFortranParser.y" /* yacc.c:1646 */ { free((yyvsp[-3].string)); } -#line 1648 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1669 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 47: -#line 269 "cmFortranParser.y" /* yacc.c:1646 */ + case 48: +#line 277 "cmFortranParser.y" /* yacc.c:1646 */ { free ((yyvsp[0].string)); } -#line 1654 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1675 "cmFortranParser.cxx" /* yacc.c:1646 */ break; - case 48: -#line 270 "cmFortranParser.y" /* yacc.c:1646 */ + case 49: +#line 278 "cmFortranParser.y" /* yacc.c:1646 */ { free ((yyvsp[0].string)); } -#line 1660 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1681 "cmFortranParser.cxx" /* yacc.c:1646 */ break; -#line 1664 "cmFortranParser.cxx" /* yacc.c:1646 */ +#line 1685 "cmFortranParser.cxx" /* yacc.c:1646 */ default: break; } /* User semantic actions sometimes alter yychar, and that requires @@ -1890,6 +1911,6 @@ yyreturn: #endif return yyresult; } -#line 278 "cmFortranParser.y" /* yacc.c:1906 */ +#line 286 "cmFortranParser.y" /* yacc.c:1906 */ /* End of grammar */ diff --git a/Source/cmFortranParser.h b/Source/cmFortranParser.h index 156c38a..cdaf46b 100644 --- a/Source/cmFortranParser.h +++ b/Source/cmFortranParser.h @@ -55,6 +55,8 @@ void cmFortranParser_Error(cmFortranParser* parser, const char* message); void cmFortranParser_RuleUse(cmFortranParser* parser, const char* name); +void cmFortranParser_RuleLineDirective(cmFortranParser* parser, + const char* filename); void cmFortranParser_RuleInclude(cmFortranParser* parser, const char* name); void cmFortranParser_RuleModule(cmFortranParser* parser, diff --git a/Source/cmFortranParser.y b/Source/cmFortranParser.y index 996bef6..83f441a 100644 --- a/Source/cmFortranParser.y +++ b/Source/cmFortranParser.y @@ -1,7 +1,7 @@ %{ /*============================================================================ CMake - Cross Platform Makefile Generator - Copyright 2000-2009 Kitware, Inc., Insight Software Consortium + Copyright 2000-2015 Kitware, Inc., Insight Software Consortium Distributed under the OSI-approved BSD License (the "License"); see accompanying file Copyright.txt for details. @@ -85,6 +85,7 @@ static bool cmFortranParserIsKeyword(const char* word, /*-------------------------------------------------------------------------*/ /* Tokens */ %token EOSTMT ASSIGNMENT_OP GARBAGE +%token CPP_LINE_DIRECTIVE %token CPP_INCLUDE F90PPR_INCLUDE COCO_INCLUDE %token F90PPR_DEFINE CPP_DEFINE F90PPR_UNDEF CPP_UNDEF %token CPP_IFDEF CPP_IFNDEF CPP_IF CPP_ELSE CPP_ELIF CPP_ENDIF @@ -185,6 +186,13 @@ keyword_stmt: free($1); free($2); } +| CPP_LINE_DIRECTIVE STRING other EOSTMT + { + cmFortranParser* parser = + cmFortran_yyget_extra(yyscanner); + cmFortranParser_RuleLineDirective(parser, $2); + free($2); + } | CPP_INCLUDE_ANGLE other EOSTMT { cmFortranParser* parser = diff --git a/Source/cmFortranParserImpl.cxx b/Source/cmFortranParserImpl.cxx index a09c5459..c175e62 100644 --- a/Source/cmFortranParserImpl.cxx +++ b/Source/cmFortranParserImpl.cxx @@ -210,6 +210,32 @@ void cmFortranParser_RuleUse(cmFortranParser* parser, } //---------------------------------------------------------------------------- +void cmFortranParser_RuleLineDirective(cmFortranParser* parser, + const char* filename) +{ + // This is a #line directive naming a file encountered during preprocessing. + std::string included = filename; + + // Skip #line directives referencing non-files like + // "<built-in>" or "<command-line>". + if (included.empty() || included[0] == '<') + { + return; + } + + // Fix windows file path separators since our lexer does not + // process escape sequences in string literals. + cmSystemTools::ReplaceString(included, "\\\\", "\\"); + cmSystemTools::ConvertToUnixSlashes(included); + + // Save the named file as included in the source. + if (cmSystemTools::FileExists(included)) + { + parser->Info.Includes.insert(included); + } +} + +//---------------------------------------------------------------------------- void cmFortranParser_RuleInclude(cmFortranParser* parser, const char* name) { diff --git a/Source/cmFortranParserTokens.h b/Source/cmFortranParserTokens.h index df1aec3..ac49840 100644 --- a/Source/cmFortranParserTokens.h +++ b/Source/cmFortranParserTokens.h @@ -48,64 +48,66 @@ extern int cmFortran_yydebug; EOSTMT = 258, ASSIGNMENT_OP = 259, GARBAGE = 260, - CPP_INCLUDE = 261, - F90PPR_INCLUDE = 262, - COCO_INCLUDE = 263, - F90PPR_DEFINE = 264, - CPP_DEFINE = 265, - F90PPR_UNDEF = 266, - CPP_UNDEF = 267, - CPP_IFDEF = 268, - CPP_IFNDEF = 269, - CPP_IF = 270, - CPP_ELSE = 271, - CPP_ELIF = 272, - CPP_ENDIF = 273, - F90PPR_IFDEF = 274, - F90PPR_IFNDEF = 275, - F90PPR_IF = 276, - F90PPR_ELSE = 277, - F90PPR_ELIF = 278, - F90PPR_ENDIF = 279, - COMMA = 280, - DCOLON = 281, - CPP_TOENDL = 282, - UNTERMINATED_STRING = 283, - STRING = 284, - WORD = 285, - CPP_INCLUDE_ANGLE = 286 + CPP_LINE_DIRECTIVE = 261, + CPP_INCLUDE = 262, + F90PPR_INCLUDE = 263, + COCO_INCLUDE = 264, + F90PPR_DEFINE = 265, + CPP_DEFINE = 266, + F90PPR_UNDEF = 267, + CPP_UNDEF = 268, + CPP_IFDEF = 269, + CPP_IFNDEF = 270, + CPP_IF = 271, + CPP_ELSE = 272, + CPP_ELIF = 273, + CPP_ENDIF = 274, + F90PPR_IFDEF = 275, + F90PPR_IFNDEF = 276, + F90PPR_IF = 277, + F90PPR_ELSE = 278, + F90PPR_ELIF = 279, + F90PPR_ENDIF = 280, + COMMA = 281, + DCOLON = 282, + CPP_TOENDL = 283, + UNTERMINATED_STRING = 284, + STRING = 285, + WORD = 286, + CPP_INCLUDE_ANGLE = 287 }; #endif /* Tokens. */ #define EOSTMT 258 #define ASSIGNMENT_OP 259 #define GARBAGE 260 -#define CPP_INCLUDE 261 -#define F90PPR_INCLUDE 262 -#define COCO_INCLUDE 263 -#define F90PPR_DEFINE 264 -#define CPP_DEFINE 265 -#define F90PPR_UNDEF 266 -#define CPP_UNDEF 267 -#define CPP_IFDEF 268 -#define CPP_IFNDEF 269 -#define CPP_IF 270 -#define CPP_ELSE 271 -#define CPP_ELIF 272 -#define CPP_ENDIF 273 -#define F90PPR_IFDEF 274 -#define F90PPR_IFNDEF 275 -#define F90PPR_IF 276 -#define F90PPR_ELSE 277 -#define F90PPR_ELIF 278 -#define F90PPR_ENDIF 279 -#define COMMA 280 -#define DCOLON 281 -#define CPP_TOENDL 282 -#define UNTERMINATED_STRING 283 -#define STRING 284 -#define WORD 285 -#define CPP_INCLUDE_ANGLE 286 +#define CPP_LINE_DIRECTIVE 261 +#define CPP_INCLUDE 262 +#define F90PPR_INCLUDE 263 +#define COCO_INCLUDE 264 +#define F90PPR_DEFINE 265 +#define CPP_DEFINE 266 +#define F90PPR_UNDEF 267 +#define CPP_UNDEF 268 +#define CPP_IFDEF 269 +#define CPP_IFNDEF 270 +#define CPP_IF 271 +#define CPP_ELSE 272 +#define CPP_ELIF 273 +#define CPP_ENDIF 274 +#define F90PPR_IFDEF 275 +#define F90PPR_IFNDEF 276 +#define F90PPR_IF 277 +#define F90PPR_ELSE 278 +#define F90PPR_ELIF 279 +#define F90PPR_ENDIF 280 +#define COMMA 281 +#define DCOLON 282 +#define CPP_TOENDL 283 +#define UNTERMINATED_STRING 284 +#define STRING 285 +#define WORD 286 +#define CPP_INCLUDE_ANGLE 287 /* Value type. */ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED @@ -116,7 +118,7 @@ union YYSTYPE char* string; -#line 120 "cmFortranParserTokens.h" /* yacc.c:1909 */ +#line 122 "cmFortranParserTokens.h" /* yacc.c:1909 */ }; # define YYSTYPE_IS_TRIVIAL 1 # define YYSTYPE_IS_DECLARED 1 |