GNU bug report logs - #20491
25.0.50; new eieio-oref implementation

Previous Next

Package: emacs;

Reported by: Pierre Lorenzon <devel <at> pollock-nageoire.net>

Date: Sun, 3 May 2015 05:39:02 UTC

Severity: normal

Found in version 25.0.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Pierre Lorenzon <devel <at> pollock-nageoire.net>
To: monnier <at> iro.umontreal.ca
Cc: zappo <at> gnu.org, 20491 <at> debbugs.gnu.org
Subject: bug#20491: 25.0.50; new eieio-oref implementation
Date: Wed, 06 May 2015 09:19:24 +0200 (CEST)
Hi,



From: Stefan Monnier <monnier <at> iro.umontreal.ca>
Subject: Re: bug#20491: 25.0.50; new eieio-oref implementation
Date: Sun, 03 May 2015 21:44:33 -0400

>>   error("eieio-oref called on a class!")
>>   eieio-oref(srecode-template-inserter-section-end key)
>>   srecode-compile-inserter("INDENT" "\n"
> 
> Does the patch below fix this problem?
> 
> AFAICT, the use of `oref' with a class object was never documented as
> a supported feature of EIEIO.  You're supposed to use oref-default for that.
> 
> 
>         Stefan
> 
> 
> diff --git a/lisp/cedet/srecode/compile.el b/lisp/cedet/srecode/compile.el
> index c93a6f7..763c462 100644
> --- a/lisp/cedet/srecode/compile.el
> +++ b/lisp/cedet/srecode/compile.el
> @@ -523,7 +523,7 @@ to the inserter constructor."
>  	(setq classes (append classes (eieio-class-children (car classes))))
>  	;; Do we have a match?
>  	(when (and (not (class-abstract-p (car classes)))
> -		   (equal (oref (car classes) key) key))
> +		   (equal (oref-default (car classes) key) key))
>  	  ;; Create the new class, and apply state.
>  	  (setq new (apply (car classes) name props))
>  	  (srecode-inserter-apply-state new STATE)


	  In fact it corrects the problem but maybe I did not
	  tell you and that's why you did not install this
	  change in the git repo. I cloned it today.

	  Pierre




This bug report was last modified 10 years and 17 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.