Merge topic 'fortran-submodules'

df4aeb31 Help: Add notes for topic 'fortran-submodules'
b5ac8b8a Fortran: Add support for submodule syntax in dependency scanning
bdcc1f51 cmFortranParser: Skip module procedures/functions/subroutines
This commit is contained in:
Brad King 2016-09-21 08:47:45 -04:00 committed by CMake Topic Stage
commit 1657fa0795
7 changed files with 659 additions and 522 deletions

View File

@ -0,0 +1,7 @@
fortran-submodules
------------------
* The Fortran dependency scanner learned to support the syntax of
`Fortran Submodules`_.
.. _`Fortran Submodules`: http://fortranwiki.org/fortran/show/Submodules

View File

@ -347,8 +347,8 @@ static void yynoreturn yy_fatal_error (yyconst char* msg ,yyscan_t yyscanner );
*yy_cp = '\0'; \
yyg->yy_c_buf_p = yy_cp;
#define YY_NUM_RULES 50
#define YY_END_OF_BUFFER 51
#define YY_NUM_RULES 54
#define YY_END_OF_BUFFER 55
/* This struct is not used in this scanner,
but its presence is necessary. */
struct yy_trans_info
@ -356,30 +356,31 @@ struct yy_trans_info
flex_int32_t yy_verify;
flex_int32_t yy_nxt;
};
static yyconst flex_int16_t yy_accept[199] =
static yyconst flex_int16_t yy_accept[210] =
{ 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
51, 45, 47, 46, 49, 1, 45, 33, 2, 35,
45, 46, 38, 45, 44, 44, 44, 44, 44, 45,
44, 47, 45, 46, 45, 44, 9, 8, 9, 4,
3, 45, 0, 10, 0, 0, 0, 0, 0, 33,
33, 34, 36, 38, 45, 44, 44, 44, 44, 44,
0, 48, 44, 0, 0, 0, 12, 0, 0, 0,
0, 0, 0, 45, 0, 11, 44, 0, 0, 5,
0, 0, 0, 29, 0, 0, 33, 33, 33, 33,
0, 0, 39, 44, 44, 44, 43, 12, 12, 0,
55, 49, 51, 50, 53, 1, 49, 33, 2, 47,
48, 35, 37, 50, 39, 49, 46, 46, 46, 46,
46, 46, 49, 46, 51, 49, 50, 49, 46, 9,
8, 9, 4, 3, 49, 0, 10, 0, 0, 0,
0, 0, 33, 33, 34, 36, 39, 49, 46, 46,
46, 46, 46, 46, 0, 52, 46, 0, 0, 0,
12, 0, 0, 0, 0, 0, 0, 49, 0, 11,
46, 0, 0, 5, 0, 0, 0, 29, 0, 0,
33, 33, 33, 33, 0, 0, 40, 46, 46, 46,
0, 0, 23, 0, 0, 0, 0, 0, 0, 6,
0, 0, 0, 0, 0, 0, 0, 0, 0, 44,
44, 44, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 30, 31, 0, 0, 0, 0,
0, 0, 44, 44, 44, 0, 24, 25, 0, 0,
0, 0, 0, 0, 0, 0, 0, 32, 27, 0,
0, 20, 0, 44, 44, 42, 0, 26, 21, 0,
0, 0, 19, 0, 0, 18, 28, 0, 0, 40,
44, 17, 22, 0, 7, 37, 7, 15, 0, 44,
14, 16, 41, 0, 0, 0, 13, 0
46, 45, 12, 12, 0, 0, 0, 23, 0, 0,
0, 0, 0, 0, 6, 0, 0, 0, 0, 0,
0, 0, 0, 0, 46, 46, 46, 46, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
30, 31, 0, 0, 0, 0, 0, 0, 46, 46,
46, 46, 0, 24, 25, 0, 0, 0, 0, 0,
0, 0, 0, 0, 32, 27, 0, 0, 20, 0,
46, 46, 43, 46, 0, 26, 21, 0, 0, 0,
19, 0, 0, 18, 28, 0, 0, 41, 46, 46,
17, 22, 0, 7, 38, 7, 15, 0, 46, 46,
14, 16, 42, 44, 0, 0, 0, 13, 0
} ;
static yyconst YY_CHAR yy_ec[256] =
@ -387,17 +388,17 @@ static yyconst YY_CHAR yy_ec[256] =
1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 5, 6, 7, 8, 9, 1, 10, 11, 1,
1, 12, 1, 13, 1, 1, 1, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 15, 16, 17,
18, 19, 20, 1, 21, 22, 23, 24, 25, 26,
22, 22, 27, 22, 22, 28, 29, 30, 31, 22,
22, 32, 33, 34, 35, 22, 22, 22, 22, 22,
1, 36, 1, 1, 37, 1, 21, 22, 38, 39,
1, 5, 6, 7, 8, 9, 1, 10, 11, 12,
13, 14, 1, 15, 1, 1, 1, 16, 16, 16,
16, 16, 16, 16, 16, 16, 16, 17, 18, 19,
20, 21, 22, 1, 23, 24, 25, 26, 27, 28,
29, 29, 30, 29, 29, 31, 32, 33, 34, 29,
29, 35, 36, 37, 38, 29, 29, 29, 29, 29,
1, 39, 1, 1, 40, 1, 23, 24, 41, 42,
40, 41, 22, 22, 42, 22, 22, 43, 29, 44,
31, 22, 22, 32, 45, 34, 46, 22, 22, 22,
22, 22, 1, 1, 1, 1, 1, 1, 1, 1,
43, 44, 29, 29, 45, 29, 29, 46, 32, 47,
34, 29, 29, 35, 48, 37, 49, 29, 29, 29,
29, 29, 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,
@ -414,211 +415,217 @@ static yyconst YY_CHAR yy_ec[256] =
1, 1, 1, 1, 1
} ;
static yyconst YY_CHAR yy_meta[47] =
static yyconst YY_CHAR yy_meta[50] =
{ 0,
1, 2, 2, 3, 4, 3, 3, 1, 1, 3,
3, 1, 3, 5, 1, 3, 1, 3, 6, 1,
7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
7, 7, 7, 7, 7, 1, 5, 7, 7, 7,
7, 7, 7, 7, 7, 7
3, 3, 3, 1, 3, 5, 3, 3, 1, 3,
6, 1, 7, 7, 7, 7, 7, 7, 7, 7,
7, 7, 7, 7, 7, 7, 7, 7, 1, 5,
7, 7, 7, 7, 7, 7, 7, 7, 7
} ;
static yyconst flex_uint16_t yy_base[208] =
static yyconst flex_uint16_t yy_base[219] =
{ 0,
0, 45, 0, 46, 392, 53, 49, 59, 61, 71,
392, 0, 572, 572, 364, 572, 91, 77, 572, 572,
342, 572, 317, 232, 0, 19, 42, 218, 40, 92,
137, 96, 174, 240, 220, 257, 572, 238, 97, 572,
572, 0, 205, 572, 302, 50, 77, 83, 59, 137,
156, 572, 0, 572, 123, 0, 84, 130, 90, 92,
167, 572, 0, 176, 347, 0, 190, 94, 175, 200,
121, 92, 201, 393, 193, 572, 0, 162, 222, 175,
171, 209, 176, 281, 184, 207, 307, 313, 328, 348,
338, 111, 0, 205, 213, 125, 0, 354, 185, 280,
0, 48, 0, 49, 513, 56, 52, 57, 62, 68,
515, 0, 583, 583, 509, 583, 97, 74, 583, 583,
583, 583, 491, 583, 423, 421, 0, 19, 40, 392,
36, 47, 86, 146, 88, 186, 413, 235, 275, 583,
407, 98, 583, 583, 0, 386, 583, 323, 65, 73,
81, 74, 127, 146, 583, 583, 583, 108, 0, 89,
120, 92, 362, 116, 161, 583, 0, 167, 371, 0,
168, 131, 146, 171, 81, 89, 352, 420, 353, 583,
0, 349, 178, 196, 175, 197, 188, 208, 196, 197,
256, 262, 324, 330, 337, 143, 0, 151, 220, 56,
336, 300, 340, 309, 278, 321, 139, 130, 245, 572,
335, 347, 351, 356, 360, 375, 375, 379, 383, 300,
80, 381, 384, 390, 392, 393, 397, 399, 397, 402,
403, 106, 105, 284, 572, 572, 407, 408, 411, 320,
413, 413, 420, 419, 421, 420, 572, 572, 421, 426,
428, 420, 467, 432, 101, 83, 438, 572, 572, 439,
446, 572, 436, 449, 63, 0, 450, 572, 572, 450,
453, 481, 572, 64, 0, 572, 572, 454, 460, 0,
464, 572, 572, 463, 572, 572, 572, 572, 468, 471,
495, 572, 0, 496, 0, 38, 572, 572, 513, 520,
305, 0, 336, 139, 225, 315, 305, 322, 318, 163,
320, 268, 266, 369, 583, 340, 347, 350, 350, 351,
357, 350, 357, 363, 140, 235, 359, 218, 362, 375,
379, 380, 381, 385, 384, 404, 405, 243, 235, 213,
583, 583, 405, 407, 410, 171, 410, 409, 419, 418,
423, 426, 311, 583, 583, 428, 429, 431, 173, 462,
435, 166, 145, 438, 583, 583, 441, 444, 583, 433,
448, 89, 0, 438, 450, 583, 583, 452, 457, 487,
583, 114, 0, 583, 583, 457, 462, 0, 465, 463,
583, 583, 468, 583, 583, 583, 583, 470, 471, 474,
526, 529, 536, 543, 550, 557, 564
500, 583, 0, 0, 505, 0, 65, 583, 583, 524,
531, 537, 540, 547, 554, 561, 568, 575
} ;
static yyconst flex_int16_t yy_def[208] =
static yyconst flex_int16_t yy_def[219] =
{ 0,
198, 1, 1, 1, 1, 1, 199, 199, 199, 199,
198, 200, 198, 198, 201, 198, 200, 198, 198, 198,
200, 198, 198, 200, 202, 202, 202, 202, 202, 200,
202, 198, 198, 198, 203, 198, 198, 198, 198, 198,
198, 200, 201, 198, 198, 198, 198, 198, 198, 198,
204, 198, 200, 198, 200, 202, 202, 202, 202, 202,
198, 198, 31, 198, 198, 65, 200, 198, 198, 198,
198, 198, 198, 203, 203, 198, 36, 198, 198, 198,
198, 198, 198, 198, 198, 198, 204, 204, 204, 204,
198, 198, 202, 202, 202, 202, 202, 198, 198, 198,
209, 1, 1, 1, 1, 1, 210, 210, 210, 210,
209, 211, 209, 209, 212, 209, 211, 209, 209, 209,
209, 209, 209, 209, 209, 211, 213, 213, 213, 213,
213, 213, 211, 213, 209, 209, 209, 214, 209, 209,
209, 209, 209, 209, 211, 212, 209, 209, 209, 209,
209, 209, 209, 215, 209, 209, 209, 211, 213, 213,
213, 213, 213, 213, 209, 209, 34, 209, 209, 69,
211, 209, 209, 209, 209, 209, 209, 214, 214, 209,
39, 209, 209, 209, 209, 209, 209, 209, 209, 209,
215, 215, 215, 215, 209, 209, 213, 213, 213, 213,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 202,
202, 202, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 202, 202, 202, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 202, 202, 202, 198, 198, 198, 198,
198, 198, 198, 205, 206, 198, 198, 198, 198, 202,
202, 198, 198, 198, 198, 198, 198, 198, 198, 202,
198, 198, 202, 198, 207, 207, 198, 0, 198, 198,
213, 213, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 213, 213, 213, 213, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 213, 213,
213, 213, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
213, 213, 213, 213, 209, 209, 209, 209, 209, 209,
209, 216, 217, 209, 209, 209, 209, 213, 213, 213,
209, 209, 209, 209, 209, 209, 209, 209, 213, 213,
198, 198, 198, 198, 198, 198, 198
209, 209, 213, 213, 209, 218, 218, 209, 0, 209,
209, 209, 209, 209, 209, 209, 209, 209
} ;
static yyconst flex_uint16_t yy_nxt[619] =
static yyconst flex_uint16_t yy_nxt[633] =
{ 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, 26, 25, 27, 25, 28, 25,
25, 25, 25, 25, 29, 30, 31, 25, 25, 26,
25, 27, 25, 25, 25, 29, 32, 32, 57, 32,
32, 38, 33, 33, 32, 34, 197, 32, 39, 40,
33, 38, 57, 38, 35, 186, 186, 41, 39, 40,
39, 58, 60, 38, 81, 36, 36, 41, 50, 50,
39, 50, 51, 181, 60, 58, 52, 175, 86, 81,
36, 36, 45, 61, 62, 45, 61, 64, 79, 80,
19, 20, 21, 12, 22, 12, 23, 24, 12, 25,
12, 26, 27, 27, 27, 27, 28, 27, 27, 29,
27, 30, 27, 27, 27, 31, 27, 32, 33, 34,
27, 27, 28, 27, 29, 27, 27, 31, 32, 35,
35, 60, 35, 35, 41, 36, 36, 35, 37, 41,
35, 42, 43, 36, 41, 60, 42, 43, 44, 38,
41, 42, 61, 63, 44, 53, 53, 42, 53, 54,
39, 39, 64, 55, 63, 208, 61, 65, 66, 68,
65, 85, 68, 127, 64, 69, 39, 39, 48, 83,
64, 79, 86, 65, 82, 174, 83, 93, 84, 156,
155, 144, 85, 96, 46, 47, 97, 48, 100, 82,
83, 106, 93, 84, 91, 49, 85, 91, 96, 46,
47, 97, 48, 100, 133, 106, 49, 42, 50, 50,
119, 50, 51, 132, 42, 42, 52, 105, 42, 92,
63, 42, 94, 42, 119, 42, 42, 88, 50, 122,
88, 89, 105, 95, 92, 90, 108, 94, 61, 62,
122, 61, 42, 63, 42, 66, 109, 64, 66, 109,
64, 42, 42, 65, 110, 42, 99, 67, 42, 99,
42, 99, 42, 42, 99, 76, 111, 68, 69, 114,
84, 48, 83, 86, 127, 87, 90, 85, 88, 95,
110, 189, 95, 89, 97, 195, 195, 100, 86, 87,
90, 111, 49, 50, 88, 110, 51, 89, 53, 53,
97, 53, 54, 100, 52, 111, 55, 96, 49, 50,
104, 51, 102, 104, 98, 52, 45, 92, 53, 183,
92, 93, 96, 45, 45, 94, 99, 105, 102, 45,
98, 67, 65, 66, 45, 65, 45, 45, 68, 104,
182, 68, 104, 105, 69, 124, 106, 149, 107, 83,
84, 125, 83, 71, 45, 67, 45, 70, 149, 124,
70, 106, 107, 45, 45, 136, 125, 114, 108, 45,
70, 71, 101, 67, 102, 107, 117, 44, 72, 42,
42, 111, 68, 69, 114, 70, 71, 101, 102, 72,
74, 117, 76, 79, 80, 103, 79, 74, 74, 104,
118, 74, 120, 74, 74, 112, 74, 121, 74, 74,
103, 113, 78, 104, 73, 118, 109, 120, 59, 109,
112, 55, 121, 113, 110, 74, 74, 75, 75, 76,
75, 75, 75, 75, 75, 75, 75, 75, 75, 75,
77, 75, 75, 75, 75, 75, 75, 77, 77, 77,
77, 77, 77, 77, 77, 77, 77, 77, 77, 77,
77, 77, 75, 77, 77, 77, 77, 77, 77, 77,
114, 71, 116, 109, 45, 115, 45, 45, 168, 136,
179, 72, 73, 119, 108, 74, 75, 109, 116, 168,
122, 179, 123, 76, 45, 45, 117, 72, 73, 119,
74, 75, 118, 120, 76, 78, 122, 80, 123, 163,
121, 117, 78, 78, 118, 164, 126, 162, 78, 120,
78, 152, 129, 78, 121, 78, 78, 92, 53, 164,
92, 93, 126, 92, 53, 94, 92, 93, 129, 150,
139, 94, 138, 78, 78, 79, 79, 80, 79, 79,
79, 79, 79, 79, 79, 79, 79, 79, 79, 79,
81, 79, 79, 79, 79, 79, 79, 81, 81, 81,
77, 77, 77, 45, 115, 123, 45, 130, 88, 50,
116, 88, 89, 157, 88, 50, 90, 88, 89, 115,
123, 130, 90, 126, 116, 46, 47, 157, 48, 88,
50, 129, 88, 89, 143, 54, 49, 90, 126, 91,
46, 47, 91, 48, 131, 143, 129, 49, 66, 88,
50, 66, 88, 89, 161, 99, 53, 90, 99, 131,
98, 134, 124, 127, 92, 161, 44, 98, 125, 128,
68, 69, 135, 70, 71, 136, 134, 124, 127, 92,
125, 72, 137, 128, 138, 68, 69, 135, 70, 71,
136, 198, 72, 74, 34, 76, 198, 137, 139, 138,
81, 81, 81, 81, 81, 81, 81, 81, 81, 81,
81, 81, 81, 79, 81, 81, 81, 81, 81, 81,
81, 81, 81, 81, 48, 92, 53, 48, 92, 93,
132, 92, 53, 94, 92, 93, 128, 104, 95, 94,
104, 95, 135, 175, 130, 137, 132, 133, 49, 50,
131, 103, 51, 113, 134, 80, 112, 175, 135, 130,
52, 137, 131, 133, 49, 50, 96, 51, 134, 140,
114, 52, 70, 114, 141, 70, 142, 144, 115, 143,
146, 96, 145, 147, 140, 101, 103, 148, 47, 151,
141, 153, 142, 144, 143, 146, 72, 73, 145, 147,
74, 74, 140, 141, 74, 142, 74, 74, 145, 74,
146, 74, 74, 139, 198, 147, 148, 140, 141, 149,
142, 150, 151, 145, 152, 146, 153, 154, 74, 74,
147, 148, 158, 159, 149, 160, 150, 151, 162, 152,
163, 153, 154, 164, 165, 166, 168, 158, 159, 167,
160, 169, 170, 162, 171, 163, 198, 173, 164, 165,
166, 168, 176, 167, 177, 171, 169, 170, 172, 178,
179, 172, 173, 180, 182, 183, 184, 176, 188, 177,
98, 179, 172, 189, 178, 172, 190, 191, 180, 182,
183, 184, 192, 188, 98, 193, 194, 194, 189, 194,
74, 75, 154, 148, 151, 155, 153, 157, 76, 156,
158, 82, 72, 73, 159, 74, 75, 77, 154, 76,
78, 155, 80, 157, 156, 62, 158, 78, 78, 159,
160, 161, 165, 78, 166, 78, 167, 169, 78, 170,
78, 78, 58, 57, 171, 172, 160, 161, 165, 173,
166, 174, 167, 169, 170, 176, 177, 178, 78, 78,
171, 172, 181, 180, 184, 173, 180, 174, 185, 186,
187, 176, 177, 178, 188, 190, 191, 103, 181, 192,
184, 187, 193, 197, 185, 186, 190, 198, 180, 199,
188, 180, 191, 200, 201, 192, 202, 203, 193, 197,
194, 190, 191, 198, 198, 198, 198, 192, 198, 198,
193, 195, 195, 37, 37, 37, 37, 37, 37, 37,
42, 198, 198, 198, 42, 42, 43, 43, 43, 43,
43, 43, 43, 56, 198, 56, 75, 75, 75, 75,
75, 75, 75, 87, 87, 87, 87, 87, 87, 87,
185, 185, 185, 198, 185, 185, 185, 187, 198, 187,
198, 187, 187, 187, 196, 196, 196, 196, 196, 198,
196, 11, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
204, 205, 103, 198, 205, 199, 205, 56, 200, 205,
201, 47, 202, 203, 209, 37, 204, 209, 206, 209,
209, 209, 209, 206, 40, 40, 40, 40, 40, 40,
40, 45, 209, 209, 209, 45, 45, 46, 46, 46,
46, 46, 46, 46, 59, 209, 59, 79, 79, 79,
79, 79, 79, 79, 91, 91, 91, 91, 91, 91,
91, 194, 194, 194, 209, 194, 194, 194, 196, 209,
196, 209, 196, 196, 196, 207, 207, 207, 207, 207,
209, 207, 11, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209
} ;
static yyconst flex_int16_t yy_chk[619] =
static yyconst flex_int16_t yy_chk[633] =
{ 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, 1, 1, 1, 1, 1, 2, 4, 26, 2,
4, 7, 2, 4, 6, 6, 196, 6, 7, 7,
6, 8, 26, 9, 6, 174, 174, 9, 8, 8,
9, 27, 29, 10, 46, 6, 6, 10, 18, 18,
10, 18, 18, 165, 29, 27, 18, 156, 49, 46,
6, 6, 17, 30, 30, 17, 30, 32, 39, 39,
1, 1, 1, 1, 1, 1, 1, 1, 1, 2,
4, 28, 2, 4, 7, 2, 4, 6, 6, 8,
6, 7, 7, 6, 9, 28, 8, 8, 9, 6,
10, 9, 29, 31, 10, 18, 18, 10, 18, 18,
6, 6, 32, 18, 31, 207, 29, 33, 33, 35,
33, 49, 35, 100, 32, 35, 6, 6, 17, 42,
32, 39, 49, 32, 47, 155, 47, 57, 48, 133,
132, 121, 48, 59, 17, 17, 60, 17, 68, 47,
47, 72, 57, 48, 55, 17, 48, 55, 59, 17,
17, 60, 17, 68, 108, 72, 17, 31, 50, 50,
92, 50, 50, 107, 31, 31, 50, 71, 31, 55,
31, 31, 58, 31, 92, 31, 31, 51, 51, 96,
51, 51, 71, 58, 55, 51, 78, 58, 61, 61,
96, 61, 31, 31, 33, 33, 80, 64, 33, 80,
64, 33, 33, 64, 80, 33, 99, 33, 33, 99,
33, 67, 33, 33, 67, 75, 81, 33, 33, 83,
42, 17, 42, 50, 100, 50, 52, 49, 51, 58,
75, 172, 58, 51, 60, 182, 182, 62, 50, 50,
52, 76, 17, 17, 51, 75, 17, 51, 53, 53,
60, 53, 53, 62, 17, 76, 53, 58, 17, 17,
104, 17, 64, 104, 61, 17, 34, 54, 54, 163,
54, 54, 58, 34, 34, 54, 61, 72, 64, 34,
61, 34, 65, 65, 34, 65, 34, 34, 68, 71,
162, 68, 71, 72, 68, 96, 73, 125, 73, 83,
83, 98, 83, 71, 34, 34, 36, 36, 125, 96,
36, 73, 73, 36, 36, 110, 98, 84, 74, 36,
33, 33, 69, 67, 69, 73, 85, 43, 33, 33,
33, 81, 33, 33, 83, 33, 33, 69, 69, 33,
35, 85, 35, 79, 79, 70, 79, 35, 35, 70,
86, 35, 94, 35, 35, 82, 35, 95, 35, 35,
70, 82, 38, 70, 34, 86, 109, 94, 28, 109,
82, 24, 95, 82, 109, 35, 35, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
84, 36, 85, 74, 36, 84, 36, 36, 146, 110,
159, 36, 36, 87, 74, 36, 36, 74, 85, 146,
89, 159, 90, 36, 36, 36, 86, 36, 36, 87,
36, 36, 86, 88, 36, 38, 89, 38, 90, 139,
88, 86, 38, 38, 86, 140, 99, 138, 38, 88,
38, 128, 105, 38, 88, 38, 38, 91, 91, 140,
91, 91, 99, 92, 92, 91, 92, 92, 105, 126,
113, 92, 112, 38, 38, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
36, 36, 36, 45, 84, 100, 45, 105, 87, 87,
84, 87, 87, 134, 88, 88, 87, 88, 88, 84,
100, 105, 88, 102, 84, 45, 45, 134, 45, 89,
89, 104, 89, 89, 120, 23, 45, 89, 102, 91,
45, 45, 91, 45, 106, 120, 104, 45, 65, 90,
90, 65, 90, 90, 140, 98, 21, 90, 98, 106,
65, 111, 101, 103, 91, 140, 15, 98, 101, 103,
65, 65, 112, 65, 65, 113, 111, 101, 103, 91,
101, 65, 114, 103, 115, 65, 65, 112, 65, 65,
113, 11, 65, 74, 5, 74, 0, 114, 116, 115,
39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 48, 93, 93, 48, 93, 93,
107, 94, 94, 93, 94, 94, 101, 103, 95, 94,
103, 95, 109, 153, 106, 111, 107, 108, 48, 48,
106, 103, 48, 82, 108, 79, 77, 153, 109, 106,
48, 111, 106, 108, 48, 48, 95, 48, 108, 116,
114, 48, 69, 114, 117, 69, 118, 120, 114, 119,
122, 95, 121, 123, 116, 63, 69, 124, 46, 127,
117, 129, 118, 120, 119, 122, 69, 69, 121, 123,
74, 74, 117, 118, 74, 119, 74, 74, 122, 74,
123, 74, 74, 116, 0, 124, 125, 117, 118, 126,
119, 127, 128, 122, 129, 123, 130, 131, 74, 74,
124, 125, 137, 138, 126, 139, 127, 128, 141, 129,
142, 130, 131, 143, 144, 145, 149, 137, 138, 146,
139, 150, 151, 141, 152, 142, 0, 154, 143, 144,
145, 149, 157, 146, 160, 152, 150, 151, 153, 161,
163, 153, 154, 164, 167, 170, 171, 157, 178, 160,
153, 163, 172, 179, 161, 172, 181, 184, 164, 167,
170, 171, 189, 178, 172, 190, 191, 194, 179, 191,
69, 69, 130, 124, 127, 131, 129, 133, 69, 132,
134, 41, 69, 69, 135, 69, 69, 37, 130, 69,
78, 131, 78, 133, 132, 30, 134, 78, 78, 135,
136, 137, 143, 78, 144, 78, 145, 147, 78, 148,
78, 78, 26, 25, 149, 150, 136, 137, 143, 151,
144, 152, 145, 147, 148, 156, 157, 158, 78, 78,
149, 150, 161, 160, 164, 151, 160, 152, 167, 168,
170, 156, 157, 158, 171, 174, 175, 160, 161, 178,
164, 170, 179, 186, 167, 168, 174, 187, 180, 189,
171, 180, 175, 190, 193, 178, 198, 199, 179, 186,
194, 181, 184, 0, 0, 0, 0, 189, 0, 0,
190, 191, 194, 199, 199, 199, 199, 199, 199, 199,
200, 0, 0, 0, 200, 200, 201, 201, 201, 201,
201, 201, 201, 202, 0, 202, 203, 203, 203, 203,
203, 203, 203, 204, 204, 204, 204, 204, 204, 204,
205, 205, 205, 0, 205, 205, 205, 206, 0, 206,
0, 206, 206, 206, 207, 207, 207, 207, 207, 0,
207, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
200, 201, 180, 187, 201, 189, 205, 23, 190, 205,
193, 15, 198, 199, 11, 5, 200, 0, 201, 0,
0, 0, 0, 205, 210, 210, 210, 210, 210, 210,
210, 211, 0, 0, 0, 211, 211, 212, 212, 212,
212, 212, 212, 212, 213, 0, 213, 214, 214, 214,
214, 214, 214, 214, 215, 215, 215, 215, 215, 215,
215, 216, 216, 216, 0, 216, 216, 216, 217, 0,
217, 0, 217, 217, 217, 218, 218, 218, 218, 218,
0, 218, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
198, 198, 198, 198, 198, 198, 198, 198
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
209, 209
} ;
/* The intent behind this definition is that it'll catch
@ -685,7 +692,7 @@ Modify cmFortranLexer.cxx:
/*--------------------------------------------------------------------------*/
#line 689 "cmFortranLexer.cxx"
#line 696 "cmFortranLexer.cxx"
#define INITIAL 0
#define free_fmt 1
@ -956,7 +963,7 @@ YY_DECL
#line 65 "cmFortranLexer.in.l"
#line 960 "cmFortranLexer.cxx"
#line 967 "cmFortranLexer.cxx"
while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
{
@ -984,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 >= 199 )
if ( yy_current_state >= 210 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (flex_int16_t) yy_c];
++yy_cp;
}
while ( yy_base[yy_current_state] != 572 );
while ( yy_base[yy_current_state] != 583 );
yy_find_action:
yy_act = yy_accept[yy_current_state];
@ -1201,71 +1208,87 @@ YY_RULE_SETUP
#line 148 "cmFortranLexer.in.l"
{ return DCOLON; }
case 37:
/* rule 37 can match eol */
YY_RULE_SETUP
#line 150 "cmFortranLexer.in.l"
{ return GARBAGE; }
#line 149 "cmFortranLexer.in.l"
{ return COLON; }
case 38:
/* rule 38 can match eol */
YY_RULE_SETUP
#line 152 "cmFortranLexer.in.l"
{ return ASSIGNMENT_OP; }
#line 151 "cmFortranLexer.in.l"
{ return GARBAGE; }
case 39:
YY_RULE_SETUP
#line 154 "cmFortranLexer.in.l"
{ return END; }
#line 153 "cmFortranLexer.in.l"
{ return ASSIGNMENT_OP; }
case 40:
YY_RULE_SETUP
#line 155 "cmFortranLexer.in.l"
{ return INCLUDE; }
{ return END; }
case 41:
YY_RULE_SETUP
#line 156 "cmFortranLexer.in.l"
{ return INTERFACE; }
{ return INCLUDE; }
case 42:
YY_RULE_SETUP
#line 157 "cmFortranLexer.in.l"
{ return MODULE; }
{ return INTERFACE; }
case 43:
YY_RULE_SETUP
#line 158 "cmFortranLexer.in.l"
{ return USE; }
{ return MODULE; }
case 44:
YY_RULE_SETUP
#line 159 "cmFortranLexer.in.l"
{ return SUBMODULE; }
case 45:
YY_RULE_SETUP
#line 160 "cmFortranLexer.in.l"
{ return USE; }
case 46:
YY_RULE_SETUP
#line 162 "cmFortranLexer.in.l"
{
yylvalp->string = strdup(yytext);
return WORD;
}
case 45:
YY_RULE_SETUP
#line 165 "cmFortranLexer.in.l"
{ return GARBAGE; }
case 46:
/* rule 46 can match eol */
YY_RULE_SETUP
#line 167 "cmFortranLexer.in.l"
{ return EOSTMT; }
case 47:
YY_RULE_SETUP
#line 170 "cmFortranLexer.in.l"
/* Ignore */
YY_BREAK
#line 167 "cmFortranLexer.in.l"
{ return LPAREN; }
case 48:
/* rule 48 can match eol */
YY_RULE_SETUP
#line 171 "cmFortranLexer.in.l"
/* Ignore line-endings preceded by \ */
YY_BREAK
#line 168 "cmFortranLexer.in.l"
{ return RPAREN; }
case 49:
YY_RULE_SETUP
#line 173 "cmFortranLexer.in.l"
#line 170 "cmFortranLexer.in.l"
{ return GARBAGE; }
case 50:
/* rule 50 can match eol */
YY_RULE_SETUP
#line 172 "cmFortranLexer.in.l"
{ return EOSTMT; }
case 51:
YY_RULE_SETUP
#line 175 "cmFortranLexer.in.l"
/* Ignore */
YY_BREAK
case 52:
/* rule 52 can match eol */
YY_RULE_SETUP
#line 176 "cmFortranLexer.in.l"
/* Ignore line-endings preceded by \ */
YY_BREAK
case 53:
YY_RULE_SETUP
#line 178 "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 175 "cmFortranLexer.in.l"
#line 180 "cmFortranLexer.in.l"
{
if(!cmFortranParser_FilePop(yyextra) )
{
@ -1273,12 +1296,12 @@ case YY_STATE_EOF(str_dq):
}
}
YY_BREAK
case 50:
case 54:
YY_RULE_SETUP
#line 182 "cmFortranLexer.in.l"
#line 187 "cmFortranLexer.in.l"
ECHO;
YY_BREAK
#line 1320 "cmFortranLexer.cxx"
#line 1347 "cmFortranLexer.cxx"
case YY_END_OF_BUFFER:
{
@ -1572,7 +1595,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 >= 199 )
if ( yy_current_state >= 210 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (flex_int16_t) yy_c];
@ -1601,11 +1624,11 @@ 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 >= 199 )
if ( yy_current_state >= 210 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (flex_int16_t) yy_c];
yy_is_jam = (yy_current_state == 198);
yy_is_jam = (yy_current_state == 209);
(void)yyg;
return yy_is_jam ? 0 : yy_current_state;
@ -2447,7 +2470,7 @@ void cmFortran_yyfree (void * ptr , yyscan_t yyscanner)
#define YYTABLES_NAME "yytables"
#line 182 "cmFortranLexer.in.l"
#line 187 "cmFortranLexer.in.l"

