Re: is (web client) ready for use even for the simplest task?

2013-09-09 Thread Nala Ginrut
This bug had a fix but didn't push, I think it's in master now. On Tue, 2013-09-10 at 12:13 +0800, Darren Hoo wrote: > (use-modules (web client)) > > (http-post "http://www.google.com/";) > > the POST request is sent without the Content-Length header > > OK, let's add something to the body >

Re: Syntax-rules generate symbol

2013-09-09 Thread Panicz Maciej Godek
2013/9/9 Taylan Ulrich B. > > For anyone who didn't know, "breaking" to arbitrary places is made > simple (and efficient) with `let/ec' from the module (ice-9 control), a > wrapper around `call-with-escape-continuation': > [...] I assume that the main reason for using this is efficiency (rather

Re: is (web client) ready for use even for the simplest task?

2013-09-09 Thread Aleix Conchillo FlaquƩ
I have used (web client) in both guile-oauth (with a twitter client example) and guile-xmlrpc. So, yes, I think it is ready for the simplest task and much more. This doesn't mean it might have bugs, as every software does. Aleix On Mon, Sep 9, 2013 at 9:13 PM, Darren Hoo wrote: > > (use-modules

is (web client) ready for use even for the simplest task?

2013-09-09 Thread Darren Hoo
(use-modules (web client)) (http-post "http://www.google.com/";) the POST request is sent without the Content-Length header OK, let's add something to the body (http-post "http://www.google.com/"; #:body "") Howcome the request now becomes an http GET request: GET / HTTP/1.1 Content-Type: t

Re: and-let* is not composable?

2013-09-09 Thread Ian Price
Stefan Israelsson Tampe writes: > (use-modules (srfi srfi-2)) > (use-modules (srfi srfi-1)) > > (define-curried (string-matches pattern string) >(and-let* ((match-struct (string-match pattern string)) > (count (match:count match-struct))) > (map (lambda(n)(match:substri

Re: Syntax-rules generate symbol

2013-09-09 Thread Taylan Ulrich B.
Panicz Maciej Godek writes: > Actually, the whole point of hygienic (syntax-rules) macros > is that you don't need to worry about the names of variables. > > I often use a very similar python-like for loop macro in my projects: > > http://hg.gnu.org.ua/hgweb/slayer/file/554a63bd3c6c/guile-modules

and-let* is not composable?

2013-09-09 Thread Panicz Maciej Godek
Hi, some time ago I posted to comp.lang.scheme with the following proposal of "define-curried" macro: (define-macro (define-curried signature . body) (match signature ((name args ...) `(define-syntax ,name (syntax-rules () ((_ ,@args) (begin ,@body))

Re: and-let* is not composable?

2013-09-09 Thread Stefan Israelsson Tampe
First of all define-macro is asking for trouble. don't use it is the general recomendation for guile. If you look into the kanren soures you will find, (define-syntax lambda@ (syntax-rules () ((_ (formal) body0 body1 ...) (lambda (formal) body0 body1 ...)) ((_ (formal0 formal1 formal2 .

Re: Syntax-rules generate symbol

2013-09-09 Thread Panicz Maciej Godek
2013/9/9 Dmitry Bogatov > > Hello! > > Here is my implementation of for loop. I found lisp really extremely > flexible, but there is one problem --- more often then not I do not need > var part, so I do not care how it would be named --- all I care is that > it will not shadow any other bindings.

Syntax-rules generate symbol

2013-09-09 Thread Dmitry Bogatov
Hello! Here is my implementation of for loop. I found lisp really extremely flexible, but there is one problem --- more often then not I do not need var part, so I do not care how it would be named --- all I care is that it will not shadow any other bindings. I think I can do it(did not tryed it