From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Tom Tromey Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 18 Sep 2014 02:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 18494@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.141100625629219 (code B ref -1); Thu, 18 Sep 2014 02:11:02 +0000 Received: (at submit) by debbugs.gnu.org; 18 Sep 2014 02:10:56 +0000 Received: from localhost ([127.0.0.1]:43774 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XURBO-0007bB-Lh for submit@debbugs.gnu.org; Wed, 17 Sep 2014 22:10:55 -0400 Received: from eggs.gnu.org ([208.118.235.92]:37121) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XURBK-0007az-0K for submit@debbugs.gnu.org; Wed, 17 Sep 2014 22:10:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XURBB-00074B-Jo for submit@debbugs.gnu.org; Wed, 17 Sep 2014 22:10:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:32912) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XURBB-00073u-G4 for submit@debbugs.gnu.org; Wed, 17 Sep 2014 22:10:41 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38841) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XURAz-0001Rc-2Z for bug-gnu-emacs@gnu.org; Wed, 17 Sep 2014 22:10:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XURAr-00072B-TR for bug-gnu-emacs@gnu.org; Wed, 17 Sep 2014 22:10:29 -0400 Received: from gproxy1-pub.mail.unifiedlayer.com ([69.89.25.95]:55866) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1XURAr-00071Q-GS for bug-gnu-emacs@gnu.org; Wed, 17 Sep 2014 22:10:21 -0400 Received: (qmail 8532 invoked by uid 0); 18 Sep 2014 02:10:10 -0000 Received: from unknown (HELO CMOut01) (10.0.90.82) by gproxy1.mail.unifiedlayer.com with SMTP; 18 Sep 2014 02:10:10 -0000 Received: from box522.bluehost.com ([74.220.219.122]) by CMOut01 with id sSA01o00Z2f2jeq01SA38k; Wed, 17 Sep 2014 20:10:09 -0600 X-Authority-Analysis: v=2.1 cv=LbyvtFvi c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=cNaOj0WVAAAA:8 a=f5113yIGAAAA:8 a=7J-OVuP3IrkA:10 a=xJdpGxRiYX4A:10 a=_cZRQKYwz3QA:10 a=zstS-IiYAAAA:8 a=PnD2wP_eR3oA:10 a=oMhZhQ4-4PIA:10 a=TT-zNVmkb8RpYOAR8dMA:9 a=me8ytBHFh7DrWKHJ:21 a=2ao6vZfoZWcI3Q2f:21 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From; bh=G0sBNI8XHQMqxgNTBG8d6yiOv1hHUYetFc8Om4nTOTs=; b=djb6B0p9Kb0BInqRE47V8GWurSIERnqtKot+3w6kib2WIajRbM4JWBRQ03haGs2yQ1+PCinP4/88p6n8LH2DrATBiaxjD2Ho7M5xQh5YYib81q+1I4C3K+jDjZrPSHYV; Received: from [71.33.141.119] (port=34157 helo=bapiya) by box522.bluehost.com with esmtpsa (TLSv1.2:AES128-GCM-SHA256:128) (Exim 4.82) (envelope-from ) id 1XURAX-00083D-CH; Wed, 17 Sep 2014 20:10:01 -0600 From: Tom Tromey X-Attribution: Tom Date: Wed, 17 Sep 2014 20:09:57 -0600 Message-ID: <87a95xvfuy.fsf@tromey.com> MIME-Version: 1.0 Content-Type: text/plain X-Identified-User: {36111:box522.bluehost.com:elynrobi:tromey.com} {sentby:smtp auth 71.33.141.119 authed with tom+tromey.com} X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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: -5.0 (-----) Try: (defclass zzz-whatever () ((hi))) Now notice there is a new function: (symbol-function 'zzz-whatever-list-p) (lambda (obj) "Test OBJ to see if it a list of objects which are a child of type zzz-whatever" (when (listp obj) (let ((ans t)) (while (and obj ans) (setq ans (and (eieio-object-p (car obj)) (object-of-class-p (car obj) zzz-whatever))) (setq obj (cdr obj))) ans))) This new -list-p function is not documented in the EIEIO manual. It seems to me that it would be a bit better not to define it. It doesn't seem generally useful enough, to me. However, if it is kept, it ought to be documented. In GNU Emacs 24.4.50.8 (x86_64-unknown-linux-gnu, GTK+ Version 3.10.9) of 2014-09-15 on bapiya Repository revision: 117884 dancol@dancol.org-20140915050944-sqsajysnwef51f9m Windowing system distributor `Fedora Project', version 11.0.11404000 Configured using: `configure --prefix=/home/tromey/Emacs/install' Configured features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GCONF GSETTINGS NOTIFY LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=none locale-coding-system: utf-8-unix Major mode: Group Minor modes in effect: gnus-topic-mode: t gnus-undo-mode: t diff-auto-refine-mode: t which-function-mode: t global-auto-revert-mode: t desktop-save-mode: t erc-services-mode: t erc-list-mode: t erc-menu-mode: t erc-autojoin-mode: t erc-ring-mode: t erc-networks-mode: t erc-pcomplete-mode: t erc-track-mode: t erc-match-mode: t erc-button-mode: t erc-fill-mode: t erc-stamp-mode: t erc-netsplit-mode: t erc-irccontrols-mode: t erc-noncommands-mode: t erc-move-to-prompt-mode: t erc-readonly-mode: t savehist-mode: t tooltip-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t buffer-read-only: t column-number-mode: t line-number-mode: t Recent input: n C-h f e c l l c o m p - - b a s l i C-g M-< C-h C-g C-u C-SPC C-h C-g C-x b C-g C-g C-g C-x b , C-/ C-h C-g C-v C-h f e c l i p e l c o m p - - s e t - l i s t C-x 1 C-l M-{ C-f C-M-f C-M-f C-f C-v M-} C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-z n C-z n C-a C-n C-n C-s e l C-w C-w C-w C-s C-a C-z n M-v M-v z n C-x C-g C-/ C-z n C-x b C-f M-v M-v M-v M-v M-> ; ; ; C-l C-a C-k C-q C-l ( d e f u n SPC e c l C-t o m p - - c o m p u t e - d o m i n a n c e - f r o n t i e r C-z n C-x b e l c o m M-< C-u C-u C-n C-u C-u C-n C-p C-p C-v C-u C-n C-u C-n C-n C-n C-n C-n C-u C-p C-u C-p C-l C-z n C-z n C-SPC C-a C-p C-p C-p C-w C-f C-x C-s C-x s C-c r C-u C-n p SPC q SPC q C-v C-u C-n C-u C-n p C-l C-u C-p C-u C-p n SPC 8 SPC SPC SPC = n k SPC n C-z n C-h f M-p M-p C-z n C-z n C-x b * C-g C-z n C-z n C-x 1 C-z n n n q s y M-x r e p o r t - e m Recent messages: Saving file /home/tromey/DotEmacs/.bbdb... Wrote /home/tromey/DotEmacs/.bbdb Saving Gnus registry (857 entries) to ~/.gnus.registry.eioio... Saving Gnus registry (size 857) to ~/.gnus.registry.eioio...done Saving file /home/tromey/.newsrc... Wrote /home/tromey/.newsrc Saving /home/tromey/.newsrc.eld... Saving file /home/tromey/.newsrc.eld... Wrote /home/tromey/.newsrc.eld Saving /home/tromey/.newsrc.eld...done Load-path shadows: /home/tromey/.emacs.d/elpa/css-mode-1.0/css-mode hides /home/tromey/Emacs/install/share/emacs/24.4.50/lisp/textmodes/css-mode /home/tromey/.emacs.d/elpa/bubbles-0.5/bubbles hides /home/tromey/Emacs/install/share/emacs/24.4.50/lisp/play/bubbles Features: (shadow emacsbug log-view cus-edit tar-mode bbdb-sc supercite regi debug cl-macs eieio-opt speedbar sb-image ezimage dframe help-mode dabbrev log-edit pcvs-util copyright url-http url-gw url-auth url-queue mailalias misearch multi-isearch mail-hist nnir find-file gnus-fun gnus-html xml url-cache mm-url url url-proxy url-privacy url-expand url-methods url-history url-cookie url-domsuf url-util url-parse url-vars shr-color color shr browse-url bbdb-gui bbdb-hooks mule-util sort smiley gnus-cite flow-fill mm-archive gnus-async gnus-bcklg qp gnus-ml disp-table gnus-topic nndraft nnmh nnfolder utf-7 bbdb-gnus bbdb-snarf mail-extr bbdb-com warnings cl gv gnutls network-stream starttls gnus-agent gnus-srvr gnus-score score-mode nnvirtual gnus-msg nntp gnus-cache gnus-registry registry eieio-base gnus-art mm-uu mml2015 epg-config mm-view mml-smime smime dig mailcap gnus-sum gnus-group gnus-undo smtpmail sendmail gnus-start gnus-cloud nnimap nnmail mail-source tls utf7 netrc nnoo parse-time gnus-spec gnus-int gnus-range message rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev gmm-utils mailheader gnus-win gnus gnus-ems nnheader mail-utils tcl autoconf autoconf-mode make-mode smerge-mode diff-mode goto-addr python js json vc-arch vc-mtn vc-hg vc-bzr vc-sccs vc-svn vc-cvs vc-rcs bug-reference cc-mode cc-fonts cc-guess cc-menus cc-cmds org-element org-rmail org-mhe org-irc org-info org-gnus org-docview doc-view jka-compr image-mode dired org-bibtex bibtex org-bbdb org-w3m org org-macro org-footnote org-pcomplete org-list org-faces org-entities noutline outline easy-mmode org-version ob-emacs-lisp ob ob-tangle org-src ob-ref ob-lob ob-table ob-keys ob-exp ob-comint ob-core ob-eval org-compat org-macs org-loaddefs vc-git add-log flyspell ispell eldoc diminish projectile edmacro kmacro pkg-info find-func lisp-mnt epl grep compile dash s appt diary-lib diary-loaddefs cal-menu calendar cal-loaddefs which-func imenu minimap autorevert filenotify desktop frameset cus-start cus-load status erc-services erc-list erc-menu erc-join erc-ring erc-networks erc-pcomplete pcomplete erc-track erc-match erc-button wid-edit cl-loaddefs cl-lib erc-fill erc-stamp erc-netsplit erc-goodies erc erc-backend erc-compat format-spec auth-source eieio byte-opt bytecomp byte-compile cconv eieio-core gnus-util mm-util mail-prsvr password-cache thingatpt pp advice help-fns vc-dir ewoc vc vc-dispatcher cc-styles cc-align cc-engine cc-vars cc-defs bbdb timezone ange-ftp comint ansi-color ring server savehist dwarf-mode-autoloads gdb-shell-autoloads jabber-autoloads lisppaste-autoloads pydoc-info-autoloads info-look info easymenu weblogger-autoloads package bbdb-autoloads time-date tooltip electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment lisp-mode prog-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process dbusbind gfilenotify dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs) Memory information: ((conses 16 989562 137419) (symbols 48 105520 6) (miscs 40 40605 3713) (strings 32 330874 35484) (string-bytes 1 14735697) (vectors 16 96901) (vector-slots 8 2164002 205204) (floats 8 554 830) (intervals 56 50349 2797) (buffers 976 308) (heap 1024 288009 55648)) Tom From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: David Engster Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 20 Sep 2014 10:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Tom Tromey Cc: 18494@debbugs.gnu.org, Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.141120970823433 (code B ref 18494); Sat, 20 Sep 2014 10:42:02 +0000 Received: (at 18494) by debbugs.gnu.org; 20 Sep 2014 10:41:48 +0000 Received: from localhost ([127.0.0.1]:46411 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVI6t-00065t-9w for submit@debbugs.gnu.org; Sat, 20 Sep 2014 06:41:47 -0400 Received: from randomsample.de ([5.45.97.173]:37432) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVI6p-00065f-0P for 18494@debbugs.gnu.org; Sat, 20 Sep 2014 06:41:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=k074HnPT+TdJhm+eA2EwH6KU/G7n+lqyNb6fQfgkHjM=; b=IeIHqGgyB2BEExHV0NUiYA8LEugGAmeNi2JRzE+6csifhR6ApB9cAWgQSzCuBqWsxCLFWlihQqeg6ttyA7D1PfpczvHh7vT6miLGfYY2AtyRfbX3YCLnn8JfiHXa3pDV; Received: from dslc-082-082-164-097.pools.arcor-ip.net ([82.82.164.97] helo=desk) by randomsample.de with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from ) id 1XVI6j-0003sn-BB; Sat, 20 Sep 2014 12:41:40 +0200 From: David Engster In-Reply-To: <87a95xvfuy.fsf@tromey.com> (Tom Tromey's message of "Wed, 17 Sep 2014 20:09:57 -0600") References: <87a95xvfuy.fsf@tromey.com> User-Agent: Gnus/5.13001 (Ma Gnus v0.10) Emacs/24.3.93 (gnu/linux) Date: Sat, 20 Sep 2014 12:41:25 +0200 Message-ID: <87bnqavaju.fsf@engster.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.7 (/) [add CC Eric] Tom Tromey writes: > Try: > > (defclass zzz-whatever () ((hi))) > > Now notice there is a new function: > > (symbol-function 'zzz-whatever-list-p) > (lambda (obj) "Test OBJ to see if it a list of objects which are a child of type zzz-whatever" (when (listp obj) (let ((ans t)) (while (and obj ans) (setq ans (and (eieio-object-p (car obj)) (object-of-class-p (car obj) zzz-whatever))) (setq obj (cdr obj))) ans))) > > > This new -list-p function is not documented in the EIEIO manual. > > It seems to me that it would be a bit better not to define it. > It doesn't seem generally useful enough, to me. I agree it's not generally useful. It was added as a helper function to validate a slot which should hold a list of objects (as part of the EIEIO/EDE security fix for Emacs 23.4). At least that's what I remember. I was under the impression that eieio-persistent-validate/fix-slot-value would use this, but I cannot see it; maybe it's just hidden very well. If it is not used, I'd agree that it should better be removed or at least renamed to X--list-p. Eric, WDYT? -David From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Eric Ludlam Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 20 Sep 2014 19:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: David Engster Cc: 18494@debbugs.gnu.org, Tom Tromey , Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.141124284418417 (code B ref 18494); Sat, 20 Sep 2014 19:55:02 +0000 Received: (at 18494) by debbugs.gnu.org; 20 Sep 2014 19:54:04 +0000 Received: from localhost ([127.0.0.1]:46849 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVQjL-0004my-TJ for submit@debbugs.gnu.org; Sat, 20 Sep 2014 15:54:04 -0400 Received: from mail-qg0-f46.google.com ([209.85.192.46]:58459) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVQjJ-0004mW-PX for 18494@debbugs.gnu.org; Sat, 20 Sep 2014 15:54:02 -0400 Received: by mail-qg0-f46.google.com with SMTP id q108so1337273qgd.33 for <18494@debbugs.gnu.org>; Sat, 20 Sep 2014 12:54:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=MSC0iC9ejQ1eGvESVS46ySMiyCB9ZNQ2hMiDSpcVaVM=; b=cnD6pmNdDFnR2cUdt9i/LLmncPtkGzPxi4T6+Yi5HGiMHCqnmWg/eIhIvWYZ3gNuQg Mx42lmaKrWknnogtl7s9zxDVfhu6TbJF/BAwLIc5WNgP9K6OOy8wt1NJPRvtEItWTAHN 0WFd3nZOGG/vmpHZ3BJoZBoX3CH/L/XjkRfac7dIveb8lrNyclwO8TLuN8dhnDZv0LoD W4kAd2Hd7KCiPPhDWeLBzJ8i7YW12jNQ36cOplYnnaJK06Q/ylTvTf/sQGZRW2My4zIu RuUSg3BDpTiyZpgJGDNi8nS2z+onu6v+hwChRS9pWDDazca9OTWkYN2hURlIK8X5xNjn /EOw== X-Received: by 10.140.97.247 with SMTP id m110mr10887507qge.80.1411242840980; Sat, 20 Sep 2014 12:54:00 -0700 (PDT) Received: from [192.168.1.201] (pool-71-184-209-46.bstnma.fios.verizon.net. [71.184.209.46]) by mx.google.com with ESMTPSA id 96sm4228640qgf.20.2014.09.20.12.53.59 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 20 Sep 2014 12:54:00 -0700 (PDT) Message-ID: <541DDB56.1020000@gmail.com> Date: Sat, 20 Sep 2014 15:53:58 -0400 From: Eric Ludlam User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.3a1pre) Gecko/20091222 Shredder/3.1a1pre MIME-Version: 1.0 References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> In-Reply-To: <87bnqavaju.fsf@engster.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.7 (/) On 09/20/2014 06:41 AM, David Engster wrote: > [add CC Eric] > > Tom Tromey writes: >> Try: >> >> (defclass zzz-whatever () ((hi))) >> >> Now notice there is a new function: >> >> (symbol-function 'zzz-whatever-list-p) >> (lambda (obj) "Test OBJ to see if it a list of objects which are a child of type zzz-whatever" (when (listp obj) (let ((ans t)) (while (and obj ans) (setq ans (and (eieio-object-p (car obj)) (object-of-class-p (car obj) zzz-whatever))) (setq obj (cdr obj))) ans))) >> >> >> This new -list-p function is not documented in the EIEIO manual. >> >> It seems to me that it would be a bit better not to define it. >> It doesn't seem generally useful enough, to me. > I agree it's not generally useful. It was added as a helper function to > validate a slot which should hold a list of objects (as part of the > EIEIO/EDE security fix for Emacs 23.4). > > At least that's what I remember. I was under the impression that > eieio-persistent-validate/fix-slot-value would use this, but I cannot > see it; maybe it's just hidden very well. If it is not used, I'd agree > that it should better be removed or at least renamed to X--list-p. Hi, I found that many of my programs that use EIEIO have slots that are of :type that is an object of some class, which is why there are base predicates. Thus, if I have some object class foo, I can set to the :type of some other class to foo, instead of some other more complex type. Having another predicate that also handles the list of objects that include subclasses is just handy. David is right about the time when it was introduced, where only slots with a constrained :type for an object were allowed to be loaded in, allowing the loader to never 'eval anything, only read. Technically, I could hand write a few of those predicates for the EDE loader, but I thought it would be generally useful, especially if other folk want to save their objects. I'm not sure how widely used it is outside of EDE, semanticdb, and cogre which all have save files. I certainly think it should be documented if consensus is that it stays. Perhaps an extra option for the defclass to add extra predicates along with :method-invocation-order. Eric From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 20 Sep 2014 23:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eric Ludlam Cc: 18494@debbugs.gnu.org, Tom Tromey , David Engster , Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.14112545204796 (code B ref 18494); Sat, 20 Sep 2014 23:09:02 +0000 Received: (at 18494) by debbugs.gnu.org; 20 Sep 2014 23:08:40 +0000 Received: from localhost ([127.0.0.1]:46892 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVTlf-0001FH-FE for submit@debbugs.gnu.org; Sat, 20 Sep 2014 19:08:40 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:8496) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVTlc-0001F5-9t for 18494@debbugs.gnu.org; Sat, 20 Sep 2014 19:08:37 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArYGAIDvNVNFpZEG/2dsb2JhbABZgwaDSr0vgw6BFxd0giUBAQEBAgFWIwULCzQSFBgNJIgECNIZF456B4Q4BJRilDeBaoNMIQ X-IPAS-Result: ArYGAIDvNVNFpZEG/2dsb2JhbABZgwaDSr0vgw6BFxd0giUBAQEBAgFWIwULCzQSFBgNJIgECNIZF456B4Q4BJRilDeBaoNMIQ X-IronPort-AV: E=Sophos;i="4.97,753,1389762000"; d="scan'208";a="90418393" Received: from 69-165-145-6.dsl.teksavvy.com (HELO pastel.home) ([69.165.145.6]) by ironport2-out.teksavvy.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 20 Sep 2014 19:08:35 -0400 Received: by pastel.home (Postfix, from userid 20848) id 3B7CC62F79; Sat, 20 Sep 2014 19:08:35 -0400 (EDT) From: Stefan Monnier Message-ID: References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> Date: Sat, 20 Sep 2014 19:08:35 -0400 In-Reply-To: <541DDB56.1020000@gmail.com> (Eric Ludlam's message of "Sat, 20 Sep 2014 15:53:58 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.3 (/) > Technically, I could hand write a few of those predicates for the EDE > loader, but I thought it would be generally useful, especially if other folk > want to save their objects. I'm not sure how widely used it is outside of > EDE, semanticdb, and cogre which all have save files. I certainly think it > should be documented if consensus is that it stays. Perhaps an extra option > for the defclass to add extra predicates along > with :method-invocation-order. My natural reaction is to say that those *-list-p predicates shouldn't be automatically created, but could someone explain to me in detail how/where they're used? E.g. I hear it's used for types, but can't we use a type like (list foo) instead of foo-list (or maybe (cl-every foo-p) instead of foo-list-p)? Stefan From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Eric Ludlam Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 20 Sep 2014 23:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: 18494@debbugs.gnu.org, Tom Tromey , David Engster , Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.14112560487180 (code B ref 18494); Sat, 20 Sep 2014 23:35:02 +0000 Received: (at 18494) by debbugs.gnu.org; 20 Sep 2014 23:34:08 +0000 Received: from localhost ([127.0.0.1]:46908 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVUAK-0001rj-2E for submit@debbugs.gnu.org; Sat, 20 Sep 2014 19:34:08 -0400 Received: from mail-qc0-f171.google.com ([209.85.216.171]:50676) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVUAH-0001rb-UJ for 18494@debbugs.gnu.org; Sat, 20 Sep 2014 19:34:06 -0400 Received: by mail-qc0-f171.google.com with SMTP id x3so4759007qcv.16 for <18494@debbugs.gnu.org>; Sat, 20 Sep 2014 16:34:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=7MlbBdLhhCgh3waXVolCCnXbreL78TK1uvP+UaTFj8o=; b=DMXqNKaP1JIbxhkDG5H2kDKnOO1JP9/sKn5FIb/5crVLxvpn3K4oHZnlI+c2K7Tiff Ob2lASgl4Hx8YLYqzT+IJF3WVCfjPKjKVEElaDdcdDNynPew0TYVBRdrriNIw0wWWr/i su/T3tow3Dln1fL9n1rlniqPnChA/R2muisY1czoZOnsYkwZ+v0uCs0l3mxeD0jLJMKG TkD593JY7p4+bKOEthaRnLRczTyDTyVfajIJSYbNU5GPhGsTQ8n6R2cc+RBk1ySBqIy0 HafuVgFd2rOPYb+Sjca+XeOKgcW4Z8zTpXadPSxZatBOfDoxxzxMvjczfw0EJg6ZgDf1 C2Wg== X-Received: by 10.224.88.71 with SMTP id z7mr128931qal.94.1411256045185; Sat, 20 Sep 2014 16:34:05 -0700 (PDT) Received: from [192.168.1.201] (pool-71-184-209-46.bstnma.fios.verizon.net. [71.184.209.46]) by mx.google.com with ESMTPSA id d8sm4562268qam.46.2014.09.20.16.34.04 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 20 Sep 2014 16:34:04 -0700 (PDT) Message-ID: <541E0EEB.4020603@gmail.com> Date: Sat, 20 Sep 2014 19:34:03 -0400 From: Eric Ludlam User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.3a1pre) Gecko/20091222 Shredder/3.1a1pre MIME-Version: 1.0 References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.7 (/) On 09/20/2014 07:08 PM, Stefan Monnier wrote: >> Technically, I could hand write a few of those predicates for the EDE >> loader, but I thought it would be generally useful, especially if other folk >> want to save their objects. I'm not sure how widely used it is outside of >> EDE, semanticdb, and cogre which all have save files. I certainly think it >> should be documented if consensus is that it stays. Perhaps an extra option >> for the defclass to add extra predicates along >> with :method-invocation-order. > My natural reaction is to say that those *-list-p predicates shouldn't > be automatically created, but could someone explain to me in detail > how/where they're used? > E.g. I hear it's used for types, but can't we use a type like (list foo) > instead of foo-list (or maybe (cl-every foo-p) instead of foo-list-p)? > I recall back in the day trying something like (list foo) and not getting it right so I just wrote a predicate. I'm not that familiar with the nuances of typep, but if there is now a typep built into Emacs, EIEIO will need to remove it's local copy of an old typep, and I could certainly convert over to using something list (list foo). I use those predicates mostly with typep. In that case, the eieio-persistent baseclass will need to be updated to extract desired classes from the predicates correctly. The other occurrences would be easier to swap in new values. Eric From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 21 Sep 2014 16:21:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eric Ludlam Cc: 18494@debbugs.gnu.org, Tom Tromey , David Engster , Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.141131641210359 (code B ref 18494); Sun, 21 Sep 2014 16:21:02 +0000 Received: (at 18494) by debbugs.gnu.org; 21 Sep 2014 16:20:12 +0000 Received: from localhost ([127.0.0.1]:47612 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVjrw-0002h1-1F for submit@debbugs.gnu.org; Sun, 21 Sep 2014 12:20:12 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:62301) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVjrt-0002gr-Ce for 18494@debbugs.gnu.org; Sun, 21 Sep 2014 12:20:10 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArYGAIDvNVNFpZEG/2dsb2JhbABZgwaDSr0vgw6BFxd0giUBAQEBAgFWHAcFCws0EhQYDSSIBAjSGReOegeEOASpGYFqg0wh X-IPAS-Result: ArYGAIDvNVNFpZEG/2dsb2JhbABZgwaDSr0vgw6BFxd0giUBAQEBAgFWHAcFCws0EhQYDSSIBAjSGReOegeEOASpGYFqg0wh X-IronPort-AV: E=Sophos;i="4.97,753,1389762000"; d="scan'208";a="90477383" Received: from 69-165-145-6.dsl.teksavvy.com (HELO pastel.home) ([69.165.145.6]) by ironport2-out.teksavvy.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 21 Sep 2014 12:20:08 -0400 Received: by pastel.home (Postfix, from userid 20848) id 2FA2A640EC; Sun, 21 Sep 2014 12:20:08 -0400 (EDT) From: Stefan Monnier Message-ID: References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> <541E0EEB.4020603@gmail.com> Date: Sun, 21 Sep 2014 12:20:08 -0400 In-Reply-To: <541E0EEB.4020603@gmail.com> (Eric Ludlam's message of "Sat, 20 Sep 2014 19:34:03 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.3 (/) > I recall back in the day trying something like (list foo) and not getting it > right so I just wrote a predicate. I'm not that familiar with the nuances > of typep, but if there is now a typep built into Emacs, Not any more than before: there was CL's `typep' and now it's been renamed to `cl-typep'. > EIEIO will need to remove it's local copy of an old typep, and I could > certainly convert over to using something list (list foo). I use > those predicates mostly with typep. Could someone explain (and show) to me in detail how/where these foo-list-p are used in relation to EIEIO? Stefan From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Eric Ludlam Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 21 Sep 2014 16:38:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: 18494@debbugs.gnu.org, Tom Tromey , David Engster Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.141131742811993 (code B ref 18494); Sun, 21 Sep 2014 16:38:02 +0000 Received: (at 18494) by debbugs.gnu.org; 21 Sep 2014 16:37:08 +0000 Received: from localhost ([127.0.0.1]:47616 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVk8J-00037M-Kr for submit@debbugs.gnu.org; Sun, 21 Sep 2014 12:37:08 -0400 Received: from newk.interbax.net ([173.193.149.250]:37378) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XVk8G-00036h-Tu for 18494@debbugs.gnu.org; Sun, 21 Sep 2014 12:37:05 -0400 X-No-Relay: not in my network Received: from mail-ie0-f169.google.com (mail-ie0-f169.google.com [209.85.223.169]) by newk.interbax.net (Postfix) with ESMTPSA id 47A8A93001A for <18494@debbugs.gnu.org>; Sun, 21 Sep 2014 10:37:03 -0600 (MDT) Received: by mail-ie0-f169.google.com with SMTP id rp18so4179866iec.0 for <18494@debbugs.gnu.org>; Sun, 21 Sep 2014 09:37:02 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.50.109.228 with SMTP id hv4mr9364570igb.13.1411317422784; Sun, 21 Sep 2014 09:37:02 -0700 (PDT) Received: by 10.64.243.38 with HTTP; Sun, 21 Sep 2014 09:37:02 -0700 (PDT) In-Reply-To: References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> <541E0EEB.4020603@gmail.com> Date: Sun, 21 Sep 2014 12:37:02 -0400 Message-ID: From: Eric Ludlam Content-Type: multipart/alternative; boundary=089e013a214ea68a55050395f16e X-InterBax-MailScanner-Information: Please contact the ISP for more information X-InterBax-MailScanner-ID: 47A8A93001A.A9A13 X-InterBax-MailScanner: Found to be clean X-InterBax-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=1.001, required 3.8, ALL_TRUSTED -1.00, BAYES_00 2.00, HTML_MESSAGE 0.00) X-InterBax-MailScanner-SpamScore: s X-InterBax-MailScanner-From: eric@siege-engine.com X-Spam-Status: No X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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 (/) --089e013a214ea68a55050395f16e Content-Type: text/plain; charset=UTF-8 On Sun, Sep 21, 2014 at 12:20 PM, Stefan Monnier wrote: > > > EIEIO will need to remove it's local copy of an old typep, and I could > > certainly convert over to using something list (list foo). I use > > those predicates mostly with typep. > > Could someone explain (and show) to me in detail how/where these > foo-list-p are used in relation to EIEIO? > > > Sure, in ede/base.el, you will find these lines: (defclass ede-project (ede-project-placeholder) ((subproj :initform nil :type list :documentation "Sub projects controlled by this project. For Automake based projects, each directory is treated as a project.") (targets :initarg :targets :type ede-target-list :custom (repeat (object :objectcreatefcn ede-new-target-custom)) :label "Local Targets" :group (targets) :documentation "List of top level targets in this project.") for "targets: you will see: :type ede-target-list which will expand to ede-target-list-p, which is a test for a list of type ede-target. This also occurs semantic/db.e which tracks a list of tables, and in cogre.el, where the graph tracks a list of graph elements. Eric --089e013a214ea68a55050395f16e Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On S= un, Sep 21, 2014 at 12:20 PM, Stefan Monnier <monnier@iro.umontrea= l.ca> wrote:

> EIEIO will need to remove it's local copy of an old typep, and I c= ould
> certainly convert over to using something list (list foo).=C2=A0 I use=
> those predicates mostly with typep.

Could someone explain (and show) to me in detail how/where these
foo-list-p are used in relation to EIEIO?



Sure, in ede/base.el, you will find these lines:
=

(defclass ede-project (ede-project-placeholder)
=C2=A0 ((subproj :initform nil
=C2=A0 =C2=A0:type list
=C2=A0 =C2=A0:documentation "Sub = projects controlled by this project.
For Automake based projects,= each directory is treated as a project.")
=C2=A0 =C2=A0(tar= gets :initarg :targets
=C2=A0 =C2=A0:type ede-target-list
=C2=A0 =C2=A0:custom (repeat (object :objec= tcreatefcn ede-new-target-custom))
=C2=A0 =C2=A0:label "Local Targets"
=C2=A0 =C2=A0:group = (targets)
=C2= =A0 =C2=A0:documentation "List of top level targets in this project.&q= uot;)


for "targets: you = will see:

:type ede-target-list

which will expand to ede-target-list-p, which is a test for a list o= f type ede-target.

This also occurs semantic/db.e = which tracks a list of tables, and in cogre.el, where the graph tracks a li= st of graph elements.

Eric
=C2=A0
<= /div>
--089e013a214ea68a55050395f16e-- From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 17 Oct 2014 05:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eric Ludlam Cc: 18494@debbugs.gnu.org, Tom Tromey , David Engster , Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.14135227042650 (code B ref 18494); Fri, 17 Oct 2014 05:12:02 +0000 Received: (at 18494) by debbugs.gnu.org; 17 Oct 2014 05:11:44 +0000 Received: from localhost ([127.0.0.1]:46505 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XezpH-0000gf-I8 for submit@debbugs.gnu.org; Fri, 17 Oct 2014 01:11:43 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:37945) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1XezpE-0000gW-9g for 18494@debbugs.gnu.org; Fri, 17 Oct 2014 01:11:41 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArYGAIDvNVNFxKjo/2dsb2JhbABZgwaDSr0vgw6BFxd0giUBAQEBAgFWIwULCzQSFBgNJIgECNIZF456B4Q4BKkZgWqDTCE X-IPAS-Result: ArYGAIDvNVNFxKjo/2dsb2JhbABZgwaDSr0vgw6BFxd0giUBAQEBAgFWIwULCzQSFBgNJIgECNIZF456B4Q4BKkZgWqDTCE X-IronPort-AV: E=Sophos;i="4.97,753,1389762000"; d="scan'208";a="94412150" Received: from 69-196-168-232.dsl.teksavvy.com (HELO ceviche.home) ([69.196.168.232]) by ironport2-out.teksavvy.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 17 Oct 2014 01:11:39 -0400 Received: by ceviche.home (Postfix, from userid 20848) id 534A3660D6; Fri, 17 Oct 2014 01:11:39 -0400 (EDT) From: Stefan Monnier Message-ID: References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> <541E0EEB.4020603@gmail.com> Date: Fri, 17 Oct 2014 01:11:39 -0400 In-Reply-To: <541E0EEB.4020603@gmail.com> (Eric Ludlam's message of "Sat, 20 Sep 2014 19:34:03 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.3 (/) > I recall back in the day trying something like (list foo) and not getting it > right so I just wrote a predicate. It think that (cl-deftype list-of (elem-type) `(and list (satisfies (lambda (list) (cl-every (lambda (elem) (cl-typep elem ',elem-type)) list))))) should work. I added this definition to eieio-core.el in Emacs's trunk. > I'm not that familiar with the nuances of typep, but if there is now > a typep built into Emacs, EIEIO will need to remove it's local copy of > an old typep, I removed eieio--typep and used cl-typep instead (one of the benefits of cl-lib is that it's OK to load it at run time). > and I could certainly convert over to using something list (list foo). Please try it. Stefan From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 30 Jan 2022 21:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: Eric Ludlam , Tom Tromey , Eric Ludlam , David Engster , 18494@debbugs.gnu.org Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.164357770811155 (code B ref 18494); Sun, 30 Jan 2022 21:22:01 +0000 Received: (at 18494) by debbugs.gnu.org; 30 Jan 2022 21:21:48 +0000 Received: from localhost ([127.0.0.1]:37840 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEHds-0002tr-26 for submit@debbugs.gnu.org; Sun, 30 Jan 2022 16:21:48 -0500 Received: from quimby.gnus.org ([95.216.78.240]:39114) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEHdq-0002tc-AU for 18494@debbugs.gnu.org; Sun, 30 Jan 2022 16:21:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=2gukXmVXxQP/UwTyJE0iHeS5k9HnbNgOBdODtkEpBS0=; b=TG2E9qO7LLFzOOxrjifXwlAWP6 lwSA+uyvruSM0gn4xcmZBH26gCCTDm2DBQLhV8ho6OlkyF13ZTOMa8+wO71bvJLk9dObRMebtcvYD IVCizEM2bVi3APk4EbUhbtkAthX11hK7IzkyFKbnU14Jy4f2OBn5xaLZ2y45HNU78lGg=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nEHdS-0002Wj-KR; Sun, 30 Jan 2022 22:21:25 +0100 From: Lars Ingebrigtsen References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> <541E0EEB.4020603@gmail.com> X-Now-Playing: Ida's _Lovers Prayers_: "The Love Below" Date: Sun, 30 Jan 2022 22:21:19 +0100 In-Reply-To: (Stefan Monnier's message of "Fri, 17 Oct 2014 01:11:39 -0400") Message-ID: <87tudk7wds.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Stefan Monnier writes: >> I'm not that familiar with the nuances of typep, but if there is now >> a typep built into Emacs, EIEIO will need to remove it's local copy of >> an old typep, > > I removed eieio--typep and used c [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 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 (---) Stefan Monnier writes: >> I'm not that familiar with the nuances of typep, but if there is now >> a typep built into Emacs, EIEIO will need to remove it's local copy of >> an old typep, > > I removed eieio--typep and used cl-typep instead (one of the benefits > of cl-lib is that it's OK to load it at run time). > >> and I could certainly convert over to using something list (list foo). > > Please try it. (I'm going through old bug reports that unfortunately weren't resolved at the time.) This was seven years ago, and apparently defclass still creates the undocumented -list-p functions. Is the consensus that they should be removed? Perhaps we should generate them as obsolete functions, to allow third-party usages of them to be notified? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 30 16:21:39 2022 Received: (at control) by debbugs.gnu.org; 30 Jan 2022 21:21:39 +0000 Received: from localhost ([127.0.0.1]:37837 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEHdi-0002tT-TA for submit@debbugs.gnu.org; Sun, 30 Jan 2022 16:21:39 -0500 Received: from quimby.gnus.org ([95.216.78.240]:39112) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEHdh-0002tC-EX for control@debbugs.gnu.org; Sun, 30 Jan 2022 16:21:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=GNoC8PvpuPX5+eWkCZLwF2amLR5YHwoPw3c2pJqwYvY=; b=RDW9mypJwfFEFUptPAxX0e7jZO LMEwUzzILYKEEPB32rOSybkMOsIt1AQ45xV4mHIwN7y+vjCDJtZjtApdXygyaN1KgpWNZ9ANJlp2g PA37I0mViJEWUiTAo/yVKT4p7fHEfHBOJRz9RPiH7dzhgz/hcLCKr/GbH1LKKYBPG8cM=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nEHdZ-0002Wv-K8 for control@debbugs.gnu.org; Sun, 30 Jan 2022 22:21:31 +0100 Date: Sun, 30 Jan 2022 22:21:28 +0100 Message-Id: <87sft47wdj.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #18494 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 18494 + moreinfo quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control 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 (---) tags 18494 + moreinfo quit From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 31 Jan 2022 02:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo To: Lars Ingebrigtsen Cc: Eric Ludlam , Tom Tromey , Eric Ludlam , David Engster , 18494@debbugs.gnu.org Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.164359648121276 (code B ref 18494); Mon, 31 Jan 2022 02:35:02 +0000 Received: (at 18494) by debbugs.gnu.org; 31 Jan 2022 02:34:41 +0000 Received: from localhost ([127.0.0.1]:38074 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEMWf-0005X6-5x for submit@debbugs.gnu.org; Sun, 30 Jan 2022 21:34:41 -0500 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:60701) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEMWd-0005Wt-K3 for 18494@debbugs.gnu.org; Sun, 30 Jan 2022 21:34:40 -0500 Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 17A46442E2D; Sun, 30 Jan 2022 21:34:34 -0500 (EST) Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id B7A23442E29; Sun, 30 Jan 2022 21:34:32 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1643596472; bh=n0QV+wLSVx+Vq/bqArEilMbvjlbOZ+OpH6T3gDBVmU8=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=ai1OcEaQp+83WZeYMzTKDW5u1yDZ0cJgjnnM+Fgf+dYGw+fz+tKIo/eqNA/I4DrEl 4/TG4v7q2jGiP0Qx40NJgkHam43tMoCMd3Nl45NuU8ND755wt9uaF0pHZ7k5n9cC/8 D7nBZPGnoShTQcML51qAmtg7w1RQ2TYdMXjUittqMgB3uocmf6erwxdlvJyKILgdBw c5s942hQStqlL8PnyBRrWtoY0TnC70lC9SlNeYFzNk+fLtKGGUA3ws1aoHY/9LemO4 EZvEl6aawc9KIbWFNajjAoAs2bcgFFngAlSgIaJyHB5Abuxrk74rfKaHVmK9wMAcDg 9EvZummb49Avg== Received: from pastel (76-10-138-212.dsl.teksavvy.com [76.10.138.212]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 6DCBD120315; Sun, 30 Jan 2022 21:34:32 -0500 (EST) From: Stefan Monnier Message-ID: References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> <541E0EEB.4020603@gmail.com> <87tudk7wds.fsf@gnus.org> Date: Sun, 30 Jan 2022 21:34:31 -0500 In-Reply-To: <87tudk7wds.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sun, 30 Jan 2022 22:21:19 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL -0.039 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain T_SCC_BODY_TEXT_LINE -0.01 - X-SPAM-LEVEL: 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 (---) > This was seven years ago, and apparently defclass still creates the > undocumented -list-p functions. Is the consensus that they should be > removed? Perhaps we should generate them as obsolete functions, to > allow third-party usages of them to be notified? AFAIK that's already what we do: (when eieio-backward-compatibility (let ((csym (intern (concat (symbol-name cname) "-list-p")))) (defalias csym [...] (make-obsolete csym (format "use (cl-typep ... \\='(list-of %s)) instead" cname) "25.1"))) -- Stefan From unknown Sun Jun 22 11:41:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#18494: 24.4.50; defclass creates undocumented *-list-p function Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 31 Jan 2022 15:34:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18494 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo To: Stefan Monnier Cc: Eric Ludlam , Tom Tromey , 18494@debbugs.gnu.org, David Engster , Eric Ludlam Received: via spool by 18494-submit@debbugs.gnu.org id=B18494.16436432152871 (code B ref 18494); Mon, 31 Jan 2022 15:34:02 +0000 Received: (at 18494) by debbugs.gnu.org; 31 Jan 2022 15:33:35 +0000 Received: from localhost ([127.0.0.1]:40280 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEYgQ-0000kF-OJ for submit@debbugs.gnu.org; Mon, 31 Jan 2022 10:33:34 -0500 Received: from quimby.gnus.org ([95.216.78.240]:46726) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEYgP-0000jv-0P for 18494@debbugs.gnu.org; Mon, 31 Jan 2022 10:33:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=4rQqMFT0T9cDWzyj4TP9e6x+Fg7wj4oldSZFPnX5R+Q=; b=K45q8ZPvXk+eRDt6HXejo+lGMz o8BMd+yRzkgX4Lf6SPfotHdv74PnWm4/wKCW8HiW6rJbKVO79VP2ewWOT70bm0WpHrTtGeJ8ftb60 jXr+ctKZrEwtzRJ8QcgsXdesJg2iBc8eHer2NSgu1XA3O2L11lTMZ6dg9ORThtyDTkQA=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nEYgE-0003lb-1r; Mon, 31 Jan 2022 16:33:24 +0100 From: Lars Ingebrigtsen References: <87a95xvfuy.fsf@tromey.com> <87bnqavaju.fsf@engster.org> <541DDB56.1020000@gmail.com> <541E0EEB.4020603@gmail.com> <87tudk7wds.fsf@gnus.org> X-Now-Playing: Two Nice Girls's _Like A Version_: "I Feel (Like Makin') Love" Date: Mon, 31 Jan 2022 16:33:19 +0100 In-Reply-To: (Stefan Monnier's message of "Sun, 30 Jan 2022 21:34:31 -0500") Message-ID: <87y22v2a4g.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Stefan Monnier writes: > AFAIK that's already what we do: > > (when eieio-backward-compatibility > (let ((csym (intern (concat (symbol-name cname) "-list-p")))) > (defalias csym > [...] > (make-obsolete csym (format > "use [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 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 (---) Stefan Monnier writes: > AFAIK that's already what we do: > > (when eieio-backward-compatibility > (let ((csym (intern (concat (symbol-name cname) "-list-p")))) > (defalias csym > [...] > (make-obsolete csym (format > "use (cl-typep ... \\='(list-of %s)) instead" > cname) > "25.1"))) Sorry; should have checked first. Eric Ludlam writes: > Could someone explain (and show) to me in detail how/where these > foo-list-p are used in relation to EIEIO? > > Sure, in ede/base.el, you will find these lines: [...] > for "targets: you will see: > > :type ede-target-list > > which will expand to ede-target-list-p, which is a test for a list of type ede-target. And this has been fixed, so I guess there's nothing to do here (beyond removing the -list-p predicates when we start removing things obsoleted in 25.1 in a couple of years), and I'm therefore closing this bug report. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 31 10:33:47 2022 Received: (at control) by debbugs.gnu.org; 31 Jan 2022 15:33:47 +0000 Received: from localhost ([127.0.0.1]:40283 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEYgd-0000kg-15 for submit@debbugs.gnu.org; Mon, 31 Jan 2022 10:33:47 -0500 Received: from quimby.gnus.org ([95.216.78.240]:46744) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEYgb-0000kQ-1R for control@debbugs.gnu.org; Mon, 31 Jan 2022 10:33:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=DH36CgN9rp3J/vdKV94PAV/M8QRLWXAHFdfPBX/0pvw=; b=V4oiFjlocXZgmaci4v/zP7t7pM N3IcHkN1v0DNMXCFhfnUA78eANJF2s1w4FDDPgLTc3xf9VU3QiIlX/PAGE2Q8hjU0yDH7x1aEri4t yavEIZfMf2388Wrl91jai5DsbgSlEB8u/c0hjpEU9at+C+DktH7gTFwx81HwCoja1rus=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nEYgT-0003lx-6N for control@debbugs.gnu.org; Mon, 31 Jan 2022 16:33:39 +0100 Date: Mon, 31 Jan 2022 16:33:35 +0100 Message-Id: <87wnif2a40.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #18494 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 18494 25.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control 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 (---) close 18494 25.1 quit