unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Daniel Llorens <dll@jast.ch>
To: 12929@debbugs.gnu.org
Subject: bug#12929: case-lambda*
Date: Mon, 19 Nov 2012 11:38:17 +0100	[thread overview]
Message-ID: <30EECB7A-D12A-4BE4-B2D0-7AD24B5A1DD9@jast.ch> (raw)


See the thread here 

http://lists.gnu.org/archive/html/guile-user/2012-11/msg00032.html

In Guile 2.0.6

(define f (case-lambda*
             ((x #:optional y) 1)
	     ((x #:key y)      2)
	     ((x y #:key z)    3)))

(f 1 2 #:z 3) -> Odd length of keyword argument list

Also

(define g (case-lambda*
                      ((a #:key x) 1)
                      ((a b c #:key x) 3)))

(g 1 2 3) - > Invalid keyword

This behavior doesn't seem useful and doesn't follow from the doc on case-lambda*, which is rather vague and lacks examples.

The case-lambda* test in tree-il.test also fails on the REPL

(let ((f (case-lambda*
          ((x #:optional y) 1)
          ((x #:key y)      2)
          ((x y #:key z)    3))))
  (list (f 1)
        (f 1 2)
        (f #:y 2)
        (f 1 2 #:z 3)))

-> Odd length of keyword argument list

Thanks,

	Daniel






             reply	other threads:[~2012-11-19 10:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-19 10:38 Daniel Llorens [this message]
2012-11-28 22:36 ` bug#12929: case-lambda* Ludovic Courtès
2013-03-05 17:54 ` Andy Wingo

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/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=30EECB7A-D12A-4BE4-B2D0-7AD24B5A1DD9@jast.ch \
    --to=dll@jast.ch \
    --cc=12929@debbugs.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.
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).