From unknown Mon Aug 18 08:26:21 2025 X-Loop: help-debbugs@gnu.org Subject: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" Resent-From: Kisaragi Hiu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 09 Jan 2024 12:33:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 68345 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 68345@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.170480356221199 (code B ref -1); Tue, 09 Jan 2024 12:33:01 +0000 Received: (at submit) by debbugs.gnu.org; 9 Jan 2024 12:32:42 +0000 Received: from localhost ([127.0.0.1]:38596 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNBHe-0005Vr-B9 for submit@debbugs.gnu.org; Tue, 09 Jan 2024 07:32:42 -0500 Received: from lists.gnu.org ([2001:470:142::17]:43968) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNBHb-0005Vf-Jw for submit@debbugs.gnu.org; Tue, 09 Jan 2024 07:32:40 -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 1rNBHO-0000gO-0n for bug-gnu-emacs@gnu.org; Tue, 09 Jan 2024 07:32:27 -0500 Received: from out-186.mta1.migadu.com ([2001:41d0:203:375::ba]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rNBHI-0003Xf-6p for bug-gnu-emacs@gnu.org; Tue, 09 Jan 2024 07:32:25 -0500 Message-ID: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kisaragi-hiu.com; s=key1; t=1704803532; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=V8LsgcJmhL/nsnzMZVP/FqvTw7+Y/vJN8QfmMRZiTL4=; b=eU9jemz5PIIFJGA70ouj9dJyRr/fcVUpvJRpWBJ4A/IpWz2bejb6byEQup1bmdHvYWKyQt wUjc87/hNYjAvdMCI7g3bL0aFeJVzunsU1tIb0jexMpFp+g8chAgWI06K/DcT1T+P953L8 jIdTQZiIOlVNy8LgLdAJgaLq8XkwUi1uYT4Z6TWOUCDHSax1cTL60ejsCKE88IUy87nn7N UVAcPRRPi/oNbfkijcnm3R/LrbqVIzQvDNaP/JF90B1xkfFdfu8Kf878NhaVzJbOCv3YqG V4TlVff3pdWee8YtDD6aVI4lTxiDyBOtxkb7poG0Fj1DFMCfF8GOK7kgjFX/pw== Date: Tue, 9 Jan 2024 21:32:06 +0900 MIME-Version: 1.0 Content-Language: en-US X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kisaragi Hiu Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_OUT Received-SPF: pass client-ip=2001:41d0:203:375::ba; envelope-from=mail@kisaragi-hiu.com; helo=out-186.mta1.migadu.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.1 (/) * The problem If a struct is defined to have a slot called "quote", the constructor will fail during the compiler macro phase. (require 'cl-lib) (cl-defstruct my-test quote) (make-my-test :quote "'") ; error: (invalid-function "'") (put 'make-my-test 'compiler-macro nil) ; disable the compiler macro (make-my-test :quote "'") ; => #s(test "'") I have tested Emacs 25.3, 26.3, 27.2, 28.2, and 29.1; this error is in all these versions. * Why this is a bug This feels like a bug to me, because it's not clear that this would be an unsupported use case, and because of the inconsistent behavior between the constructor being inlined vs. without a compiler macro. * Potential directions This could be "fixed" by either digging into cl-defstruct and cl-lib then fixing it properly, or by simply declaring in the documentation that this is not supported. I wish for a proper fix, but the documentation workaround also seems fine to me. * Additional info This is what the compiler macro for make-my-test expands into: (cl-block make-my-test (record ("'" my-test) "'")) In GNU Emacs 29.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.17.8) Windowing system distributor 'The X.Org Foundation', version 11.0.12101010 System Description: Arch Linux From unknown Mon Aug 18 08:26:21 2025 X-Loop: help-debbugs@gnu.org Subject: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 09 Jan 2024 14:21:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68345 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Kisaragi Hiu , Stefan Monnier Cc: 68345@debbugs.gnu.org Received: via spool by 68345-submit@debbugs.gnu.org id=B68345.17048100024700 (code B ref 68345); Tue, 09 Jan 2024 14:21:02 +0000 Received: (at 68345) by debbugs.gnu.org; 9 Jan 2024 14:20:02 +0000 Received: from localhost ([127.0.0.1]:38822 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNCxW-0001Dj-2b for submit@debbugs.gnu.org; Tue, 09 Jan 2024 09:20:02 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:48116) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNCxU-0001D6-AO for 68345@debbugs.gnu.org; Tue, 09 Jan 2024 09:20:00 -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 1rNCxH-0005aO-7n; Tue, 09 Jan 2024 09:19:47 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=R5/ZfdFY1dLID8S53g8/CRqy7+kSXuo1vI6AOSY4v9A=; b=ogjgC3utJJiw NkTBb8s3WIMFtlF3K53DDTfgSmyYrBaYovFQ7vqF25ziaDVoquyjHXgTuUqyMO//kMJoi+psyKj32 2/5ZgFF8ohuVqBcArVglc5Qt0klhqHw34aizsQg7HKwD9yBnkXmWg2jXO1YlOhn9qn6C3DMF9GIGe 6FqOAQTuqiNdt7ZOJDpx8TGEpjB9P7Q53DWVgaUYbHHUfMJpncOfZ+MhNJQkAptBcaZ5WYqGq7uGs xF5vxExAwGvmGNEbWxxg3rsE3M+s8YQTtoZ3AmN7sLEoklqlc0FooP1x+WW/iDj8zUNs8U5nyAfX3 FznCtCMDrFbxk0p/XCAqFQ==; Date: Tue, 09 Jan 2024 16:19:27 +0200 Message-Id: <83h6jmpp1s.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> (bug-gnu-emacs@gnu.org) References: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Tue, 9 Jan 2024 21:32:06 +0900 > From: Kisaragi Hiu via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > * The problem > > If a struct is defined to have a slot called "quote", the constructor > will fail during the compiler macro phase. > > (require 'cl-lib) > (cl-defstruct my-test quote) > (make-my-test :quote "'") ; error: (invalid-function "'") 'quote' is a documented special form in Emacs, see the node "Quoting" in the ELisp manual. Adding Stefan to the discussion. From unknown Mon Aug 18 08:26:21 2025 X-Loop: help-debbugs@gnu.org Subject: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" Resent-From: Gerd =?UTF-8?Q?M=C3=B6llmann?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 09 Jan 2024 15:00:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68345 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 68345@debbugs.gnu.org Cc: mail@kisaragi-hiu.com X-Debbugs-Original-To: Kisaragi Hiu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" X-Debbugs-Original-Cc: Kisaragi Hiu , 68345@debbugs.gnu.org Received: via spool by submit@debbugs.gnu.org id=B.170481236430494 (code B ref -1); Tue, 09 Jan 2024 15:00:01 +0000 Received: (at submit) by debbugs.gnu.org; 9 Jan 2024 14:59:24 +0000 Received: from localhost ([127.0.0.1]:40677 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNDZc-0007vm-1f for submit@debbugs.gnu.org; Tue, 09 Jan 2024 09:59:24 -0500 Received: from lists.gnu.org ([2001:470:142::17]:32940) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNDZY-0007vM-St for submit@debbugs.gnu.org; Tue, 09 Jan 2024 09:59: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 1rNDZM-0004HL-IJ for bug-gnu-emacs@gnu.org; Tue, 09 Jan 2024 09:59:08 -0500 Received: from mail-ed1-x52e.google.com ([2a00:1450:4864:20::52e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rNDZK-0007W7-Tv for bug-gnu-emacs@gnu.org; Tue, 09 Jan 2024 09:59:08 -0500 Received: by mail-ed1-x52e.google.com with SMTP id 4fb4d7f45d1cf-5582796b85bso346433a12.2 for ; Tue, 09 Jan 2024 06:59:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1704812345; x=1705417145; darn=gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=N7RpChHW4+Sdq7dS0WKgH7O2yA/KAGU9dx0x932IkU8=; b=XuUXmx79QhbBoLSwr0mr674RPBo7xXnb+OFn9Yp8AWdP+CvaXrvv6/nPk50cYZiibT fcG9rpUr18pbDRFxiJSMIS9j+YyYO4tPxGgaNdpzHOCfaUeY3JeYnCfz2PZv4onlQ1tF r0ThIXX5N4CYwtNtoCFC3ZugpzQzbkY5GEIwx4tm0j9JL7iBSoaaPgVsxBS+8e0mWuZS vY6XjX9VzWcX/07+Nor4LMD3Rn/LmygIdb4jO3+EjQurz+3ddFe4+2xq7dvFzg9xAizg sGzoY8qw5cEdOiAzTCZRoX2qsRj8ugzrLCgu1n+z1tHuj3yUTVBB7ZPUrz6GP8bk5qIB OXsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704812345; x=1705417145; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=N7RpChHW4+Sdq7dS0WKgH7O2yA/KAGU9dx0x932IkU8=; b=n7s3jn/Tp2uAjMYgabnUzhjATcmDLUitVCH2mXOnt1AIHjmPPTnj1B0VC73MuLGcdt BqUwIv0xxNE79csdlIotsmJe2f+kArSv7oHlfmJyu1r3JDTNx5oqB77mqok+F5Uzxjci udD4kGmgQCaTnVIe3RnJWiTewxk3uE29kfMN2gO1bMUZp2rXZIWJ2K0OlApSu06jNCJQ RJ5ufWp1oddoOe06yP83PapJN7HnwpPLCWcoyrwIGTE0J1w3VJ95eUyP4QUbbrAKPwDZ 2o1+EgrLLhm3JjkpNjIfGuM7LtLiNPNNFiDOXwKN7ga2I/EwlxagYK4vWO7Mda/xwbQ+ RgYA== X-Gm-Message-State: AOJu0YwEgCdhQps0gjg28Fz4A6z6UAnUa+zjcp/oFd/tHMELam/CseDw n6yWFRAeU/IFieBrxf9myAs= X-Google-Smtp-Source: AGHT+IH7026pOFc/tqVgmp5LZqNs8FIzrCKIjTtJYqE+DxjijStm15XcN2GoNQBnNH7hCtzE8BK+ng== X-Received: by 2002:a17:906:3e0f:b0:a27:ef87:3f00 with SMTP id k15-20020a1709063e0f00b00a27ef873f00mr468056eji.26.1704812344612; Tue, 09 Jan 2024 06:59:04 -0800 (PST) Received: from Pro.fritz.box (pd9e36353.dip0.t-ipconnect.de. [217.227.99.83]) by smtp.gmail.com with ESMTPSA id j11-20020a170906430b00b00a2b3bb73b83sm934382ejm.94.2024.01.09.06.59.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jan 2024 06:59:04 -0800 (PST) From: Gerd =?UTF-8?Q?M=C3=B6llmann?= In-Reply-To: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> (Kisaragi Hiu via's message of "Tue, 9 Jan 2024 21:32:06 +0900") References: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> Date: Tue, 09 Jan 2024 15:59:03 +0100 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2a00:1450:4864:20::52e; envelope-from=gerd.moellmann@gmail.com; helo=mail-ed1-x52e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) Kisaragi Hiu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" writes: > * The problem > > If a struct is defined to have a slot called "quote", the constructor > will fail during the compiler macro phase. > > (require 'cl-lib) > (cl-defstruct my-test quote) > (make-my-test :quote "'") ; error: (invalid-function "'") > > (put 'make-my-test 'compiler-macro nil) ; disable the compiler macro > (make-my-test :quote "'") ; => #s(test "'") > > I have tested Emacs 25.3, 26.3, 27.2, 28.2, and 29.1; this error is in > all these versions. Could you please check with Emacs/master? Seems to work there. From unknown Mon Aug 18 08:26:21 2025 X-Loop: help-debbugs@gnu.org Subject: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" Resent-From: Kisaragi Hiu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 09 Jan 2024 22:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68345 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Gerd =?UTF-8?Q?M=C3=B6llmann?= Cc: 68345@debbugs.gnu.org Received: via spool by 68345-submit@debbugs.gnu.org id=B68345.170484043911986 (code B ref 68345); Tue, 09 Jan 2024 22:48:02 +0000 Received: (at 68345) by debbugs.gnu.org; 9 Jan 2024 22:47:19 +0000 Received: from localhost ([127.0.0.1]:41229 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNKsR-00037F-0W for submit@debbugs.gnu.org; Tue, 09 Jan 2024 17:47:19 -0500 Received: from out-187.mta0.migadu.com ([91.218.175.187]:28599) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNKsM-000371-UC for 68345@debbugs.gnu.org; Tue, 09 Jan 2024 17:47:18 -0500 Message-ID: <680e4901-a6cc-490a-907b-3ca5c29b915a@kisaragi-hiu.com> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kisaragi-hiu.com; s=key1; t=1704840425; h=from:from: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: in-reply-to:in-reply-to:references:references; bh=UaVFczeDA/pNjrXGHigdHBUBkImkga6UTXt1ivbFgf8=; b=XHak5zNaa5EeVchMUT+K8viX7FioQ4Oup3De/8KBS4byD6YQJ/OOlt8eq3WdivFSHhvvBe HrTe7xBWxusivt+d4womUJBcg0prbbqphA4mb/dEvncI48d/oT9yGbLMSq3kuiUMObb+8Y vfEP6DGejm4jHWu3PuPLR9clztQEjZI3UOksFehrtUtaCSsYEiqZTJhlqeuVmFCFsUbHMP VyJ8CIFVXaWEpIAou8HcYTg2YYWke31FWAo1TObycm/wRe/RpVFsJ6fVeXGTLwVZqU9qNu 83vmdLa4nZ5rhHmLO5hCNPNvf+JMmIzjpOFWTEgOLOZzXbhtPF6InP7kb/LUYg== Date: Wed, 10 Jan 2024 07:46:56 +0900 MIME-Version: 1.0 References: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> Content-Language: en-US X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kisaragi Hiu In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2024/01/09 23:59, Gerd Möllmann wrote: > Could you please check with Emacs/master? Seems to work there. It works as I'd expect at master (commit fccaeabc959f5403ce49744030bd2620352b59f8), without errors. I should've checked master before filing this report - sorry about that. I might run a bisect later to see how it was fixed, but this appears to no longer be an issue. From unknown Mon Aug 18 08:26:21 2025 X-Loop: help-debbugs@gnu.org Subject: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" Resent-From: Gerd =?UTF-8?Q?M=C3=B6llmann?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 10 Jan 2024 05:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68345 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Kisaragi Hiu Cc: 68345@debbugs.gnu.org Received: via spool by 68345-submit@debbugs.gnu.org id=B68345.17048648421235 (code B ref 68345); Wed, 10 Jan 2024 05:35:01 +0000 Received: (at 68345) by debbugs.gnu.org; 10 Jan 2024 05:34:02 +0000 Received: from localhost ([127.0.0.1]:41587 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNRE2-0000Jr-3m for submit@debbugs.gnu.org; Wed, 10 Jan 2024 00:34:02 -0500 Received: from mail-ej1-x62e.google.com ([2a00:1450:4864:20::62e]:57704) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNRE0-0000JK-39 for 68345@debbugs.gnu.org; Wed, 10 Jan 2024 00:34:00 -0500 Received: by mail-ej1-x62e.google.com with SMTP id a640c23a62f3a-a29a4f610b1so383359666b.3 for <68345@debbugs.gnu.org>; Tue, 09 Jan 2024 21:33:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1704864827; x=1705469627; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ic382RQnvoCDuBD+4ScZ1v9tqB85uCAnDGp6r8+VNxA=; b=Z9V+e5LAEcwjqGtM1162oCJzy4UDWv1soOVH4v0HrQOtc8yC0jpmCCkjO8cg17mQds T/1ZVihajEj1LQDEPUKaLd1L/DLgqlf8jbxI4xt/cb+JCnuwHLQHeQU/Py4Uiq0Fzu2W ST9jCmGVsgwgfo05MNmZiROFatE8LXIUC1TrnAT/7Wq5yAw9KchFvBkAR1DqmdjkZJkg zm4DljPLRegKTARaxlZdeXK7S/+gA/ZCU+bGC6bJT+fdylSA5Qa3eX/BqVOfVRfU4k5E LuP43RI1JVle7gDhKKdykeebV1AH+es04g0HBdz8RiSzYyA10vOmejLib/4LCM088iUx Lk6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704864827; x=1705469627; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=ic382RQnvoCDuBD+4ScZ1v9tqB85uCAnDGp6r8+VNxA=; b=M+DnGug5/c/3NscGwjC/SMEUw6zhCuF1PhJ9ISk1+PWy7Y0+PkYQs/kGtW0REEDduA l+kixrU95WP3bsIsMnBmQNKsKe562orhIWyikzkNfjDiD5UUGLRBeAo45chiRgeZ+Vju 8/EUbz7w9tcknsQhK0kl1R6/Kitx0qGJbMtrtxkdQWmEEc862GQQZN/vVzgntRFuWnFc fOPOQGux+mHLy8grQg2A49epoLL6UfWoT+59Xsr9uMg9C+1mDLDWUkTUY+RFDhCxhK7t MBAyV4sadSPTEzglNc7mRbqg3iG4PWDnoh3m4ksP3mczVSLf2pwNhsnzSV5jxP6McQXm I7MQ== X-Gm-Message-State: AOJu0YwL1w+7dmcdPeeHFqmCPV/hDh97TC8ni6iYFpG38wew5Rx/qaaq xHd7r4ObegZvfmoDOUXwPAr3iYTD2/A= X-Google-Smtp-Source: AGHT+IGquVKHADXCu9OyC3UYENetaquUAjv1VehdrtBT81Mg6AXA/1emBuK1XMO0lpYiHDSLgGz5CA== X-Received: by 2002:a17:906:c47:b0:a28:a806:2144 with SMTP id t7-20020a1709060c4700b00a28a8062144mr257984ejf.110.1704864826537; Tue, 09 Jan 2024 21:33:46 -0800 (PST) Received: from Pro.fritz.box (pd9e3627e.dip0.t-ipconnect.de. [217.227.98.126]) by smtp.gmail.com with ESMTPSA id 14-20020a170906318e00b00a2be17645c2sm120898ejy.197.2024.01.09.21.33.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jan 2024 21:33:46 -0800 (PST) From: Gerd =?UTF-8?Q?M=C3=B6llmann?= In-Reply-To: <680e4901-a6cc-490a-907b-3ca5c29b915a@kisaragi-hiu.com> (Kisaragi Hiu's message of "Wed, 10 Jan 2024 07:46:56 +0900") References: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> <680e4901-a6cc-490a-907b-3ca5c29b915a@kisaragi-hiu.com> Date: Wed, 10 Jan 2024 06:33:44 +0100 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Kisaragi Hiu writes: > On 2024/01/09 23:59, Gerd M=C3=B6llmann wrote: >> Could you please check with Emacs/master? Seems to work there. > > It works as I'd expect at master (commit > fccaeabc959f5403ce49744030bd2620352b59f8), without errors. I should've > checked master before filing this report - sorry about that. No problem, and thanks for testing! > > I might run a bisect later to see how it was fixed, but this appears > to no longer be an issue. From unknown Mon Aug 18 08:26:21 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Kisaragi Hiu Subject: bug#68345: closed (Re: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote") Message-ID: References: <83bk9tnyai.fsf@gnu.org> <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> X-Gnu-PR-Message: they-closed 68345 X-Gnu-PR-Package: emacs Reply-To: 68345@debbugs.gnu.org Date: Wed, 10 Jan 2024 13:48:05 +0000 Content-Type: multipart/mixed; boundary="----------=_1704894485-11710-1" This is a multi-part message in MIME format... ------------=_1704894485-11710-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler= macro if a slot is called "quote" which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 68345@debbugs.gnu.org. --=20 68345: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D68345 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1704894485-11710-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 68345-done) by debbugs.gnu.org; 10 Jan 2024 13:47:35 +0000 Received: from localhost ([127.0.0.1]:39213 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNYve-0002xY-Q8 for submit@debbugs.gnu.org; Wed, 10 Jan 2024 08:47:35 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:54278) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNYvc-0002ww-1L for 68345-done@debbugs.gnu.org; Wed, 10 Jan 2024 08:47:32 -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 1rNY7d-0004rk-VF; Wed, 10 Jan 2024 07:55:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=baEHPtuvse4cj9qvvUoehuKAAjklQfNsRxWLsD0a4Ko=; b=amFoey72WbmUYHNNJcm8 shP5VaNO2UwWDAlafJoKtNEHLuco5/eiDlSlkFbcXEfMTXzdDUqZuRMpoxVrwaaZGyaH+ehKx0sie Anz8K8J2JESZeRq6whB4Ame5GbOwJ8Zc8MneMUjPMIm7YWOzXE99saD2E7bkO6IL9IFkr4TSYlcDl mPt18tUguX+7lCIUmk3H9SHwqK1hiT/d0JbUt3ilg/+tj7owUlzL4/QsGnYKLlJLeUoNn62AWGBVm QWO1Wq7GOEz5/JCg580X1owMGkqMS1iKZW5xjfDGEeGY0UeJh9W0Bi1Vy63jQlIiLwZKadVb+Ltvs RVpZUMlJR+a1Pw==; Date: Wed, 10 Jan 2024 14:55:01 +0200 Message-Id: <83bk9tnyai.fsf@gnu.org> From: Eli Zaretskii To: Kisaragi Hiu In-Reply-To: <680e4901-a6cc-490a-907b-3ca5c29b915a@kisaragi-hiu.com> (bug-gnu-emacs@gnu.org) Subject: Re: bug#68345: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" References: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> <680e4901-a6cc-490a-907b-3ca5c29b915a@kisaragi-hiu.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 68345-done Cc: gerd.moellmann@gmail.com, 68345-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Cc: 68345@debbugs.gnu.org > Date: Wed, 10 Jan 2024 07:46:56 +0900 > From: Kisaragi Hiu via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > On 2024/01/09 23:59, Gerd Möllmann wrote: > > Could you please check with Emacs/master? Seems to work there. > > It works as I'd expect at master (commit > fccaeabc959f5403ce49744030bd2620352b59f8), without errors. I should've > checked master before filing this report - sorry about that. > > I might run a bisect later to see how it was fixed, but this appears to > no longer be an issue. Thanks, closing. ------------=_1704894485-11710-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 9 Jan 2024 12:32:42 +0000 Received: from localhost ([127.0.0.1]:38596 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNBHe-0005Vr-B9 for submit@debbugs.gnu.org; Tue, 09 Jan 2024 07:32:42 -0500 Received: from lists.gnu.org ([2001:470:142::17]:43968) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rNBHb-0005Vf-Jw for submit@debbugs.gnu.org; Tue, 09 Jan 2024 07:32:40 -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 1rNBHO-0000gO-0n for bug-gnu-emacs@gnu.org; Tue, 09 Jan 2024 07:32:27 -0500 Received: from out-186.mta1.migadu.com ([2001:41d0:203:375::ba]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rNBHI-0003Xf-6p for bug-gnu-emacs@gnu.org; Tue, 09 Jan 2024 07:32:25 -0500 Message-ID: <05766552-b1d9-44b6-99fb-6f13c4601746@kisaragi-hiu.com> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kisaragi-hiu.com; s=key1; t=1704803532; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=V8LsgcJmhL/nsnzMZVP/FqvTw7+Y/vJN8QfmMRZiTL4=; b=eU9jemz5PIIFJGA70ouj9dJyRr/fcVUpvJRpWBJ4A/IpWz2bejb6byEQup1bmdHvYWKyQt wUjc87/hNYjAvdMCI7g3bL0aFeJVzunsU1tIb0jexMpFp+g8chAgWI06K/DcT1T+P953L8 jIdTQZiIOlVNy8LgLdAJgaLq8XkwUi1uYT4Z6TWOUCDHSax1cTL60ejsCKE88IUy87nn7N UVAcPRRPi/oNbfkijcnm3R/LrbqVIzQvDNaP/JF90B1xkfFdfu8Kf878NhaVzJbOCv3YqG V4TlVff3pdWee8YtDD6aVI4lTxiDyBOtxkb7poG0Fj1DFMCfF8GOK7kgjFX/pw== Date: Tue, 9 Jan 2024 21:32:06 +0900 MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org Subject: 29.1; cl-defstruct'ed struct errors out in the constructor compiler macro if a slot is called "quote" Content-Language: en-US X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kisaragi Hiu Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_OUT Received-SPF: pass client-ip=2001:41d0:203:375::ba; envelope-from=mail@kisaragi-hiu.com; helo=out-186.mta1.migadu.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.1 (/) * The problem If a struct is defined to have a slot called "quote", the constructor will fail during the compiler macro phase. (require 'cl-lib) (cl-defstruct my-test quote) (make-my-test :quote "'") ; error: (invalid-function "'") (put 'make-my-test 'compiler-macro nil) ; disable the compiler macro (make-my-test :quote "'") ; => #s(test "'") I have tested Emacs 25.3, 26.3, 27.2, 28.2, and 29.1; this error is in all these versions. * Why this is a bug This feels like a bug to me, because it's not clear that this would be an unsupported use case, and because of the inconsistent behavior between the constructor being inlined vs. without a compiler macro. * Potential directions This could be "fixed" by either digging into cl-defstruct and cl-lib then fixing it properly, or by simply declaring in the documentation that this is not supported. I wish for a proper fix, but the documentation workaround also seems fine to me. * Additional info This is what the compiler macro for make-my-test expands into: (cl-block make-my-test (record ("'" my-test) "'")) In GNU Emacs 29.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.17.8) Windowing system distributor 'The X.Org Foundation', version 11.0.12101010 System Description: Arch Linux ------------=_1704894485-11710-1--