From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?Gerd_M=C3=B6llmann?= Newsgroups: gmane.emacs.devel Subject: Re: Attaching context info to an error Date: Fri, 22 Dec 2023 07:50:35 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23968"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Dec 22 07:51:50 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rGZNu-00062e-Ee for ged-emacs-devel@m.gmane-mx.org; Fri, 22 Dec 2023 07:51:50 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rGZMy-0002l4-6x; Fri, 22 Dec 2023 01:50:52 -0500 Original-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 1rGZMq-0002km-3h for emacs-devel@gnu.org; Fri, 22 Dec 2023 01:50:44 -0500 Original-Received: from mail-lf1-x136.google.com ([2a00:1450:4864:20::136]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rGZMl-0006FT-RA for emacs-devel@gnu.org; Fri, 22 Dec 2023 01:50:42 -0500 Original-Received: by mail-lf1-x136.google.com with SMTP id 2adb3069b0e04-50e6a806e4aso170116e87.1 for ; Thu, 21 Dec 2023 22:50:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1703227837; x=1703832637; 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=ScLgXbLiGAVa/FwKe1WtYYwKKIHpROG1BSdLxNpzGqE=; b=cdGWkT7xHusCKBVyKp5krXXpCR9R7GMCFRWi9ZzrC7+EnNc4NtG5G5vUdBY78hoP7C HZzJYvngD9hUxnJYxDGGYwu2iAFyp6yK0VsRxKlYf/h63yismEHfVmiPUGFV9eubogjs X9wRqqXxLP9FXCphZO+zEoVmW4iXiVT9AHEqAAmR0oA4DNT00TV2pQKz58Y3MmlMDPxv Oa6W/AA7xYMD12YcjcUSq/CP7aamIhK/9na9/8Guh2MhIQOv4PK6mpPYTN1X8UgylcHL j8jrd1pBGD4kh3VV6lA8B4pQnihvB2g/tnh9zxgHZI15kZM4uFIyHSKcW0deCz+kS3xH yXmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703227837; x=1703832637; 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=ScLgXbLiGAVa/FwKe1WtYYwKKIHpROG1BSdLxNpzGqE=; b=pmUdIoLYHzidK/SuA+JRJvmVyGF8ZAsTawKSUKYdt2ZoHJNwdXLM+Rs+RBWRQhCRwc m6uN9NTvguQIPuKYvZQrGJo7iQ4Tim2BrHs6eeMUDlGlNoKSjfqwbEd/3+8FB4pBJGMh Uz3uX8j5rt4G1u0AGHy2w262BFcRKcRFZZ8ChW874bU+o8p88UQjNu7uJng858QYcU6o yH0bizBRYY+P40rVkQefc7VGBaHZ6EQRt+dc8SbaD32zD9nHotDakGZKG1KvikjkvtSs sE96GfKwfiI489dvc/y9ki3rcwKXJaWl0RO2tqKiMWIruyZdZPP80drEFHFLPCzbzLej woEQ== X-Gm-Message-State: AOJu0Yyth4V2p/ZExukvGLd1WBFY5HKp9ugaGMSWkpyR754U1tibUuTs FruUhaEcOXT7NAKoWWYNr0/geGFZN9o= X-Google-Smtp-Source: AGHT+IG3zPbW83yBaHK28JgdwNPNlx9eU6eoHoE6FCT25oY2DHIGdgAKtsIBz5uhjgRkSep4O1yypw== X-Received: by 2002:ac2:4d12:0:b0:50d:f93b:97a9 with SMTP id r18-20020ac24d12000000b0050df93b97a9mr344975lfi.1.1703227836579; Thu, 21 Dec 2023 22:50:36 -0800 (PST) Original-Received: from Pro.fritz.box (p4fe3adc6.dip0.t-ipconnect.de. [79.227.173.198]) by smtp.gmail.com with ESMTPSA id o15-20020aa7d3cf000000b00553a094dd5csm2169965edr.32.2023.12.21.22.50.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Dec 2023 22:50:36 -0800 (PST) In-Reply-To: (Stefan Monnier's message of "Thu, 21 Dec 2023 17:30:24 -0500") Received-SPF: pass client-ip=2a00:1450:4864:20::136; envelope-from=gerd.moellmann@gmail.com; helo=mail-lf1-x136.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-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:314052 Archived-At: Stefan Monnier writes: > The question is: where should we put this "context" info. > > One possibility is to do something like the following: > > > (defun load (file ...) > (handler-bind ((error (lambda (err) > (signal 'error-during-load > (cons file err))))) > ...)) I'm just guessing - so the argument ERR of the handler function is not a `condition' object of some kind, in the CL sense? What is it? Or can I look myself somewhere? > ... > Any other idea how/where we could attach that info? I don't have a good idea either, I'm afraid.