From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id mOFGCCtKHWaxTgEAe85BDQ:P1 (envelope-from ) for ; Mon, 15 Apr 2024 17:39:23 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id mOFGCCtKHWaxTgEAe85BDQ (envelope-from ) for ; Mon, 15 Apr 2024 17:39:23 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=A8fPfDUY; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1713195563; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=EXkmOYq5C91w+rjqInPiIAPtMC1u/Ul7/eM3xbS+R04=; b=HDk2A/3B3Ey7YRfPNGRZEcO5+ZKUdjlalHsuB625NX5QFM9VfkN7wRAIyIHFsTpX4EXxbQ FsqonoXvU4N4UTZVdN1bVOu/JERuxvMP7VyE0xOmNoMcmT1A8I/RgY2mCdgSBvLg9VvHJi ZClg82BgbGhUnadnmWXlfD4CcNIfq1bMtAuLyHemo4YW+IPO9mupWStoHL2GaHzTNGop1M +I/INjNKDe3fN9LWH1NrJmrDR1ymo4KzLbV+gnZM/1LQrau27V9qAt2mdFg4sqzgt4DrDg IJVjU/LDcaY/qiIkjdn3XLWgkjMCs9QxMXgd4ngrG6QV3wyg6MzitKIPMt16Vg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=A8fPfDUY; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1713195563; a=rsa-sha256; cv=none; b=lJVVBJg16snCj2WqJQz53UoezXF3W+l9XgH1Wd8P/l1S2FKA2RlwkompSfm8rLg9wJiW5B 7TuQqI6psmcnj/x1pard/MVdgu1KygUXkNrLOkkTJrEY5sv/ylCVtKRflXO3fVXaq7/Rjs Jt6tJL+E/AHJGpDaUlcuynybktr7TbnCyP1KH4i1rPzyeS8owZTYrKEttkxqvtCG9y2VZP 8X0ALt/xsm/ZcRnhg4gg4wyIkHz4v1TTIlizfcpmisOoIGbxGUZBDu/5+r989i+LzfUyWM 9PG7NPUbkIDvfgDIz61czJH94Yq70ow0KjUjancBwlEkv44NWC1DyM+VlEbqcA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 10602C087 for ; Mon, 15 Apr 2024 17:39:23 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rwOQ2-0006Hm-JV; Mon, 15 Apr 2024 11:38:54 -0400 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 1rwOQ0-0006HQ-SE for guix-patches@gnu.org; Mon, 15 Apr 2024 11:38:52 -0400 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 1rwOQ0-0001bP-Jh; Mon, 15 Apr 2024 11:38:52 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rwOQA-0007zn-Dt; Mon, 15 Apr 2024 11:39:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70398] [PATCH 1/5] records: Do not inline throws for ABI mismatches. Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 15 Apr 2024 15:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70398 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70398@debbugs.gnu.org Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?UTF-8?Q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?UTF-8?Q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70398-submit@debbugs.gnu.org id=B70398.171319549230315 (code B ref 70398); Mon, 15 Apr 2024 15:39:02 +0000 Received: (at 70398) by debbugs.gnu.org; 15 Apr 2024 15:38:12 +0000 Received: from localhost ([127.0.0.1]:37900 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rwOPI-0007s0-BG for submit@debbugs.gnu.org; Mon, 15 Apr 2024 11:38:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60108) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rwOPE-0007pw-TS for 70398@debbugs.gnu.org; Mon, 15 Apr 2024 11:38:06 -0400 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 1rwOOw-0001Tq-MX; Mon, 15 Apr 2024 11:37:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=EXkmOYq5C91w+rjqInPiIAPtMC1u/Ul7/eM3xbS+R04=; b=A8fPfDUYuwSzjAJXp8yN mdqlPMtnExmgwydCqqNrIVYH8JXBIzUnIjN69VbT0TcM6dpBQoZx8++b9j5Ny2j065jMbp4QOcchP JzBZBC3f8KuVx9xxg+mcobMSzQ3M+SYjQMx8tuU10tB1k03DSYi1jFeA9vbbGRQeyPmOXEhcniC5J A6DEVT9aOXgJs6koya+jiIXJTENq0r+ZC127FmVE1S/QNxuAPWX0CVAGvPgau6hVm+uff42Jvszc1 wUTjoK/kgwjBNlGuJyVST0e6siw2O7I95evtW5JIgNtf6TdS9wXiYngzAw1747KiFX4cbOenqcORV DFUuBbSwvdsgZA==; From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Date: Mon, 15 Apr 2024 17:37:03 +0200 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -3.07 X-Migadu-Scanner: mx11.migadu.com X-Spam-Score: -3.07 X-Migadu-Queue-Id: 10602C087 X-TUID: paTRtpHN6ZqP * guix/records.scm (record-abi-mismatch-error): New procedure. (abi-check): Use it. Change-Id: I49936599716e117b8fbf26fb9d8f462bbbb8e88b --- guix/records.scm | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/guix/records.scm b/guix/records.scm index f4d12a861d..48637ea0a4 100644 --- a/guix/records.scm +++ b/guix/records.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2023 Ludovic Courtès +;;; Copyright © 2012-2024 Ludovic Courtès ;;; Copyright © 2018 Mark H Weaver ;;; ;;; This file is part of GNU Guix. @@ -61,6 +61,11 @@ (define-syntax record-error (string-append "% " (symbol->string type-name) " abi-cookie"))))) + (define (record-abi-mismatch-error type) + (throw 'record-abi-mismatch-error 'abi-check + "~a: record ABI mismatch; recompilation needed" + (list type) '())) + (define (abi-check type cookie) "Return syntax that checks that the current \"application binary interface\" (ABI) for TYPE is equal to COOKIE." @@ -68,9 +73,7 @@ (define-syntax record-error #`(unless (eq? current-abi #,cookie) ;; The source file where this exception is thrown must be ;; recompiled. - (throw 'record-abi-mismatch-error 'abi-check - "~a: record ABI mismatch; recompilation needed" - (list #,type) '())))) + (record-abi-mismatch-error #,type)))) (define* (report-invalid-field-specifier name bindings #:optional parent-form) -- 2.41.0