unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Nicolas Petton <nicolas@petton.fr>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: Is there a function for auto currying in Elisp?
Date: Fri, 22 Dec 2017 16:38:42 +0100	[thread overview]
Message-ID: <873742n56l.fsf@petton.fr> (raw)
In-Reply-To: <jwv1sjmc2xk.fsf-monnier+emacs@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 552 bytes --]

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> If you're serious about using such a construct, you'd first want to make
> it into a macro so it avoids the use of apply-partially which just adds
> insult to injury.

The implementation can be made more efficient, but my question is
whether or not a `curry' function should be part of Elisp's arsenal.  I
think it should, the same way as we have `apply-partially'.

The fact that closures are expensive is a bit sad, but I don't think
that we should discourage users from using them.

Cheers,
Nico

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

      parent reply	other threads:[~2017-12-22 15:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-21 14:41 Is there a function for auto currying in Elisp? Nicolas Petton
2017-12-21 15:36 ` Philipp Stephani
2017-12-21 16:13   ` Nicolas Petton
2017-12-21 16:50     ` Clément Pit-Claudel
2017-12-21 16:56       ` Nicolas Petton
2017-12-21 17:22         ` Clément Pit-Claudel
2017-12-21 18:00           ` Nicolas Petton
2017-12-21 16:48 ` vlnx
2017-12-21 21:04   ` John Wiegley
2017-12-21 19:13 ` Stefan Monnier
2017-12-22  9:14   ` Nicolas Petton
2017-12-22 13:51     ` Stefan Monnier
2017-12-22 15:34       ` Nicolas Petton
2017-12-26 18:56         ` John Wiegley
2017-12-22 15:38       ` Nicolas Petton [this message]

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=873742n56l.fsf@petton.fr \
    --to=nicolas@petton.fr \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /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).