Somewhat related, would it make sense to add a function like stx-e that would
be like (if (syntax? stx) (syntax-e stx) stx) to syntax/stx?
On Feb 17, 2015, at 2:18 AM, Alexis King wrote:
> I was just thinking today that I would, for example, find it useful to have a
> (zip ...) function in rac
the contracts or the set of values
that would pass the contracts or something like that.
>
>> On Jan 30, 2015, at 12:30, Alexander D. Knauth wrote:
>>
>>
>> On Jan 30, 2015, at 1:53 PM, Alexis King wrote:
>>
>>> No, it doesn’t need to be wrapped
setter function.
>> On Jan 30, 2015, at 07:27, Alexander D. Knauth wrote:
>>
>> On Thu, Jan 29, 2015, at 09:03 PM, Alexis King wrote:
>>> It isn’t wrapped in an opaque structure. That wasn’t a part of my proposal,
>>> and while I didn’t think of it until y
is passed through the orig contract as if it were going to the typed
side, which would unwrap it, and then that unwrapped value would be
passed to the new contract as if it were flowing from the untyped side
to the typed side.
>
>> On Jan 29, 2015, at 20:50, Alexander D. Knauth
>&g
And for “this isn’t really any different from casting mutable data types,” look
at this:
#lang typed/racket
(: b : (Boxof Number))
(define b (box 1))
(set-box! (cast b (Boxof (U Number String))) "I am a string")
(ann (unbox b) Number) ;"I am a string” ; not a contract error
>
&
Furthermore, even if the wrappers were shared between functions, untyped code
would recieved wrapped values, which would render them quite useless.
If it’s not an opaque type, but something like a list, then this works, and the
untyped code receiving wrapped values isn’t a problem here:
#lang ty
Um, for this:
(module typed typed/racket/base
(provide (struct-out Foo))
(struct [A] Foo ([x : A] [y : A]) #:transparent))
(Foo "a" 'b)
Should be fine because Foo could be instantiated at the type (U String Symbol).
On Jan 29, 2015, at 9:25 PM, Alexis King wrote:
> I recently ran into a
There’s a bug report about this here:
http://bugs.racket-lang.org/query/?cmd=view&pr=14524
Though I notice it gives a different error message now.
But why should structure type declarations being a module-wide construct?
Internal function definitions work, and internal type definitions work, so why
But I think it’s important that it doesn’t use gensym or something like that,
it uses syntax-marks, which means you can break these lexical scoping rules if
you want/need to by using either syntax-local-introduce or datum->syntax:
#lang racket
(require syntax/parse/define)
(define-simple-macro (
In terms of bugs, it’s probably related to this problem with call-with-values
and poly-dots:
#lang typed/racket
(: f : (All (a ...) [(-> (values Any ... a)) -> Void]))
(define (f g)
(call-with-values g void))
;=>
. . ../../Applications/Racket
v6.1.1/share/pkgs/typed-racket-lib/typed-racket/type
the OS terminated the `racket/racket3m` process
> from the outside. For example, the process may have exceeded a
> memory-use limit.
>
> At Sat, 19 Jul 2014 20:25:24 -0400, "Alexander D. Knauth" wrote:
>> I made a fork of the racket repo and committed some chang
I made a fork of the racket repo and committed some changes in a topic branch,
but I got this:
make[8]: Leaving directory
`/home/travis/build/AlexKnauth/racket/racket/src/build'
make[7]: Leaving directory
`/home/travis/build/AlexKnauth/racket/racket/src/build'
make[6]: Leaving directory
`/home/
12 matches
Mail list logo