From: Jeff Law <law@redhat.com>
To: David Malcolm <dmalcolm@redhat.com>, gcc-patches@gcc.gnu.org
Subject: Re: [PATCH] PR bootstrap/71481: fix input.c selftest
Date: Mon, 13 Jun 2016 18:19:00 -0000 [thread overview]
Message-ID: <ba4582b9-8e99-112b-72fd-f6bd3c51d922@redhat.com> (raw)
In-Reply-To: <1465509519-4165-1-git-send-email-dmalcolm@redhat.com>
On 06/09/2016 03:58 PM, David Malcolm wrote:
> input.c's selftest::test_reading_source_line attempted to read from
> __FILE__, which doesn't work if the binary is run from a different
> location than the build dir.
>
> Fix it by rewriting the test to write out a tempfile, and read from
> that, rather than from __FILE__.
>
> I used make_temp_file to create the name for the temporary file, on
> the grounds that that's what the driver uses for that purpose.
>
> This is on top of the patch kit posted as:
> https://gcc.gnu.org/ml/gcc-patches/2016-06/msg00735.html
>
> Successfully bootstrapped®retested on x86_64-pc-linux-gnu
> Successful -fself-test of stage1 on powerpc-ibm-aix7.1.3.0
>
> OK for trunk?
>
> gcc/ChangeLog:
> PR bootstrap/71481
> * input.c (selftest::test_reading_source_line): Avoid reading from
> __FILE__ by creating a tempfile with known content and reading
> from that instead.
OK.
FWIW, I think the LANG_C vs translating is your call to make. I can see
arguments for both directions.
Jeff
prev parent reply other threads:[~2016-06-13 18:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-09 21:32 David Malcolm
2016-06-10 11:32 ` Richard Biener
2016-06-13 18:19 ` Jeff Law [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ba4582b9-8e99-112b-72fd-f6bd3c51d922@redhat.com \
--to=law@redhat.com \
--cc=dmalcolm@redhat.com \
--cc=gcc-patches@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).