From patchwork Tue Mar 4 22:13:38 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 39696 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 811B127BBE2; Tue, 4 Mar 2025 22:20:58 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-8.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL, RCVD_IN_VALIDITY_SAFE,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id DE3BE27BBE9 for ; Tue, 4 Mar 2025 22:20:56 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tpaai-00074j-KI; Tue, 04 Mar 2025 17:18:22 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tpaYW-0004mw-4B for guix-patches@gnu.org; Tue, 04 Mar 2025 17:16:05 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tpaYV-0002Z7-Kr for guix-patches@gnu.org; Tue, 04 Mar 2025 17:16:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=PAjbOj+rX+fDAHImZzv+cKBc+Wjp4+JmxJq3faQW9/Y=; b=A/eTqRJtpUxLVPic6nQs2D+LnhWiJDFIAzhSoRCp0bybdiV86OaelDPUahEV9xIrPrCf2KiX7D+TfTcsZtI+LbxAXmJLZ3t1KJ5ryreU+6CTzsGs629KaHxOc7ISPYD4ilvFxii34I8xmX6Xt7HMellrohygeFOfFDvi56gNOoMzbuFHAzXy340krN9Un1FfPcn+q/75qLKuVRWOZMJFCxPp6ETgKHq8PL24AN0n4JH9BYceS5ShpyAzjxvfchR1YQbMjbmA2csVo4MnSd2n834XQzin/qZxNeDhC79h+vip/lu+63NHbdkCZRzxVquStPiIvnZEfOGxbra0T/WAfg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tpaYU-0003dw-Cx for guix-patches@gnu.org; Tue, 04 Mar 2025 17:16:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#76485] [PATCH v2] gexp: =?utf-8?b?4oCYd2l0aC1wYXJhbWV0ZXJz4oCZ?= properly handles =?utf-8?b?4oCYJWdyYWZ0P+KAmS4=?= Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 04 Mar 2025 22:16:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76485 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: David Elsing Cc: 76485@debbugs.gnu.org Received: via spool by 76485-submit@debbugs.gnu.org id=B76485.174112654113935 (code B ref 76485); Tue, 04 Mar 2025 22:16:02 +0000 Received: (at 76485) by debbugs.gnu.org; 4 Mar 2025 22:15:41 +0000 Received: from localhost ([127.0.0.1]:33361 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tpaY5-0003cT-7f for submit@debbugs.gnu.org; Tue, 04 Mar 2025 17:15:40 -0500 Received: from hera.aquilenet.fr ([185.233.100.1]:59570) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tpaWN-0003Sc-9c for 76485@debbugs.gnu.org; Tue, 04 Mar 2025 17:13:53 -0500 Received: from localhost (localhost [127.0.0.1]) by hera.aquilenet.fr (Postfix) with ESMTP id 94018614; Tue, 4 Mar 2025 23:13:41 +0100 (CET) Authentication-Results: hera.aquilenet.fr; none X-Virus-Scanned: Debian amavis at hera.aquilenet.fr Received: from hera.aquilenet.fr ([127.0.0.1]) by localhost (hera.aquilenet.fr [127.0.0.1]) (amavis, port 10024) with ESMTP id XqZbh8zh4W8T; Tue, 4 Mar 2025 23:13:41 +0100 (CET) Received: from ribbon (91-160-117-201.subs.proxad.net [91.160.117.201]) by hera.aquilenet.fr (Postfix) with ESMTPSA id 839CE186; Tue, 4 Mar 2025 23:13:39 +0100 (CET) From: Ludovic =?utf-8?q?Court=C3=A8s?= In-Reply-To: <20250304203337.2628-1-david.elsing@posteo.net> (David Elsing's message of "Tue, 4 Mar 2025 20:33:08 +0000") References: <868qpky1uc.fsf@posteo.net> <20250304203337.2628-1-david.elsing@posteo.net> User-Agent: Gnus/5.13 (Gnus v5.13) Date: Tue, 04 Mar 2025 23:13:38 +0100 Message-ID: <87sens8mwd.fsf@gnu.org> MIME-Version: 1.0 X-Rspamd-Server: hera X-Rspamd-Queue-Id: 94018614 X-Spamd-Result: default: False [5.90 / 15.00]; SPAM_FLAG(5.00)[]; BAYES_HAM(-3.00)[100.00%]; NEURAL_SPAM(3.00)[1.000]; CTYPE_MIXED_BOGUS(1.00)[]; MIME_GOOD(-0.10)[multipart/mixed,text/plain,text/x-patch]; RCPT_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:+]; RCVD_COUNT_TWO(0.00)[2]; ARC_NA(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; SUBJECT_HAS_QUESTION(0.00)[] X-Spamd-Bar: +++++ X-Rspamd-Action: greylist X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches Hello, David Elsing skribis: > Fixes . > > * .dir-locals.el (scheme-mode): Remove mparameterize indentation rules. > Add state-parameterize and store-parameterize indentation rules. > * etc/manifests/system-tests.scm (test-for-current-guix): Replace > mparameterize with store-parameterize. > * etc/manifests/time-travel.scm (guix-instance-compiler): Likewise. > * gnu/tests.scm (compile-system-test): Likewise. > * guix/gexp.scm (compile-parameterized): Use state-call-with-parameters. > * guix/monads.scm (mparameterize): Remove macro. > (state-call-with-parameters): New procedure. > (state-parameterize): New macro. > * guix/store.scm (store-parameterize): New macro. > * tests/gexp.scm ("with-parameters for %graft?"): New test. > * tests/monads.scm ("mparameterize"): Remove test. > ("state-parameterize"): New test. > > Co-authored-by: Ludovic Courtès Applied with the change below, in accordance with the deprecation policy. Thank you! Ludo’. PS: Let me know if I got the copyright line wrong. diff --git a/guix/monads.scm b/guix/monads.scm index 0df82bb4653..e1b056dc95f 100644 --- a/guix/monads.scm +++ b/guix/monads.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2013, 2014, 2015, 2017, 2022 Ludovic Courtès +;;; Copyright © 2013-2015, 2017, 2022, 2025 Ludovic Courtès +;;; Copyright © 2025 David Elsing ;;; ;;; This file is part of GNU Guix. ;;; @@ -19,6 +20,7 @@ (define-module (guix monads) #:use-module ((system syntax) #:select (syntax-local-binding)) + #:autoload (guix deprecation) (warn-about-deprecation) #:use-module (ice-9 match) #:use-module (srfi srfi-1) #:use-module (srfi srfi-9) @@ -58,7 +60,8 @@ (define-module (guix monads) state-push state-pop run-with-state - state-parameterize)) + state-parameterize + mparameterize)) ;;; Commentary: ;;; @@ -618,4 +621,15 @@ (define-syntax state-parameterize (lambda () (mbegin %state-monad body ...)))))))) +(define-syntax mparameterize ;can be removed after 2026-03-05 + (lambda (s) + "This is the old form for 'state-parameterize', which pretended to work +with any monad but was in fact specialized for '%state-monad'." + (syntax-case s () + ((_ monad bindings body ...) + (begin + (warn-about-deprecation 'mparameterize (current-source-location) + #:replacement 'state-parameterize) + #'(state-parameterize bindings body ...)))))) + ;;; monads.scm end here