[racket-dev] paren-shape question

2012-03-25 Thread Danny Yoo
I'm getting confused by some behavior with regards to paren-shape. Here's what I see: #lang racket ;; (define-for-syntax (square-brackets? stx) (eq? (syntax-property stx 'paren-shape) #\[)) (define-syntax

Re: [racket-dev] paren-shape question

2012-03-25 Thread Robby Findler
It comes from the way syntax properties are propagated through macro transformers. There is some explanation of this in the docs; search for syntax-property and scroll up. Robby On Sun, Mar 25, 2012 at 7:05 PM, Danny Yoo d...@cs.wpi.edu wrote: I'm getting confused by some behavior with regards

Re: [racket-dev] paren-shape question

2012-03-25 Thread Danny Yoo
On Sun, Mar 25, 2012 at 8:09 PM, Robby Findler ro...@eecs.northwestern.edu wrote: It comes from the way syntax properties are propagated through macro transformers. There is some explanation of this in the docs; search for syntax-property and scroll up. Ok. Yikes, this is more complicated

[racket-dev] `_fun' types for higher-order functions in the ffi

2012-03-25 Thread Eli Barzilay
This is a design issue in the ffi -- I'd really appreciate comments from people who use it, particularly if you're using higher-order functions (= callbacks) with pointer arguments. It's long because I don't see a good way out, so it's partly me thinking out loud. There is a long-standing issue

Re: [racket-dev] paren-shape question

2012-03-25 Thread Robby Findler
On Sun, Mar 25, 2012 at 7:18 PM, Danny Yoo d...@cs.wpi.edu wrote: I'm still somewhat confused, because of the following: Compare: (syntax/loc #'foo [app op ...]) vs: (syntax [app op ...]) The first does not have paren-shape defined, while the second does. Is this intentional?

Re: [racket-dev] paren-shape question

2012-03-25 Thread Matthew Flatt
At Sun, 25 Mar 2012 19:58:29 -0500, Robby Findler wrote: On Sun, Mar 25, 2012 at 7:18 PM, Danny Yoo d...@cs.wpi.edu wrote: I'm still somewhat confused, because of the following: Compare: (syntax/loc #'foo [app op ...]) vs: (syntax [app op ...]) The first does not have