GNU bug report logs - #78375
daemon: Replace random_shuffle() with shuffle()

Previous Next

Package: guix-patches;

Reported by: Congcong Kuo <congcong.kuo <at> gmail.com>

Date: Sun, 11 May 2025 15:44:03 UTC

Severity: normal

Done: Ludovic Courtès <ludo <at> gnu.org>

To reply to this bug, email your comments to 78375 AT debbugs.gnu.org.
There is no need to reopen the bug first.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#78375; Package guix-patches. (Sun, 11 May 2025 15:44:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Congcong Kuo <congcong.kuo <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sun, 11 May 2025 15:44:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Congcong Kuo <congcong.kuo <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: daemon: Replace random_shuffle() with shuffle()
Date: Sun, 11 May 2025 17:24:02 +0800
[Message part 1 (text/plain, inline)]
Hello,

I am trying to build libstore using the Zig build system. The default C++ version of ‘zig c++’ is gnu++17 and random_shuffle() has been removed in C++ 14 standard.

Even though guix is built using gnu++11 currently, I think it is not harmful to replace a deprecated function.

Regards,
Kuo

[0001-Replace-random_shuffle-with-shuffle.patch (text/plain, attachment)]

Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Mon, 12 May 2025 08:55:07 GMT) Full text and rfc822 format available.

Notification sent to Congcong Kuo <congcong.kuo <at> gmail.com>:
bug acknowledged by developer. (Mon, 12 May 2025 08:55:07 GMT) Full text and rfc822 format available.

Message #10 received at 78375-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Congcong Kuo <congcong.kuo <at> gmail.com>
Cc: 78375-done <at> debbugs.gnu.org
Subject: Re: [bug#78375] daemon: Replace random_shuffle() with shuffle(),
 [PATCH] Replace random_shuffle with shuffle
Date: Mon, 12 May 2025 10:11:42 +0200
Hello,

Congcong Kuo <congcong.kuo <at> gmail.com> writes:

> I am trying to build libstore using the Zig build system. The default
> C++ version of ‘zig c++’ is gnu++17 and random_shuffle() has been
> removed in C++ 14 standard.
>
> Even though guix is built using gnu++11 currently, I think it is not harmful to replace a deprecated function.
>
> Regards,
> Kuo
>
> From fc7ccca0a1a58e16d1c4729b31bc477deddb308b Mon Sep 17 00:00:00 2001
> From: Congcong Kuo <congcong.kuo <at> gmail.com>
> Date: Sun, 11 May 2025 16:31:22 +0800
> Subject: [PATCH] Replace random_shuffle with shuffle
>
> ---
>  nix/libstore/gc.cc | 5 ++++-

I added a commit log following our conventions and applied it, thanks!

Ludo’.




This bug report was last modified 24 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.