From patchwork Tue Mar 4 22:09:59 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: 39697 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 EB18B27BBE2; Tue, 4 Mar 2025 22:21:13 +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 6EEA427BBEA for ; Tue, 4 Mar 2025 22:21:13 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tpaac-0006pC-SH; Tue, 04 Mar 2025 17:18:15 -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 1tpaZq-0005Su-7b for guix-patches@gnu.org; Tue, 04 Mar 2025 17:17:31 -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 1tpaZT-0003Sg-5P for guix-patches@gnu.org; Tue, 04 Mar 2025 17:17: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=YMotZ5yw2bsD6ZlXIt+WADEpfqqchu3gKKSUKhg5BoIKlzvPn6rZl9z/AVMoncBVseJLJ6YPI4Nk2KohDJaA940UzrO2FqNCdlkxXHLu108b44fofCAabs3lySY9fOw43BBfPs6Wg0xYbiqKSvjCNABGCy69ZjNJxGVq+jJsoRHG+Co09pRp6WCboooOjGh2ixwVeO4kUxpOoTAUJ7t3G/im0Wm1TWN9aM+hTJDRWhDzR0o6Ie+ILOLH95TdExgA9cWCMe1os5lBmMizrdeQ1rXhZ8XfXonBfYPxaaPezqkOP5xczWUCOX6fU7/P8TuCgaSaWxZaBxF9pUhAR+U2ag==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tpaZS-0003gT-Vy for guix-patches@gnu.org; Tue, 04 Mar 2025 17:17:03 -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:17: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.174112657514069 (code B ref 76485); Tue, 04 Mar 2025 22:17:02 +0000 Received: (at 76485) by debbugs.gnu.org; 4 Mar 2025 22:16:15 +0000 Received: from localhost ([127.0.0.1]:33379 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tpaYh-0003eo-3r for submit@debbugs.gnu.org; Tue, 04 Mar 2025 17:16:15 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44710) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tpaYP-0003d7-4O for 76485@debbugs.gnu.org; Tue, 04 Mar 2025 17:15:59 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tpaYJ-0002Gy-0P; Tue, 04 Mar 2025 17:15:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=PAjbOj+rX+fDAHImZzv+cKBc+Wjp4+JmxJq3faQW9/Y=; b=qP/hVDzJZvxcJw0OoyDH P7spxf55rou+Qhi/fn6VmSampkWZWUoPozp6uZ4AABcT/6RladHWnLYpei/9kpKRpJbCBESg6yaZB yZsPU87WqHYlgGV83h/unC6OsYAMWEMec8WHmDZSuQ+TjBKqj+txlkxmHZKEAQOzW9eLp+V9MdEJ+ e9vcM/6aOdGox+0vK+amDMzw742v5KVkJyuFItDCFTl4yTa0SgOr1zM+M4b9x160ddwgCkAIjIYuP Wyt6tpoMp+tNvhoZBU0eXArU2TuSDom07LFPP4CRvzzYz0OLbITtCa+qC9Vb4cUhvT5Mrv4j9Zqps 2z6Tme4YtiQ9/g==; 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:09:59 +0100 Message-ID: <87wmd48n2g.fsf@gnu.org> MIME-Version: 1.0 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