diff options
author | Richard Biener <rguenther@suse.de> | 2017-02-17 10:19:21 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2017-02-17 10:19:21 +0000 |
commit | c265c2dd6f4f18d94d001b68faee1ac7ee1280cb (patch) | |
tree | 08f205bec15b79460bddda72d439d3279273644e /gcc | |
parent | 5bf69d74abbf3b0971b9dae37b804ff685e7298c (diff) | |
download | gcc-c265c2dd6f4f18d94d001b68faee1ac7ee1280cb.zip gcc-c265c2dd6f4f18d94d001b68faee1ac7ee1280cb.tar.gz gcc-c265c2dd6f4f18d94d001b68faee1ac7ee1280cb.tar.bz2 |
re PR bootstrap/79567 (Compiler-warning "unknown escape sequence '\x'" about genmatch-generated C-files on mingw-host)
2017-02-17 Richard Biener <rguenther@suse.de>
PR bootstrap/79567
* genmatch.c (output_line_directive): Handle DIR_SEPARATOR_2.
From-SVN: r245527
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/genmatch.c | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index b7d0d8e..96ae59a 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2017-02-17 Richard Biener <rguenther@suse.de> + + PR bootstrap/79567 + * genmatch.c (output_line_directive): Handle DIR_SEPARATOR_2. + 2017-02-17 Marek Polacek <polacek@redhat.com> PR middle-end/79536 diff --git a/gcc/genmatch.c b/gcc/genmatch.c index c163ded..fdf5aaf 100644 --- a/gcc/genmatch.c +++ b/gcc/genmatch.c @@ -192,6 +192,11 @@ output_line_directive (FILE *f, source_location location, { /* When writing to a dumpfile only dump the filename. */ const char *file = strrchr (loc.file, DIR_SEPARATOR); +#if defined(DIR_SEPARATOR_2) + const char *pos2 = strrchr (loc.file, DIR_SEPARATOR_2); + if (pos2 && (!file || (pos2 > file))) + file = pos2; +#endif if (!file) file = loc.file; else |