View File

@ -337,7 +337,7 @@ extern int cmFortran_yylex (yyscan_t yyscanner);
#undef YY_DECL
#endif
#line 182 "cmFortranLexer.in.l"
#line 187 "cmFortranLexer.in.l"
#line 344 "cmFortranLexer.h"

View File

@ -146,6 +146,7 @@ $[ \t]*endif { return F90PPR_ENDIF; }
, { return COMMA; }
:: { return DCOLON; }
: { return COLON; }
<fixed_fmt>\n[ ]{5}[^ ] { return GARBAGE; }
@ -155,6 +156,7 @@ $[ \t]*endif { return F90PPR_ENDIF; }
[Ii][Nn][Cc][Ll][Uu][Dd][Ee] { return INCLUDE; }
[Ii][Nn][Tt][Ee][Rr][Ff][Aa][Cc][Ee] { return INTERFACE; }
[Mm][Oo][Dd][Uu][Ll][Ee] { return MODULE; }
[Ss][Uu][bb][Mm][Oo][Dd][Uu][Ll][Ee] { return SUBMODULE; }
[Uu][Ss][Ee] { return USE; }
[a-zA-Z_][a-zA-Z_0-9]* {
@ -162,7 +164,10 @@ $[ \t]*endif { return F90PPR_ENDIF; }
return WORD;
}
[^ \t\n\r;,!'"a-zA-Z=&]+ { return GARBAGE; }
\( { return LPAREN; }
\) { return RPAREN; }
[^ \t\n\r:;,!'"a-zA-Z=&()]+ { return GARBAGE; }
;|\n { return EOSTMT; }

View File

@ -192,16 +192,20 @@ extern int cmFortran_yydebug;
F90PPR_ELIF = 279,
F90PPR_ENDIF = 280,
COMMA = 281,
DCOLON = 282,
UNTERMINATED_STRING = 283,
STRING = 284,
WORD = 285,
CPP_INCLUDE_ANGLE = 286,
END = 287,
INCLUDE = 288,
INTERFACE = 289,
MODULE = 290,
USE = 291
COLON = 282,
DCOLON = 283,
LPAREN = 284,
RPAREN = 285,
UNTERMINATED_STRING = 286,
STRING = 287,
WORD = 288,
CPP_INCLUDE_ANGLE = 289,
END = 290,
INCLUDE = 291,
INTERFACE = 292,
MODULE = 293,
SUBMODULE = 294,
USE = 295
};
#endif
/* Tokens. */
@ -229,16 +233,20 @@ extern int cmFortran_yydebug;
#define F90PPR_ELIF 279
#define F90PPR_ENDIF 280
#define COMMA 281
#define DCOLON 282
#define UNTERMINATED_STRING 283
#define STRING 284
#define WORD 285
#define CPP_INCLUDE_ANGLE 286
#define END 287
#define INCLUDE 288
#define INTERFACE 289
#define MODULE 290
#define USE 291
#define COLON 282
#define DCOLON 283
#define LPAREN 284
#define RPAREN 285
#define UNTERMINATED_STRING 286
#define STRING 287
#define WORD 288
#define CPP_INCLUDE_ANGLE 289
#define END 290
#define INCLUDE 291
#define INTERFACE 292
#define MODULE 293
#define SUBMODULE 294
#define USE 295
/* Value type. */
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
@ -249,7 +257,7 @@ union YYSTYPE
char* string;
#line 253 "cmFortranParser.cxx" /* yacc.c:355 */
#line 261 "cmFortranParser.cxx" /* yacc.c:355 */
};
typedef union YYSTYPE YYSTYPE;
@ -265,7 +273,7 @@ int cmFortran_yyparse (yyscan_t yyscanner);
/* Copy the second part of user declarations. */
#line 269 "cmFortranParser.cxx" /* yacc.c:358 */
#line 277 "cmFortranParser.cxx" /* yacc.c:358 */
#ifdef short
# undef short
@ -507,21 +515,21 @@ union yyalloc
/* YYFINAL -- State number of the termination state. */
#define YYFINAL 2
/* YYLAST -- Last index in YYTABLE. */
#define YYLAST 469
#define YYLAST 593
/* YYNTOKENS -- Number of terminals. */
#define YYNTOKENS 37
#define YYNTOKENS 41
/* YYNNTS -- Number of nonterminals. */
#define YYNNTS 14
/* YYNRULES -- Number of rules. */
#define YYNRULES 57
#define YYNRULES 63
/* YYNSTATES -- Number of states. */
#define YYNSTATES 109
#define YYNSTATES 126
/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned
by yylex, with out-of-bounds checking. */
#define YYUNDEFTOK 2
#define YYMAXUTOK 291
#define YYMAXUTOK 295
#define YYTRANSLATE(YYX) \
((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
@ -559,19 +567,20 @@ static const yytype_uint8 yytranslate[] =
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, 32, 33, 34,
35, 36
35, 36, 37, 38, 39, 40
};
#if YYDEBUG
/* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
static const yytype_uint8 yyrline[] =
{
0, 102, 102, 102, 105, 109, 114, 119, 124, 128,
133, 141, 146, 151, 156, 161, 166, 171, 176, 181,
185, 189, 193, 197, 198, 203, 203, 203, 204, 204,
205, 205, 206, 206, 207, 207, 208, 208, 209, 209,
210, 210, 211, 211, 212, 212, 215, 216, 217, 218,
219, 220, 221, 222, 223, 224, 225, 226
0, 103, 103, 103, 106, 110, 115, 124, 130, 137,
142, 146, 151, 159, 164, 169, 174, 179, 184, 189,
194, 199, 203, 207, 211, 215, 216, 221, 221, 221,
222, 222, 223, 223, 224, 224, 225, 225, 226, 226,
227, 227, 228, 228, 229, 229, 230, 230, 233, 234,
235, 236, 237, 238, 239, 240, 241, 242, 243, 244,
245, 246, 247, 248
};
#endif
@ -585,10 +594,11 @@ static const char *const yytname[] =
"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", "UNTERMINATED_STRING",
"STRING", "WORD", "CPP_INCLUDE_ANGLE", "END", "INCLUDE", "INTERFACE",
"MODULE", "USE", "$accept", "code", "stmt", "include", "define", "undef",
"ifdef", "ifndef", "if", "elif", "else", "endif", "other", "misc_code", YY_NULLPTR
"F90PPR_ELIF", "F90PPR_ENDIF", "COMMA", "COLON", "DCOLON", "LPAREN",
"RPAREN", "UNTERMINATED_STRING", "STRING", "WORD", "CPP_INCLUDE_ANGLE",
"END", "INCLUDE", "INTERFACE", "MODULE", "SUBMODULE", "USE", "$accept",
"code", "stmt", "include", "define", "undef", "ifdef", "ifndef", "if",
"elif", "else", "endif", "other", "misc_code", YY_NULLPTR
};
#endif
@ -600,14 +610,15 @@ 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, 287, 288, 289, 290, 291
285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
295
};
# endif
#define YYPACT_NINF -38
#define YYPACT_NINF -39
#define yypact_value_is_default(Yystate) \
(!!((Yystate) == (-38)))
(!!((Yystate) == (-39)))
#define YYTABLE_NINF -1
@ -618,17 +629,19 @@ static const yytype_uint16 yytoknum[] =
STATE-NUM. */
static const yytype_int16 yypact[] =
{
-38, 39, -38, 3, -38, -20, -38, -38, -38, -38,
-38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
-38, -38, -38, -38, -38, -38, -22, -16, 1, -8,
-6, -38, -4, -7, -3, -2, -1, -38, -38, -38,
-38, -38, -38, 62, -38, -38, -38, -38, -38, 0,
2, -38, -38, -38, -38, -38, -38, 73, 107, 118,
152, 163, -38, -38, -38, -38, -38, -38, -38, -38,
-38, -38, -38, -38, -38, -38, 197, 208, 242, 253,
6, -38, 287, 298, 332, 343, 377, 388, -38, -38,
-38, -38, -38, -38, -38, -38, -38, 4, 422, -38,
-38, -38, -38, -38, -38, -38, -38, 433, -38
-39, 21, -39, 1, -39, -20, -39, -39, -39, -39,
-39, -39, -39, -39, -39, -39, -39, -39, -39, -39,
-39, -39, -39, -39, -39, -39, -24, -18, 20, -8,
-3, 39, -39, 15, 16, 18, 19, 33, -39, -39,
-39, -39, -39, -39, 59, -39, -39, -39, -39, -39,
35, 36, 37, -39, -39, -39, -39, -39, -39, 76,
114, 129, 167, 182, -39, -39, -39, -39, -39, -39,
-39, -39, -39, -39, -39, -39, -39, -39, -39, -39,
-39, -39, 220, 235, 273, 288, -21, 26, -39, 326,
341, 379, 394, 432, 447, -39, -39, -39, -39, -39,
-39, -39, -39, -39, 38, 40, 41, 485, -39, -39,
-39, -39, -39, -39, 45, -39, -39, -39, 43, 500,
538, -39, -39, -39, 553, -39
};
/* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
@ -636,31 +649,33 @@ static const yytype_int16 yypact[] =
means the default is an error. */
static const yytype_uint8 yydefact[] =
{
2, 0, 1, 0, 23, 0, 25, 26, 27, 29,
28, 31, 30, 32, 34, 36, 40, 38, 42, 33,
35, 37, 41, 39, 43, 44, 0, 0, 0, 0,
0, 3, 0, 0, 0, 0, 0, 44, 44, 44,
44, 24, 44, 0, 44, 44, 4, 44, 44, 0,
0, 44, 44, 44, 44, 44, 44, 0, 0, 0,
0, 0, 13, 54, 53, 56, 55, 57, 52, 46,
47, 48, 49, 50, 51, 45, 0, 0, 0, 0,
0, 44, 0, 0, 0, 0, 0, 0, 19, 20,
21, 22, 12, 8, 11, 7, 6, 0, 0, 5,
14, 15, 16, 17, 18, 44, 9, 0, 10
2, 0, 1, 0, 25, 0, 27, 28, 29, 31,
30, 33, 32, 34, 36, 38, 42, 40, 44, 35,
37, 39, 43, 41, 45, 46, 0, 0, 0, 0,
0, 0, 3, 0, 0, 0, 0, 0, 46, 46,
46, 46, 26, 46, 0, 46, 46, 4, 46, 46,
0, 0, 0, 46, 46, 46, 46, 46, 46, 0,
0, 0, 0, 0, 15, 57, 56, 62, 58, 59,
60, 61, 63, 55, 48, 49, 50, 51, 52, 53,
54, 47, 0, 0, 0, 0, 0, 0, 46, 0,
0, 0, 0, 0, 0, 21, 22, 23, 24, 14,
10, 13, 9, 6, 0, 0, 0, 0, 5, 16,
17, 18, 19, 20, 0, 46, 46, 11, 0, 0,
0, 46, 7, 12, 0, 8
};
/* YYPGOTO[NTERM-NUM]. */
static const yytype_int8 yypgoto[] =
{
-38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
-38, -38, -37, -38
-39, -39, -39, -39, -39, -39, -39, -39, -39, -39,
-39, -39, -38, -39
};
/* YYDEFGOTO[NTERM-NUM]. */
static const yytype_int8 yydefgoto[] =
{
-1, 1, 31, 32, 33, 34, 35, 36, 37, 38,
39, 40, 43, 75
-1, 1, 32, 33, 34, 35, 36, 37, 38, 39,
40, 41, 44, 81
};
/* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
@ -668,143 +683,173 @@ static const yytype_int8 yydefgoto[] =
number is the opposite. If YYTABLE_NINF, syntax error. */
static const yytype_uint8 yytable[] =
{
57, 58, 59, 60, 46, 61, 41, 76, 77, 42,
78, 79, 44, 45, 82, 83, 84, 85, 86, 87,
49, 50, 48, 53, 51, 52, 0, 54, 55, 56,
80, 47, 81, 97, 105, 0, 0, 0, 0, 2,
3, 0, 4, 0, 98, 5, 6, 7, 8, 9,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
20, 21, 22, 23, 24, 62, 63, 64, 107, 0,
25, 26, 27, 28, 29, 30, 88, 63, 64, 0,
0, 0, 0, 0, 0, 0, 0, 0, 65, 66,
67, 68, 69, 0, 70, 71, 72, 73, 74, 65,
66, 67, 68, 69, 0, 70, 71, 72, 73, 74,
89, 63, 64, 0, 0, 0, 0, 0, 0, 0,
0, 90, 63, 64, 0, 0, 0, 0, 0, 0,
0, 0, 0, 65, 66, 67, 68, 69, 0, 70,
71, 72, 73, 74, 65, 66, 67, 68, 69, 0,
70, 71, 72, 73, 74, 91, 63, 64, 0, 0,
0, 0, 0, 0, 0, 0, 92, 63, 64, 0,
0, 0, 0, 0, 0, 0, 0, 0, 65, 66,
67, 68, 69, 0, 70, 71, 72, 73, 74, 65,
66, 67, 68, 69, 0, 70, 71, 72, 73, 74,
93, 63, 64, 0, 0, 0, 0, 0, 0, 0,
0, 94, 63, 64, 0, 0, 0, 0, 0, 0,
0, 0, 0, 65, 66, 67, 68, 69, 0, 70,
71, 72, 73, 74, 65, 66, 67, 68, 69, 0,
70, 71, 72, 73, 74, 95, 63, 64, 0, 0,
0, 0, 0, 0, 0, 0, 96, 63, 64, 0,
0, 0, 0, 0, 0, 0, 0, 0, 65, 66,
67, 68, 69, 0, 70, 71, 72, 73, 74, 65,
66, 67, 68, 69, 0, 70, 71, 72, 73, 74,
99, 63, 64, 0, 0, 0, 0, 0, 0, 0,
0, 100, 63, 64, 0, 0, 0, 0, 0, 0,
0, 0, 0, 65, 66, 67, 68, 69, 0, 70,
71, 72, 73, 74, 65, 66, 67, 68, 69, 0,
70, 71, 72, 73, 74, 101, 63, 64, 0, 0,
0, 0, 0, 0, 0, 0, 102, 63, 64, 0,
0, 0, 0, 0, 0, 0, 0, 0, 65, 66,
67, 68, 69, 0, 70, 71, 72, 73, 74, 65,
66, 67, 68, 69, 0, 70, 71, 72, 73, 74,
103, 63, 64, 0, 0, 0, 0, 0, 0, 0,
0, 104, 63, 64, 0, 0, 0, 0, 0, 0,
0, 0, 0, 65, 66, 67, 68, 69, 0, 70,
71, 72, 73, 74, 65, 66, 67, 68, 69, 0,
70, 71, 72, 73, 74, 106, 63, 64, 0, 0,
0, 0, 0, 0, 0, 0, 108, 63, 64, 0,
0, 0, 0, 0, 0, 0, 0, 0, 65, 66,
67, 68, 69, 0, 70, 71, 72, 73, 74, 65,
66, 67, 68, 69, 0, 70, 71, 72, 73, 74
59, 60, 61, 62, 42, 63, 104, 82, 83, 105,
84, 85, 43, 45, 46, 89, 90, 91, 92, 93,
94, 2, 3, 47, 4, 49, 50, 5, 6, 7,
8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 54, 0, 55,
107, 56, 57, 48, 106, 25, 26, 27, 28, 29,
30, 31, 64, 65, 66, 51, 58, 52, 86, 87,
88, 114, 53, 115, 116, 118, 121, 119, 120, 95,
65, 66, 0, 124, 0, 67, 68, 69, 70, 71,
72, 73, 74, 0, 75, 76, 77, 78, 79, 80,
0, 0, 67, 68, 69, 70, 71, 72, 73, 74,
0, 75, 76, 77, 78, 79, 80, 96, 65, 66,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 97, 65, 66, 0, 0, 0, 0, 0,
67, 68, 69, 70, 71, 72, 73, 74, 0, 75,
76, 77, 78, 79, 80, 67, 68, 69, 70, 71,
72, 73, 74, 0, 75, 76, 77, 78, 79, 80,
98, 65, 66, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 99, 65, 66, 0, 0,
0, 0, 0, 67, 68, 69, 70, 71, 72, 73,
74, 0, 75, 76, 77, 78, 79, 80, 67, 68,
69, 70, 71, 72, 73, 74, 0, 75, 76, 77,
78, 79, 80, 100, 65, 66, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 101, 65,
66, 0, 0, 0, 0, 0, 67, 68, 69, 70,
71, 72, 73, 74, 0, 75, 76, 77, 78, 79,
80, 67, 68, 69, 70, 71, 72, 73, 74, 0,
75, 76, 77, 78, 79, 80, 102, 65, 66, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 103, 65, 66, 0, 0, 0, 0, 0, 67,
68, 69, 70, 71, 72, 73, 74, 0, 75, 76,
77, 78, 79, 80, 67, 68, 69, 70, 71, 72,
73, 74, 0, 75, 76, 77, 78, 79, 80, 108,
65, 66, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 109, 65, 66, 0, 0, 0,
0, 0, 67, 68, 69, 70, 71, 72, 73, 74,
0, 75, 76, 77, 78, 79, 80, 67, 68, 69,
70, 71, 72, 73, 74, 0, 75, 76, 77, 78,
79, 80, 110, 65, 66, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 111, 65, 66,
0, 0, 0, 0, 0, 67, 68, 69, 70, 71,
72, 73, 74, 0, 75, 76, 77, 78, 79, 80,
67, 68, 69, 70, 71, 72, 73, 74, 0, 75,
76, 77, 78, 79, 80, 112, 65, 66, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
113, 65, 66, 0, 0, 0, 0, 0, 67, 68,
69, 70, 71, 72, 73, 74, 0, 75, 76, 77,
78, 79, 80, 67, 68, 69, 70, 71, 72, 73,
74, 0, 75, 76, 77, 78, 79, 80, 117, 65,
66, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 122, 65, 66, 0, 0, 0, 0,
0, 67, 68, 69, 70, 71, 72, 73, 74, 0,
75, 76, 77, 78, 79, 80, 67, 68, 69, 70,
71, 72, 73, 74, 0, 75, 76, 77, 78, 79,
80, 123, 65, 66, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 125, 65, 66, 0,
0, 0, 0, 0, 67, 68, 69, 70, 71, 72,
73, 74, 0, 75, 76, 77, 78, 79, 80, 67,
68, 69, 70, 71, 72, 73, 74, 0, 75, 76,
77, 78, 79, 80
};
static const yytype_int8 yycheck[] =
{
37, 38, 39, 40, 3, 42, 3, 44, 45, 29,
47, 48, 34, 29, 51, 52, 53, 54, 55, 56,
26, 27, 30, 30, 30, 29, -1, 30, 30, 30,
30, 30, 30, 27, 30, -1, -1, -1, -1, 0,
1, -1, 3, -1, 81, 6, 7, 8, 9, 10,
11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
21, 22, 23, 24, 25, 3, 4, 5, 105, -1,
31, 32, 33, 34, 35, 36, 3, 4, 5, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 26, 27,
28, 29, 30, -1, 32, 33, 34, 35, 36, 26,
27, 28, 29, 30, -1, 32, 33, 34, 35, 36,
38, 39, 40, 41, 3, 43, 27, 45, 46, 30,
48, 49, 32, 37, 32, 53, 54, 55, 56, 57,
58, 0, 1, 3, 3, 33, 29, 6, 7, 8,
9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
19, 20, 21, 22, 23, 24, 25, 32, -1, 33,
88, 33, 33, 33, 28, 34, 35, 36, 37, 38,
39, 40, 3, 4, 5, 26, 33, 28, 33, 33,
33, 33, 33, 33, 33, 30, 33, 115, 116, 3,
4, 5, -1, 121, -1, 26, 27, 28, 29, 30,
31, 32, 33, -1, 35, 36, 37, 38, 39, 40,
-1, -1, 26, 27, 28, 29, 30, 31, 32, 33,
-1, 35, 36, 37, 38, 39, 40, 3, 4, 5,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, 3, 4, 5, -1, -1, -1, -1, -1,
26, 27, 28, 29, 30, 31, 32, 33, -1, 35,
36, 37, 38, 39, 40, 26, 27, 28, 29, 30,
31, 32, 33, -1, 35, 36, 37, 38, 39, 40,
3, 4, 5, -1, -1, -1, -1, -1, -1, -1,
-1, 3, 4, 5, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 26, 27, 28, 29, 30, -1, 32,
33, 34, 35, 36, 26, 27, 28, 29, 30, -1,
32, 33, 34, 35, 36, 3, 4, 5, -1, -1,
-1, -1, -1, -1, -1, 3, 4, 5, -1, -1,
-1, -1, -1, 26, 27, 28, 29, 30, 31, 32,
33, -1, 35, 36, 37, 38, 39, 40, 26, 27,
28, 29, 30, 31, 32, 33, -1, 35, 36, 37,
38, 39, 40, 3, 4, 5, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 3, 4,
5, -1, -1, -1, -1, -1, 26, 27, 28, 29,
30, 31, 32, 33, -1, 35, 36, 37, 38, 39,
40, 26, 27, 28, 29, 30, 31, 32, 33, -1,
35, 36, 37, 38, 39, 40, 3, 4, 5, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, 3, 4, 5, -1, -1, -1, -1, -1, 26,
27, 28, 29, 30, 31, 32, 33, -1, 35, 36,
37, 38, 39, 40, 26, 27, 28, 29, 30, 31,
32, 33, -1, 35, 36, 37, 38, 39, 40, 3,
4, 5, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, 3, 4, 5, -1, -1, -1,
-1, -1, 26, 27, 28, 29, 30, 31, 32, 33,
-1, 35, 36, 37, 38, 39, 40, 26, 27, 28,
29, 30, 31, 32, 33, -1, 35, 36, 37, 38,
39, 40, 3, 4, 5, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
-1, -1, -1, -1, -1, 26, 27, 28, 29, 30,
31, 32, 33, -1, 35, 36, 37, 38, 39, 40,
26, 27, 28, 29, 30, 31, 32, 33, -1, 35,
36, 37, 38, 39, 40, 3, 4, 5, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
3, 4, 5, -1, -1, -1, -1, -1, 26, 27,
28, 29, 30, 31, 32, 33, -1, 35, 36, 37,
38, 39, 40, 26, 27, 28, 29, 30, 31, 32,
33, -1, 35, 36, 37, 38, 39, 40, 3, 4,
5, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 3, 4, 5, -1, -1, -1, -1,
-1, 26, 27, 28, 29, 30, 31, 32, 33, -1,
35, 36, 37, 38, 39, 40, 26, 27, 28, 29,
30, 31, 32, 33, -1, 35, 36, 37, 38, 39,
40, 3, 4, 5, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, 3, 4, 5, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 26, 27,
28, 29, 30, -1, 32, 33, 34, 35, 36, 26,
27, 28, 29, 30, -1, 32, 33, 34, 35, 36,
3, 4, 5, -1, -1, -1, -1, -1, -1, -1,
-1, 3, 4, 5, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 26, 27, 28, 29, 30, -1, 32,
33, 34, 35, 36, 26, 27, 28, 29, 30, -1,
32, 33, 34, 35, 36, 3, 4, 5, -1, -1,
-1, -1, -1, -1, -1, -1, 3, 4, 5, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 26, 27,
28, 29, 30, -1, 32, 33, 34, 35, 36, 26,
27, 28, 29, 30, -1, 32, 33, 34, 35, 36,
3, 4, 5, -1, -1, -1, -1, -1, -1, -1,
-1, 3, 4, 5, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 26, 27, 28, 29, 30, -1, 32,
33, 34, 35, 36, 26, 27, 28, 29, 30, -1,
32, 33, 34, 35, 36, 3, 4, 5, -1, -1,
-1, -1, -1, -1, -1, -1, 3, 4, 5, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 26, 27,
28, 29, 30, -1, 32, 33, 34, 35, 36, 26,
27, 28, 29, 30, -1, 32, 33, 34, 35, 36,
3, 4, 5, -1, -1, -1, -1, -1, -1, -1,
-1, 3, 4, 5, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 26, 27, 28, 29, 30, -1, 32,
33, 34, 35, 36, 26, 27, 28, 29, 30, -1,
32, 33, 34, 35, 36, 3, 4, 5, -1, -1,
-1, -1, -1, -1, -1, -1, 3, 4, 5, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 26, 27,
28, 29, 30, -1, 32, 33, 34, 35, 36, 26,
27, 28, 29, 30, -1, 32, 33, 34, 35, 36
-1, -1, -1, -1, 26, 27, 28, 29, 30, 31,
32, 33, -1, 35, 36, 37, 38, 39, 40, 26,
27, 28, 29, 30, 31, 32, 33, -1, 35, 36,
37, 38, 39, 40
};
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
symbol of state STATE-NUM. */
static const yytype_uint8 yystos[] =
{
0, 38, 0, 1, 3, 6, 7, 8, 9, 10,
0, 42, 0, 1, 3, 6, 7, 8, 9, 10,
11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
21, 22, 23, 24, 25, 31, 32, 33, 34, 35,
36, 39, 40, 41, 42, 43, 44, 45, 46, 47,
48, 3, 29, 49, 34, 29, 3, 30, 30, 26,
27, 30, 29, 30, 30, 30, 30, 49, 49, 49,
49, 49, 3, 4, 5, 26, 27, 28, 29, 30,
32, 33, 34, 35, 36, 50, 49, 49, 49, 49,
30, 30, 49, 49, 49, 49, 49, 49, 3, 3,
3, 3, 3, 3, 3, 3, 3, 27, 49, 3,
3, 3, 3, 3, 3, 30, 3, 49, 3
21, 22, 23, 24, 25, 34, 35, 36, 37, 38,
39, 40, 43, 44, 45, 46, 47, 48, 49, 50,
51, 52, 3, 32, 53, 37, 32, 3, 33, 33,
29, 26, 28, 33, 32, 33, 33, 33, 33, 53,
53, 53, 53, 53, 3, 4, 5, 26, 27, 28,
29, 30, 31, 32, 33, 35, 36, 37, 38, 39,
40, 54, 53, 53, 53, 53, 33, 33, 33, 53,
53, 53, 53, 53, 53, 3, 3, 3, 3, 3,
3, 3, 3, 3, 27, 30, 28, 53, 3, 3,
3, 3, 3, 3, 33, 33, 33, 3, 30, 53,
53, 33, 3, 3, 53, 3
};
/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
static const yytype_uint8 yyr1[] =
{
0, 37, 38, 38, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
39, 39, 39, 39, 39, 40, 40, 40, 41, 41,
42, 42, 43, 43, 44, 44, 45, 45, 46, 46,
47, 47, 48, 48, 49, 49, 50, 50, 50, 50,
50, 50, 50, 50, 50, 50, 50, 50
0, 41, 42, 42, 43, 43, 43, 43, 43, 43,
43, 43, 43, 43, 43, 43, 43, 43, 43, 43,
43, 43, 43, 43, 43, 43, 43, 44, 44, 44,
45, 45, 46, 46, 47, 47, 48, 48, 49, 49,
50, 50, 51, 51, 52, 52, 53, 53, 54, 54,
54, 54, 54, 54, 54, 54, 54, 54, 54, 54,
54, 54, 54, 54
};
/* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
static const yytype_uint8 yyr2[] =
{
0, 2, 0, 2, 2, 4, 4, 4, 4, 5,
7, 4, 4, 3, 4, 4, 4, 4, 4, 3,
3, 3, 3, 1, 2, 1, 1, 1, 1, 1,
0, 2, 0, 2, 2, 4, 4, 7, 9, 4,
4, 5, 7, 4, 4, 3, 4, 4, 4, 4,
4, 3, 3, 3, 3, 1, 2, 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, 1, 1, 1, 1, 1, 0, 2, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1
};
@ -1487,65 +1532,92 @@ yyreduce:
switch (yyn)
{
case 4:
#line 105 "cmFortranParser.y" /* yacc.c:1646 */
#line 106 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_SetInInterface(parser, true);
}
#line 1496 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1541 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 5:
#line 109 "cmFortranParser.y" /* yacc.c:1646 */
#line 110 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUse(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1506 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1551 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 6:
#line 114 "cmFortranParser.y" /* yacc.c:1646 */
#line 115 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
if (cmsysString_strcasecmp((yyvsp[-2].string), "function") != 0 &&
cmsysString_strcasecmp((yyvsp[-2].string), "procedure") != 0 &&
cmsysString_strcasecmp((yyvsp[-2].string), "subroutine") != 0) {
cmFortranParser_RuleModule(parser, (yyvsp[-2].string));
}
free((yyvsp[-2].string));
}
#line 1516 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1565 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 7:
#line 119 "cmFortranParser.y" /* yacc.c:1646 */
#line 124 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUse(parser, (yyvsp[-4].string));
free((yyvsp[-4].string));
free((yyvsp[-2].string));
}
#line 1576 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 8:
#line 130 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUse(parser, (yyvsp[-6].string));
free((yyvsp[-6].string));
free((yyvsp[-4].string));
free((yyvsp[-2].string));
}
#line 1588 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 9:
#line 137 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_SetInInterface(parser, true);
free((yyvsp[-2].string));
}
#line 1526 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1598 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 8:
#line 124 "cmFortranParser.y" /* yacc.c:1646 */
case 10:
#line 142 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_SetInInterface(parser, false);
}
#line 1535 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1607 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 9:
#line 128 "cmFortranParser.y" /* yacc.c:1646 */
case 11:
#line 146 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUse(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1545 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1617 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 10:
#line 133 "cmFortranParser.y" /* yacc.c:1646 */
case 12:
#line 151 "cmFortranParser.y" /* yacc.c:1646 */
{
if (cmsysString_strcasecmp((yyvsp[-4].string), "non_intrinsic") == 0) {
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
@ -1554,139 +1626,139 @@ yyreduce:
free((yyvsp[-4].string));
free((yyvsp[-2].string));
}
#line 1558 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1630 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 11:
#line 141 "cmFortranParser.y" /* yacc.c:1646 */
case 13:
#line 159 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleInclude(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1568 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1640 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 12:
#line 146 "cmFortranParser.y" /* yacc.c:1646 */
case 14:
#line 164 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleLineDirective(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1578 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 13:
#line 151 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleInclude(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1588 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 14:
#line 156 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleInclude(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1598 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1650 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 15:
#line 161 "cmFortranParser.y" /* yacc.c:1646 */
#line 169 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleInclude(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1660 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 16:
#line 174 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleInclude(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1670 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 17:
#line 179 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleDefine(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1608 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1680 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 16:
#line 166 "cmFortranParser.y" /* yacc.c:1646 */
case 18:
#line 184 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUndef(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1618 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1690 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 17:
#line 171 "cmFortranParser.y" /* yacc.c:1646 */
case 19:
#line 189 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleIfdef(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1628 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1700 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 18:
#line 176 "cmFortranParser.y" /* yacc.c:1646 */
case 20:
#line 194 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleIfndef(parser, (yyvsp[-2].string));
free((yyvsp[-2].string));
}
#line 1638 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1710 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 19:
#line 181 "cmFortranParser.y" /* yacc.c:1646 */
case 21:
#line 199 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleIf(parser);
}
#line 1647 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1719 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 20:
#line 185 "cmFortranParser.y" /* yacc.c:1646 */
case 22:
#line 203 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleElif(parser);
}
#line 1656 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1728 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 21:
#line 189 "cmFortranParser.y" /* yacc.c:1646 */
case 23:
#line 207 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleElse(parser);
}
#line 1665 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1737 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 22:
#line 193 "cmFortranParser.y" /* yacc.c:1646 */
case 24:
#line 211 "cmFortranParser.y" /* yacc.c:1646 */
{
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleEndif(parser);
}
#line 1674 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1746 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 46:
#line 215 "cmFortranParser.y" /* yacc.c:1646 */
case 48:
#line 233 "cmFortranParser.y" /* yacc.c:1646 */
{ free ((yyvsp[0].string)); }
#line 1680 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1752 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
case 52:
#line 221 "cmFortranParser.y" /* yacc.c:1646 */
case 55:
#line 240 "cmFortranParser.y" /* yacc.c:1646 */
{ free ((yyvsp[0].string)); }
#line 1686 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1758 "cmFortranParser.cxx" /* yacc.c:1646 */
break;
#line 1690 "cmFortranParser.cxx" /* yacc.c:1646 */
#line 1762 "cmFortranParser.cxx" /* yacc.c:1646 */
default: break;
}
/* User semantic actions sometimes alter yychar, and that requires
@ -1916,6 +1988,6 @@ yyreturn:
#endif
return yyresult;
}
#line 229 "cmFortranParser.y" /* yacc.c:1906 */
#line 251 "cmFortranParser.y" /* yacc.c:1906 */
/* End of grammar */

