File tree 2 files changed +12
-7
lines changed
regression/goto-gcc/at_files
2 files changed +12
-7
lines changed Original file line number Diff line number Diff line change
1
+ -o
2
+ test.gb
1
3
other.c
Original file line number Diff line number Diff line change @@ -12,8 +12,9 @@ Author: CM Wintersteiger, 2006
12
12
#include " gcc_cmdline.h"
13
13
14
14
#include < cstring>
15
- #include < iostream>
16
15
#include < fstream>
16
+ #include < iostream>
17
+ #include < sstream>
17
18
18
19
#include < util/prefix.h>
19
20
@@ -256,16 +257,18 @@ bool gcc_cmdlinet::parse_arguments(
256
257
if (has_prefix (argv_i, " @" ))
257
258
{
258
259
std::ifstream opts_file (argv_i.substr (1 ));
260
+ std::ostringstream all_lines;
259
261
std::string line;
260
262
261
263
while (std::getline (opts_file, line))
262
- {
263
- // erase leading whitespace
264
- line.erase (0 , line.find_first_not_of (" \t " ));
264
+ all_lines << ' ' << line;
265
265
266
- if (!line.empty ())
267
- parse_specs_line (line, false );
268
- }
266
+ line = all_lines.str ();
267
+ // erase leading whitespace
268
+ line.erase (0 , line.find_first_not_of (" \t " ));
269
+
270
+ if (!line.empty ())
271
+ parse_specs_line (line, false );
269
272
270
273
continue ;
271
274
}
You can’t perform that action at this time.
0 commit comments