Re: [racket-dev] Generics scoping issues

2013-08-17 Thread J. Ian Johnson
-0400 (EDT) Subject: Re: [racket-dev] Generics scoping issues Mind you, I don't think this example -- using a method in a #:fast-defaults predicate -- can work. The implementation of free-box will have to check the predicate in order to perform generic dispatch, and the predicate has to call fre

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread Carl Eastlund
med to do the trick, oddly. >>> -Ian >>> ----- Original Message - >>> From: "Carl Eastlund" >>> To: "J. Ian Johnson" >>> Cc: "dev" >>> Sent: Friday, August 16, 2013 5:23:33 PM GMT -05:00 US/Canada Easter

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread Carl Eastlund
[(def-free e gfree free bound avar [(x) (if (x . ∈ . bound) ∅ (set x))])]) >> >> generic-problems.rkt:31:27: define/generic: free is not a method of >> generic interfaces gen:binds-variables >> at: free >> in: (define/generic gfree free) >> >> >> >> &g

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread Carl Eastlund
iables seemed to do the trick, oddly. > -Ian > - Original Message - > From: "Carl Eastlund" > To: "J. Ian Johnson" > Cc: "dev" > Sent: Friday, August 16, 2013 5:23:33 PM GMT -05:00 US/Canada Eastern > Subject: Re: [racket-dev] Generic

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread J. Ian Johnson
gen:binds-variables at: free in: (define/generic gfree free) - Original Message - From: "Carl Eastlund" < c...@ccs.neu.edu > To: "J. Ian Johnson" < i...@ccs.neu.edu > Cc: "dev" < dev@racket-lang.org > Sent: Friday, August 16, 2013 4:

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread Carl Eastlund
eric: free is not a method of > generic interfaces gen:binds-variables > at: free > in: (define/generic gfree free) > > > - Original Message - > From: "Carl Eastlund" > To: "J. Ian Johnson" > Cc: "dev" > Sent: Friday, Aug

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread J. Ian Johnson
To: "J. Ian Johnson" Cc: "dev" Sent: Friday, August 16, 2013 4:50:53 PM GMT -05:00 US/Canada Eastern Subject: Re: [racket-dev] Generics scoping issues Problem 1 -- you have to use define/generic if you want to use the generic version of something in the context of a set of

Re: [racket-dev] Generics scoping issues

2013-08-16 Thread Carl Eastlund
Problem 1 -- you have to use define/generic if you want to use the generic version of something in the context of a set of specific method implementations. That's by design. Problem 2 -- what error message or unexpected behavior are you getting? That should work, it sounds like a bug in define/ge

[racket-dev] Generics scoping issues

2013-08-16 Thread J. Ian Johnson
I'm starting to use generics, and me being myself, I wrote some macros to make writing method definitions easier. But, I'm seeing that #:methods seems to rebind method identifiers in a way that hygiene interferes with. I would expect to be allowed to do the following two things (problems annota