Re: [racket-users] adding meaning to boolean return values

2015-11-09 Thread Matthias Felleisen
Yes, this is correct. But it is not a problem for Typed Racket, which was designed to accommodate precisely this style of programming: #lang typed/racket (define-type [Option P] (U P False)) (define-type SPath String) (: file-exists-> (-> SPath [Option SPath])) (define (file-exists-> name)

[racket-users] adding meaning to boolean return values

2015-11-09 Thread JCG
Perhaps this would be a hassle for Typed-Racket maintainers, but there are many places where standard Racket library functions return boolean. However, given the non-false nature of almost everything, certainly the code could be doubly useful and half the size while retaining boolean compatibil