このページを編集する際は,編集に関する方針に従ってください.[]
概要[]
引数[]
- void
実装[]
1329 /* Handle -D, -U, -A, -imacros, and the first -include. */
1330 static void
1331 finish_options (void)
1332 {
1333 if (!cpp_opts->preprocessed)
1334 {
1335 size_t i;
1336
1337 cb_file_change (parse_in,
1338 linemap_add (&line_table, LC_RENAME, 0,
1339 _("<built-in>"), 0));
1340
1341 cpp_init_builtins (parse_in, flag_hosted);
1342 c_cpp_builtins (parse_in);
1343
1344 /* We're about to send user input to cpplib, so make it warn for
1345 things that we previously (when we sent it internal definitions)
1346 told it to not warn.
1347
1348 C99 permits implementation-defined characters in identifiers.
1349 The documented meaning of -std= is to turn off extensions that
1350 conflict with the specified standard, and since a strictly
1351 conforming program cannot contain a '$', we do not condition
1352 their acceptance on the -std= setting. */
1353 cpp_opts->warn_dollars = (cpp_opts->pedantic && !cpp_opts->c99);
1354
1355 cpp_change_file (parse_in, LC_RENAME, _("<command line>"));
1356 for (i = 0; i < deferred_count; i++)
1357 {
1358 struct deferred_opt *opt = &deferred_opts[i];
1359
1360 if (opt->code == OPT_D)
1361 cpp_define (parse_in, opt->arg);
1362 else if (opt->code == OPT_U)
1363 cpp_undef (parse_in, opt->arg);
1364 else if (opt->code == OPT_A)
1365 {
1366 if (opt->arg[0] == '-')
1367 cpp_unassert (parse_in, opt->arg + 1);
1368 else
1369 cpp_assert (parse_in, opt->arg);
1370 }
1371 }
1372
1373 /* Handle -imacros after -D and -U. */
1374 for (i = 0; i < deferred_count; i++)
1375 {
1376 struct deferred_opt *opt = &deferred_opts[i];
1377
1378 if (opt->code == OPT_imacros
1379 && cpp_push_include (parse_in, opt->arg))
1380 {
1381 /* Disable push_command_line_include callback for now. */
1382 include_cursor = deferred_count + 1;
1383 cpp_scan_nooutput (parse_in);
1384 }
1385 }
1386 }
1387
1388 include_cursor = 0;
1389 push_command_line_include ();
1390 }