File tree Expand file tree Collapse file tree 6 files changed +24
-5
lines changed
regression/goto-gcc/at_files Expand file tree Collapse file tree 6 files changed +24
-5
lines changed Original file line number Diff line number Diff line change 1+ other.c
Original file line number Diff line number Diff line change 1+ int foo ();
2+
3+ int main ()
4+ {
5+ return foo ();
6+ }
Original file line number Diff line number Diff line change 1+ int foo ()
2+ {
3+ return 1 ;
4+ }
Original file line number Diff line number Diff line change 1+ CORE
2+ main.c
3+ @args
4+ ^EXIT=0$
5+ ^SIGNAL=0$
6+ --
7+ ^warning: ignoring
8+ ^CONVERSION ERROR$
Original file line number Diff line number Diff line change @@ -252,7 +252,7 @@ bool gcc_cmdlinet::parse_arguments(
252252 line.erase (0 , line.find_first_not_of (" \t " ));
253253
254254 if (!line.empty ())
255- parse_specs_line (line);
255+ parse_specs_line (line, false );
256256 }
257257
258258 continue ;
@@ -428,7 +428,7 @@ bool gcc_cmdlinet::parse_arguments(
428428}
429429
430430// / Parse GCC spec files https://gcc.gnu.org/onlinedocs/gcc/Spec-Files.html
431- void gcc_cmdlinet::parse_specs_line (const std::string &line)
431+ void gcc_cmdlinet::parse_specs_line (const std::string &line, bool in_spec_file )
432432{
433433 // initial whitespace has been stripped
434434 assert (!line.empty ());
@@ -444,7 +444,7 @@ void gcc_cmdlinet::parse_specs_line(const std::string &line)
444444 args.push_back (line.substr (arg_start, arg_end-arg_start));
445445 }
446446
447- parse_arguments (args, true );
447+ parse_arguments (args, in_spec_file );
448448}
449449
450450// / Parse GCC spec files https://gcc.gnu.org/onlinedocs/gcc/Spec-Files.html
@@ -473,7 +473,7 @@ void gcc_cmdlinet::parse_specs()
473473 line==" *link:" ))
474474 use_line=true ;
475475 else if (use_line)
476- parse_specs_line (line);
476+ parse_specs_line (line, true );
477477 else
478478 {
479479 // TODO need message interface
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ class gcc_cmdlinet:public goto_cc_cmdlinet
3131
3232 bool parse_arguments (const argst &args, bool in_spec_file);
3333 void parse_specs ();
34- void parse_specs_line (const std::string &line);
34+ void parse_specs_line (const std::string &line, bool in_spec_file );
3535};
3636
3737#endif // CPROVER_GOTO_CC_GCC_CMDLINE_H
You can’t perform that action at this time.
0 commit comments