diff options
author | manu <manu@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-11-05 22:17:22 +0000 |
---|---|---|
committer | manu <manu@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-11-05 22:17:22 +0000 |
commit | 1d715999fd04ec367e51fdfafdd76f7702cf9338 (patch) | |
tree | 8249e806b1ac70a853b9112a20e3ef9a27d08c1f /gcc/toplev.c | |
parent | e774b0057b43a56560e7611b5c851fe32813fa31 (diff) | |
download | gcc-1d715999fd04ec367e51fdfafdd76f7702cf9338.tar.gz |
Revert revision 217149 because it breaks Ada:
gcc/testsuite/ChangeLog:
2014-11-05 Anthony Brandon <anthony.brandon@gmail.com>
PR driver/36312
* gcc.misc-tests/output.exp: New test case for identical input and
output files.
include/ChangeLog:
2014-11-05 Anthony Brandon <anthony.brandon@gmail.com>
PR driver/36312
* filenames.h: Add prototype for canonical_filename_eq.
gcc/ChangeLog:
2014-11-05 Anthony Brandon <anthony.brandon@gmail.com>
PR driver/36312
* diagnostic-core.h: Add prototype for fatal_error.
* diagnostic.c (fatal_error): New function fatal_error.
* gcc.c (store_arg): Remove have_o_argbuf_index.
(process_command): Check if input and output files are the same.
* toplev.c (init_asm_output): Check if input and output files are
the same.
libiberty/ChangeLog:
2014-11-05 Anthony Brandon <anthony.brandon@gmail.com>
PR driver/36312
* filename_cmp.c (canonical_filename_eq): New function to check if
file names are the same.
* functions.texi: Updated with documentation for new function.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@217159 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/toplev.c')
-rw-r--r-- | gcc/toplev.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/gcc/toplev.c b/gcc/toplev.c index d3bd35c11ec..9c75dd8e39e 100644 --- a/gcc/toplev.c +++ b/gcc/toplev.c @@ -942,17 +942,10 @@ init_asm_output (const char *name) } if (!strcmp (asm_file_name, "-")) asm_out_file = stdout; - else if (!canonical_filename_eq (asm_file_name, name)) - asm_out_file = fopen (asm_file_name, "w"); else - /* Use fatal_error (UNKOWN_LOCATION) instead of just fatal_error to - prevent gcc from printing the first line in the current file. */ - fatal_error (UNKNOWN_LOCATION, - "output file %s is the same as input file", - asm_file_name); + asm_out_file = fopen (asm_file_name, "w"); if (asm_out_file == 0) - fatal_error (UNKNOWN_LOCATION, - "can%'t open %s for writing: %m", asm_file_name); + fatal_error ("can%'t open %s for writing: %m", asm_file_name); } if (!flag_syntax_only) |