Re: [racket] integer-sqrt

2014-09-12 Thread Matthias Felleisen
I have pushed a repair for the teaching languages. The Racket docs for git head seem to be okay. On Sep 12, 2014, at 6:21 PM, Patrick Useldinger wrote: > Hi all, > > according to the documentation, the above procedure accepts a *number* and > returns an integer. > > But (at least in Racke

Re: [racket] integer-sqrt

2014-09-12 Thread Matthias Felleisen
The docs contradict themselves here :-) On Sep 12, 2014, at 6:27 PM, Robby Findler wrote: > The docs, I believe. > > Robby > > On Fri, Sep 12, 2014 at 5:21 PM, Patrick Useldinger > wrote: >> Hi all, >> >> according to the documentation, the above procedure accepts a *number* and >> return

Re: [racket] error writing to stream port (Broken pipe; errno=32)

2014-09-12 Thread Matthew Flatt
To make the program concrete, suppose we have "a.rkt" as #lang racket/base (define (epipe? x) (and (exn:fail:filesystem:errno? x) (equal? '(32 . posix) (exn:fail:filesystem:errno-errno x (define (epipe-handler x) "ignore") (with-handlers ([epipe? epipe-handler]) (let loo

Re: [racket] integer-sqrt

2014-09-12 Thread Robby Findler
The docs, I believe. Robby On Fri, Sep 12, 2014 at 5:21 PM, Patrick Useldinger wrote: > Hi all, > > according to the documentation, the above procedure accepts a *number* and > returns an integer. > > But (at least in Racket 6.1) there's an error message stating that the > parameter needs to be

[racket] integer-sqrt

2014-09-12 Thread Patrick Useldinger
Hi all, according to the documentation, the above procedure accepts a *number* and returns an integer. But (at least in Racket 6.1) there's an error message stating that the parameter needs to be an *integer*: --- > (integer-sqrt 151.29) integer-sqrt:

Re: [racket] DrRacket 6.1 or Hardware Issue?

2014-09-12 Thread Robby Findler
I've pushed a fix for DrRacket so that it limits online expansion to the same limits that are in place for running programs. Thanks, Robby On Mon, Sep 8, 2014 at 4:23 PM, Sean Kanaley wrote: > After investigating a near complete lock up some more (saved by TTY window > and killing DrRacket after

Re: [racket] missing solution 20.1.1 ex:sem-funcs

2014-09-12 Thread Matthias Felleisen
On Sep 12, 2014, at 4:40 PM, Daniel Bastos wrote: > Again, we start with (2) and apply a series of substitutions. > > (f f) > = ( ) ;; since f is a > = ( ) ;; since is a subset of > > However, ( ) is not by definition a value. It is an > expression which may or may not /have/ a val

Re: [racket] missing solution 20.1.1 ex:sem-funcs

2014-09-12 Thread Daniel Bastos
On Mon, Sep 8, 2014 at 9:51 PM, Matthias Felleisen wrote: On Sep 2, 2014, at 11:45 AM, Daniel Bastos wrote: > > > A candidate for a solution. > > > > Exercise 20.1.1. Assume the Definitions window in DrScheme contains > > (define (f x) x). Identify the values among the following expressions: > >

Re: [racket] error writing to stream port (Broken pipe; errno=32)

2014-09-12 Thread Wolfgang Hukriede
Hi Matthias, nice to meet you! Yes, this was what I was looking for. For the records: (define (epipe? x) (and (exn:fail:filesystem:errno? x) (equal? '(32 . posix) (exn:fail:filesystem:errno-errno x (define (epipe-handler x) "ignore") (with-handlers ((epipe? epipe-handler)) tran

Re: [racket] missing solution 20.2.4 ex:fancy-contracts-poly

2014-09-12 Thread Daniel Bastos
On Mon, Sep 8, 2014 at 9:51 PM, Matthias Felleisen wrote: On Sep 4, 2014, at 12:54 PM, Daniel Bastos wrote: > > > A candidate for a solution. (I'm not sure I'm correct regarding the > > function project. The description says "a lists of lists" (which I > > translate to (listof ITEM)) and "a funct

Re: [racket] possibility of defining recontract-all-from-out

2014-09-12 Thread Jon Zeppieri
Yes, this is very helpful. Thank you. -Jon On Fri, Sep 12, 2014 at 10:47 AM, Matthias Felleisen wrote: > > Does this sketch help: > > #lang racket > > ;; define a header file language > (module L racket > ;; specification > (provide export) > ;; ---

Re: [racket] possibility of defining recontract-all-from-out

2014-09-12 Thread Matthias Felleisen
Does this sketch help: #lang racket ;; define a header file language (module L racket ;; specification (provide export) ;; -- ;; implementation (define-syntax (export stx) (syntax-case stx () [(_ file name ctc) #'(define-s

Re: [racket] possibility of defining recontract-all-from-out

2014-09-12 Thread Jon Zeppieri
Matthias, Would you be willing to elaborate on this a bit? Specifically, how is the header specified? Thanks, Jon On Thu, Sep 11, 2014 at 10:35 AM, Matthias Felleisen wrote: > > For a project last year, I developed a suite of syntactic abstractions > that expand into contracted provides. With