[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Two questions about generalized variables
From: |
Eric Abrahamsen |
Subject: |
Re: Two questions about generalized variables |
Date: |
Wed, 24 Feb 2016 10:03:25 +0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) |
Michael Heerdegen <michael_heerdegen@web.de> writes:
> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
>> > Oh, I see. Hmm, one could define a place expander quite similarly to
>> > the one of `alist-get', I think, but it doesn't seem one to be
>> > predefined, indeed.
>>
>> Right, that was my question, I guess -- I would do this with
>> `gv-define-setter', right? Its docstring is a bit impenetrable, but if
>> that's the right place to start I can figure it out.
>
> I think even `gv-define-simple-setter' should be sufficient.
>
>
>> Last question: How do I actually see the gv-expander of `alist-get'?
>> Where is that?
>
> Look into gv.el and search for `alist-get'.
>
> That expander definition produces more efficient code than a separate
> setter definition would - but one has to learn a bit about the concept
> behind the library to understand how that works.
Learning about the concepts was the whole idea!
Thanks again for your help,
Eric