I will; I just want to play with it for a bit first and make sure I'm doing
the right thing.
martin
On Tue, Sep 30, 2014 at 10:02 AM, Jens Axel Søgaard jensa...@soegaard.net
wrote:
Hi Martin,
2014-09-28 0:46 GMT+02:00 Martin DeMello martindeme...@gmail.com:
Solved, with help from Jens
Konrad, I am surprised you want to remove contracts from Typed-Untyped
boundaries given your history of praising types on this mailing list. But yes,
you're on the right track.
On Oct 2, 2014, at 1:18 AM, Konrad Hinsen konrad.hin...@fastmail.net wrote:
Konrad Hinsen writes:
Then, a
Let's make Spencer's question concrete. Say we have this situation:
#lang racket
;; contracts set up boundaries between two regions of a program, say two
modules
;;
---
;; the library
(module
[rather later]
When can I have this wonderful thing?
As it is, I insert (ann e Void) to discover the type that TR gives `e`.
The type error is very informative.
With `case-` types, as you say, it can get tricky to find out which
combination of argument types produces which type for any
Matthias Felleisen writes:
Konrad, I am surprised you want to remove contracts from
Typed-Untyped boundaries given your history of praising types on
this mailing list. But yes, you're on the right track.
I don't want to remove contracts from the boundaries, I want to remove
the boundaries
At Thu, 02 Oct 2014 09:23:19 -0400,
Neil Toronto wrote:
With `case-` types, as you say, it can get tricky to find out which
combination of argument types produces which type for any given `e` in
the function body. It might work out to just keep the types in order and
number them.
Would
Couple more questions: Is the use of defines inside let different from
using let*? And does #%datum actually need to be exported? Based on
documentation and trying it seems like it doesn't actually touch the
new literals since they are treated as symbols.
--
Tomi Pieviläinen, +358 400 487 504
A:
Spencer, I'm calling cubic-bezier from within a (module+ test (require
submod ..)...) form that itself is defined in the file where cubic-bezier
is defined. Also I tried from within REPL and requiring the code file.
Matthias,
I ran your example and it works exactly the way I wanted. The lambda
If you use this as the program:
#lang racket
;; contracts set up boundaries between two regions of a program, say two
modules
;;
---
;; the library
(provide (contract-out
[struct
I'm recompiling dylibs for OS X, and it occurs to me to wonder whether I
should still have
-mmacosx-version-min=10.5
in my raco ctool call. Does racket 6+ still support OS X 10.5?
Thanks!
John
Racket Users list:
http://lists.racket-lang.org/users
What's the best approach to:
+ defining a class whose instances can be used as procedures?
(define ci (new proc-class%))
(ci arg arg2 ... )
+ ... whose instances can be used as lists (or at least support direct
iteration?)
(define li (new listish-class%))
(for-each displayln li)
(map ci li)
Yes, 10.5 is the minimum supported version.
At Thu, 2 Oct 2014 13:45:23 -0700, John Clements wrote:
I'm recompiling dylibs for OS X, and it occurs to me to wonder whether I
should still have
-mmacosx-version-min=10.5
in my raco ctool call. Does racket 6+ still support OS X 10.5?
I've just pushed a change to check syntax that picks up tooltip syntax
properties in syntax objects that it sees. See the docs for
mouse-over-tooltips.
Robby
On Thu, Oct 2, 2014 at 8:23 AM, Neil Toronto neil.toro...@gmail.com wrote:
[rather later]
When can I have this wonderful thing?
As it
Hi guys,
Why does this appear to work? I assume it’s not a recommended approach.
#lang racket
(require (for-syntax syntax/parse))
(define-syntax (mylet stx)
(let ([val (syntax-case stx ()
[(_ x) #'x]
[(_ x xs ...) #'(cons x (mylet xs ...))])])
val))
(mylet
(let ([x y])
x)
= y
That let is just a wrapper that equals y. So your macro is really
(define-syntax (mylet stx)
(syntax-case stx ()
[(_ x) #'x]
[(_ x xs ...) #'(cons x (mylet xs ...))])])
Which causes
(mylet 1 2 3) = '(1 2 . 3) ;don't forget the dot!
And that's just the macro
On 10/02/2014 09:19 PM, Kevin Forchione wrote:
Hi guys,
Why does this appear to work? I assume it’s not a recommended approach.
#lang racket
(require (for-syntax syntax/parse))
(define-syntax (mylet stx)
(let ([val (syntax-case stx ()
[(_ x) #'x]
[(_ x xs
I don’t know if you can do it with generic interfaces (as in racket/generic),
but you can make classes whose instances have struct-type properties such as
prop:procedure and prop:sequence
(using interfaces as in racket/class, not racket/generic)
#lang racket
(define proc%
(interface* ()
On Oct 2, 2014, at 6:53 PM, Ryan Culpepper ry...@ccs.neu.edu wrote:
On 10/02/2014 09:19 PM, Kevin Forchione wrote:
Hi guys,
Why does this appear to work? I assume it’s not a recommended approach.
#lang racket
(require (for-syntax syntax/parse))
(define-syntax (mylet stx)
(let
If you're not already using DrRacket's awesome Macro Stepper, give it a
try, to see how your examples expand.
Neil V.
Racket Users list:
http://lists.racket-lang.org/users
19 matches
Mail list logo