compiler: Pass location to fatal_error.

The GCC function is changing.

The error functions need to move to a compiler-indepent
approach so that changes to the GCC functions are not a
concern here.

From-SVN: r220292
This commit is contained in:
Ian Lance Taylor 2015-01-30 16:04:58 +00:00
parent b4d216f6e2
commit 4811c44ee0
1 changed files with 2 additions and 1 deletions

View File

@ -63,7 +63,8 @@ go_parse_input_files(const char** filenames, unsigned int filename_count,
{
file = fopen(filename, "r");
if (file == NULL)
fatal_error("cannot open %s: %m", filename);
fatal_error(Linemap::unknown_location(),
"cannot open %s: %m", filename);
}
Lex lexer(filename, file, ::gogo->linemap());