View File

@ -85,7 +85,7 @@ static void cmFortran_yyerror(yyscan_t yyscanner, const char* message)
%token CPP_IFDEF CPP_IFNDEF CPP_IF CPP_ELSE CPP_ELIF CPP_ENDIF
%token F90PPR_IFDEF F90PPR_IFNDEF F90PPR_IF
%token F90PPR_ELSE F90PPR_ELIF F90PPR_ENDIF
%token COMMA DCOLON
%token COMMA COLON DCOLON LPAREN RPAREN
%token <number> UNTERMINATED_STRING
%token <string> STRING WORD
%token <string> CPP_INCLUDE_ANGLE
@ -93,6 +93,7 @@ static void cmFortran_yyerror(yyscan_t yyscanner, const char* message)
%token INCLUDE
%token INTERFACE
%token MODULE
%token SUBMODULE
%token USE
/*-------------------------------------------------------------------------*/
@ -113,9 +114,26 @@ stmt:
}
| MODULE WORD other EOSTMT {
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
if (cmsysString_strcasecmp($2, "function") != 0 &&
cmsysString_strcasecmp($2, "procedure") != 0 &&
cmsysString_strcasecmp($2, "subroutine") != 0) {
cmFortranParser_RuleModule(parser, $2);
}
free($2);
}
| SUBMODULE LPAREN WORD RPAREN WORD other EOSTMT {
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUse(parser, $3);
free($3);
free($5);
}
| SUBMODULE LPAREN WORD COLON WORD RPAREN WORD other EOSTMT {
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_RuleUse(parser, $3);
free($3);
free($5);
free($7);
}
| INTERFACE WORD other EOSTMT {
cmFortranParser* parser = cmFortran_yyget_extra(yyscanner);
cmFortranParser_SetInInterface(parser, true);
@ -217,11 +235,15 @@ misc_code:
| INCLUDE
| INTERFACE
| MODULE
| SUBMODULE
| USE
| STRING { free ($1); }
| GARBAGE
| ASSIGNMENT_OP
| COLON
| DCOLON
| LPAREN
| RPAREN
| COMMA
| UNTERMINATED_STRING
;

View File

@ -69,16 +69,20 @@ extern int cmFortran_yydebug;
F90PPR_ELIF = 279,
F90PPR_ENDIF = 280,
COMMA = 281,
DCOLON = 282,
UNTERMINATED_STRING = 283,
STRING = 284,
WORD = 285,
CPP_INCLUDE_ANGLE = 286,
END = 287,
INCLUDE = 288,
INTERFACE = 289,
MODULE = 290,
USE = 291
COLON = 282,
DCOLON = 283,
LPAREN = 284,
RPAREN = 285,
UNTERMINATED_STRING = 286,
STRING = 287,
WORD = 288,
CPP_INCLUDE_ANGLE = 289,
END = 290,
INCLUDE = 291,
INTERFACE = 292,
MODULE = 293,
SUBMODULE = 294,
USE = 295
};
#endif
/* Tokens. */
@ -106,16 +110,20 @@ extern int cmFortran_yydebug;
#define F90PPR_ELIF 279
#define F90PPR_ENDIF 280
#define COMMA 281
#define DCOLON 282
#define UNTERMINATED_STRING 283
#define STRING 284
#define WORD 285
#define CPP_INCLUDE_ANGLE 286
#define END 287
#define INCLUDE 288
#define INTERFACE 289
#define MODULE 290
#define USE 291
#define COLON 282
#define DCOLON 283
#define LPAREN 284
#define RPAREN 285
#define UNTERMINATED_STRING 286
#define STRING 287
#define WORD 288
#define CPP_INCLUDE_ANGLE 289
#define END 290
#define INCLUDE 291
#define INTERFACE 292
#define MODULE 293
#define SUBMODULE 294
#define USE 295
/* Value type. */
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
@ -126,7 +134,7 @@ union YYSTYPE
char* string;
#line 130 "cmFortranParserTokens.h" /* yacc.c:1909 */
#line 138 "cmFortranParserTokens.h" /* yacc.c:1909 */
};
typedef union YYSTYPE YYSTYPE;