From: Stefan Monnier <monnier@IRO.UMontreal.CA>
To: Daniel Colascione <dancol@dancol.org>
Cc: emacs-devel@gnu.org
Subject: Re: [Emacs-diffs] trunk r116995: cl-lib defstruct introspection
Date: Mon, 21 Apr 2014 22:03:18 -0400 [thread overview]
Message-ID: <jwv1twqnnmu.fsf-monnier+emacsdiffs@gnu.org> (raw)
In-Reply-To: <53559B0D.3070505@dancol.org> (Daniel Colascione's message of "Mon, 21 Apr 2014 15:26:21 -0700")
> Can it? I tried it in vc-dir and got a completely unrelated ChangeLog hunk.
Yes, there's a long-standing problem in vc-dir, such that it only works
well if you mark the files you're going to commit (basically the
changelog-copying feature needs the list of files that will be committed
and vc-dir doesn't provide it unless you manually mark each file).
Patch welcome.
>>>> I'm curious: when/where did you bump against a need for that?
>>> I have a few private macros that lexically bind structure slots,
>> Which part makes it impossible/impractical to use standard accessors for
>> that?
> :conc-name, for starters. Also, :read-only, although you could argue
> that you shouldn't go around mutating read-only slots anyway.
I guess I don't know what you mean by "lexically bind structure slots".
Can you give an example?
> Better to just define additional interfaces for optional functionality.
> The interface approach seems decently light and extensible, and the
> implementation complexity is low.
An object system based on interfaces sounds fine (tho I'm not sure if
it'll really end up simpler). But note that every closure is made of
2 arrays, so a struct of 4 closures will really be made of 9 arrays, and
usually the only thing closed-over will be "the additional data"
(i.e. the attributes usually stored in "self"), so if we could handle
this object (the "self") specially we'd avoid all 4 closures.
Stefan
next prev parent reply other threads:[~2014-04-22 2:03 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <E1Wbhqn-0001CJ-4X@vcs.savannah.gnu.org>
2014-04-20 12:49 ` [Emacs-diffs] trunk r116995: cl-lib defstruct introspection Stefan Monnier
2014-04-23 12:56 ` Stefan Monnier
2014-04-21 15:38 ` Stefan Monnier
2014-04-21 17:40 ` Daniel Colascione
2014-04-21 22:03 ` Stefan Monnier
2014-04-21 22:26 ` Daniel Colascione
2014-04-22 2:03 ` Stefan Monnier [this message]
2014-04-22 2:07 ` Daniel Colascione
2014-04-22 3:28 ` Stefan Monnier
2014-04-23 3:18 ` Declaim and proclaim (Was: Re: [Emacs-diffs] trunk r116995: cl-lib defstruct introspection) Daniel Colascione
2014-04-23 13:14 ` Declaim and proclaim Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwv1twqnnmu.fsf-monnier+emacsdiffs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=dancol@dancol.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).