Re: Re[1]: Newbie: Old methods hanging around when refactoring code
Syver Enstad <[email protected]> 10 Dec 2002 14:32:24 +0100
| Newsgroups | gmane.emacs.eieio |
|---|---|
| Message-ID | <[email protected]> |
"Eric M. Ludlam" <[email protected]> writes: > I think some code like this can wipe out old methods though: > > (fset 'dead-method nil) > (put eieio-method-obarray nil) > > but that is a pretty heavy hammer if you have other classes using > that method. I tried using this snippet, based on what you wrote. I think it was too heavy a hammer because I wasn't able to get them back again when I evaluated the buffer afterwards. You don't wear a somewhat lighter hammer do you? :-) Actually it's a bit of a shame because when the inability to delete methods means that my strategy of loading test-case objects based on introspecting their methods won't work because methods that I have removed from the source code still hangs around. (mapcar (lambda (each) (fset each nil) (put each 'eieio-method-obarray nil)) (eieio-all-generic-functions 'test-case-test)) -- Vennlig hilsen Syver Enstad ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf