From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Robert Weiner Newsgroups: gmane.emacs.devel Subject: funcall of load-read-function (default nil) in elisp--eval-defun Date: Fri, 1 Dec 2023 11:47:35 +0000 Message-ID: Reply-To: rswgnu@gmail.com Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000297ab7060b715791" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29392"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Dec 01 12:48:43 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 1r920g-0007V9-Oj for ged-emacs-devel@m.gmane-mx.org; Fri, 01 Dec 2023 12:48:42 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r9204-00072Y-S0; Fri, 01 Dec 2023 06:48:04 -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 1r9202-00072P-T9 for emacs-devel@gnu.org; Fri, 01 Dec 2023 06:48:03 -0500 Original-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 1r9202-0001zl-L1 for emacs-devel@gnu.org; Fri, 01 Dec 2023 06:48:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=To:Subject:Date:From:MIME-Version:in-reply-to: references; bh=q5XbFpq0ODka54wNFKc6qaEvFbgdlUKmRt2OK1bE+2k=; b=g9I8IrY7lSIG61 N0dPKhWBOfZt3SQBwBNE3uBU9+jw80VoU1Z0m1ldkWBcLCW6SFC/VoKNh/jmXf/DC/3IDjjh4FTiv ArAABvG5ldizuQhgON6uR+/jsy6sVsudYIEjx4p2qm2WR6efCZU3mxKoLn4B49M1fJYTP4a43riWS Ud/TBkKUtmWNI+9VnlGsViXTBIkGfz3xhVsnAMImlvUQ8l9SF4z01kZyP8irSwpMLAuhJHrFlw0Nh 72ZrFnw5pIKfxi8VZZv7JkD9U7dpy29qk5tpzJHMWRVvHRdiLO4g0M9r3h1uXNxCfSbL885P0p2hY g++I13GfjKyT9e0VEhbw==; X-Gm-Message-State: AOJu0YzSDCjc9N0ZVAgFt80ua6ahV0hNFjI1MQMSfWsnTpj+fQYkphqU jHV4O7yQUEj5N4J9pDYRnWW6v6ocZuNnoBzwdKY= X-Google-Smtp-Source: AGHT+IG6CI3BQCQBBoGBBXyesTb1GPn+WeBt/uwL1YmgjXzOu/Wzd+43lc0hh+jZli/JLRQB03xVagObQmDMKuyJOVk= X-Received: by 2002:ac5:cac8:0:b0:4b2:9b85:55c8 with SMTP id m8-20020ac5cac8000000b004b29b8555c8mr5225596vkl.1.1701431281807; Fri, 01 Dec 2023 03:48:01 -0800 (PST) X-Gmail-Original-Message-ID: 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:313436 Archived-At: --000000000000297ab7060b715791 Content-Type: text/plain; charset="UTF-8" I see this line in elisp--eval-defun at least Emacs 28 - 30 (pre-release): (setq form (funcall load-read-function (current-buffer))) The default for load-read-function is nil, so it can't be called as a function by default. The value for me is indeed nil and is triggering an error for me when trying to evaluate an ert-deftest expression. How does this work? I don't see the value of load-read-function set anywhere else in elisp-mode.el. I see it set in debug.el and edebug.el but not when doing a normal defun eval. Thanks, rsw --000000000000297ab7060b715791 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I see this line in elisp--eval-defun at least Emacs 28 - 30 (p= re-release):

=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (setq form (funcall = load-read-function (current-buffer)))

The default for load-read-func= tion is nil, so it can't be called as a function by default.=C2=A0 The = value for me is indeed nil and is triggering an error for me when trying to= evaluate an ert-deftest expression.

How does this work?=C2=A0 I= don't see the value of load-read-function set anywhere else in elisp-m= ode.el.=C2=A0 I see it set in debug.el and edebug.el but not when doing a n= ormal defun eval.

Thanks,

rsw=C2=A0
--000000000000297ab7060b715791--