The following servlet show an input field from a formlet and then tries to use
formlet-process on the resulting request. I don't understand why this fails
when, like below, the send/suspend and formlet-process is in a function but
works when inlined, like the #; commented code in handle-html-for
I don't get why TR should use a custom contract instead of case-> providing
better error messages.
You get the same error message with:
#lang racket
(define/contract (f) (case->) 2)
(f 2)
;(f)
On Tue, Feb 5, 2013 at 8:10 PM, Matthias Felleisen wrote:
>
> On Feb 5, 2013, at 4:17 PM, Asumu Taki
On Feb 5, 2013, at 4:17 PM, Asumu Takikawa wrote:
>>
>> In 5.3.2, when running untyped.rkt, I get:
>>
>> #: arity mismatch;
>>the expected number of arguments does not match the given number
>> given: 1
>> arguments...:
>> 5
>
> I agree that this error message is bad. It's
Fixed, thanks for the report!
Vincent
At Tue, 5 Feb 2013 16:06:12 -0500,
Joe Gibbs Politz wrote:
>
> [1 ]
> [1.1 ]
> It seems like `cast` doesn't work at all in typed/racket/no-check:
>
> #lang typed/racket/no-check
>
> (cast 5 Number)
>
> ../../usr/lib/racket/collects/racket/contract/priv
On 2013-02-05 16:06:11 -0500, Joe Gibbs Politz wrote:
>This worked in 5.3.1:
>
>typed.rkt
>===
>#lang typed/racket
>
>(provide wrap)
>
>(define: (wrap (p : Procedure)) : Procedure
> (λ (_) p))
>
>untyped.rkt
>===
>#lang racket
>
>(require "ty
It seems like `cast` doesn't work at all in typed/racket/no-check:
#lang typed/racket/no-check
(cast 5 Number)
../../usr/lib/racket/collects/racket/contract/private/blame.rkt:89:0: 5:
broke its contract
promised: #f
produced: 5
in: #f
contract from: cast
blaming: cast
at: unsaved-editor108
Question about a TR regression in 5.3.2
This worked in 5.3.1:
typed.rkt
===
#lang typed/racket
(provide wrap)
(define: (wrap (p : Procedure)) : Procedure
(λ (_) p))
untyped.rkt
===
#lang racket
(require "typed.rkt")
(define f (λ (n) n))
((wrap f) 5) ;; returns f itself; f is e
Thanks Pierpaolo, I did not know about that useful trick with
call-with-values, missed it sometimes.
Ryan, thanks! in-values-sequence did the trick perfectly.
Regards,
Dmitry
On 02/05/2013 09:17 PM, Ryan Culpepper wrote:
On 02/05/2013 11:57 AM, Dmitry Pavlov wrote:
Hello,
Suppose I have
On 02/05/2013 11:57 AM, Dmitry Pavlov wrote:
Hello,
Suppose I have the following code:
(define conn (sqlite3-connect #:database "mydb.db" ))
(for (((x y) (in-query c "SELECT X, Y FROM DATA")))
(displayln x) (displayln y))
in-query returns a sequence that gives two values
at one call, and
On Tue, Feb 5, 2013 at 5:57 PM, Dmitry Pavlov wrote:
> Any hints will be much appreciated.
Does the following help?
(define (function-which-returns-an-unknown-number-of-values)
(apply values (make-list (random 10) 'foo)))
> (call-with-values function-which-returns-an-unknown-number-of-values
Hello,
Suppose I have the following code:
(define conn (sqlite3-connect #:database "mydb.db" ))
(for (((x y) (in-query c "SELECT X, Y FROM DATA")))
(displayln x) (displayln y))
in-query returns a sequence that gives two values
at one call, and the "for" loop binds those values
to x and y r
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 01-02-13 19:34, Matthew Flatt wrote:
> At Fri, 01 Feb 2013 15:09:31 +0100, Marijn wrote:
>> On 01-02-13 05:20, Eli Barzilay wrote:
>>> Racket version 5.3.2 is now available from
>>>
>>> http://racket-lang.org/
>>>
>>> * Documentation cross-referen
12 matches
Mail list logo