emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 0161a4a: Fix compilation warning by having ede-targ


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master 0161a4a: Fix compilation warning by having ede-target inherit from eieio-named
Date: Mon, 17 Jun 2019 07:05:46 -0400 (EDT)

branch: master
commit 0161a4ae09b4269a14143808cfa44a6fd02790df
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Fix compilation warning by having ede-target inherit from eieio-named
    
    * lisp/cedet/ede/base.el (ede-target): Inherit from eieio-named so
    that if you're customizing objects via eieio-object-value-get, you
    can set the name.
    
    * lisp/emacs-lisp/eieio-custom.el (eieio-object-value-get): Don't
    use obsolete function `eieio-object-set-name-string'.
---
 lisp/cedet/ede/base.el          | 2 +-
 lisp/emacs-lisp/eieio-custom.el | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/lisp/cedet/ede/base.el b/lisp/cedet/ede/base.el
index 57973ff..a4e2464 100644
--- a/lisp/cedet/ede/base.el
+++ b/lisp/cedet/ede/base.el
@@ -46,7 +46,7 @@
 ;; The TARGET is an entity in a project that knows about files
 ;; and features of those files.
 
-(defclass ede-target (eieio-speedbar-directory-button)
+(defclass ede-target (eieio-speedbar-directory-button eieio-named)
   ((buttonface :initform speedbar-file-face) ;override for superclass
    (name :initarg :name
         :type string
diff --git a/lisp/emacs-lisp/eieio-custom.el b/lisp/emacs-lisp/eieio-custom.el
index c9a8129..78fab90 100644
--- a/lisp/emacs-lisp/eieio-custom.el
+++ b/lisp/emacs-lisp/eieio-custom.el
@@ -317,7 +317,8 @@ Optional argument IGNORE is an extraneous parameter."
                             (car (widget-apply (car chil) :value-inline))))
               (setq chil (cdr chil))))))
     ;; Set any name updates on it.
-    (if name (eieio-object-set-name-string obj name))
+    (when name
+      (setf (slot-value obj 'object-name) name))
     ;; This is the same object we had before.
     obj))
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]