public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jakub Jelinek <jakub@redhat.com>
To: LIU Hao <lh_mouse@126.com>
Cc: "gcc-rust@gcc.gnu.org" <gcc@gcc.gnu.org>
Subject: Re: [PATCH] Fix rust on *-w64-mingw32
Date: Thu, 25 Apr 2024 13:19:22 +0200	[thread overview]
Message-ID: <Zio8OirpCUcVuLvM@tucnak> (raw)
In-Reply-To: <79bd7ab5-b908-400d-b0a6-1faf1193bc61@126.com>

On Thu, Apr 25, 2024 at 07:16:31PM +0800, LIU Hao via Gcc wrote:
> --- a/gcc/rust/parse/rust-parse.cc
> +++ b/gcc/rust/parse/rust-parse.cc
> @@ -89,7 +89,7 @@ extract_module_path (const AST::AttrVec &inner_attrs,
>    // Source: rustc compiler
>    // (https://github.com/rust-lang/rust/blob/9863bf51a52b8e61bcad312f81b5193d53099f9f/compiler/rustc_expand/src/module.rs#L174)
>  #if defined(HAVE_DOS_BASED_FILE_SYSTEM)
> -  path.replace ('/', '\\');
> +  std::replace(path.begin(), path.end(), '/', '\\');

This should be
  std::replace (path.begin (), path.end (), '/', '\\');
(at least if gcc/rust/ follows normal GCC coding conventions).

	Jakub


  reply	other threads:[~2024-04-25 11:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-25 11:16 LIU Hao
2024-04-25 11:19 ` Jakub Jelinek [this message]
2024-04-26 10:47 ` Arthur Cohen
2024-04-26 11:14   ` LIU Hao
2024-04-27 15:57     ` LIU Hao

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=Zio8OirpCUcVuLvM@tucnak \
    --to=jakub@redhat.com \
    --cc=gcc@gcc.gnu.org \
    --cc=lh_mouse@126.com \
    /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).