Re: [racket-users] [ANN] New package: live-free-or-die

2016-09-23 Thread Matthias Felleisen

Well, now that our youngsters have easily debunked the package, we can let it 
die because it no longer wants to live. 




> On Sep 22, 2016, at 10:30 PM, Leif Andersen  wrote:
> 
> > Also, with typed/racket/unsafe the optimizer *is* still run, so that's not 
> > any better *unless* you selectively choose what you want to be unsafe.
> 
> Woops, you are absolutely correct, I meant:
> 
> typed/racket/no-check
> 
> 
> ~Leif Andersen
> 
> On Thu, Sep 22, 2016 at 10:27 PM, Alex Knauth  wrote:
> 
>> On Sep 22, 2016, at 9:39 PM, Jay McCarthy  wrote:
>> 
>> If I knew how, I'd do unsafe-in, but I just know how to fake a typed 
>> context. The whole point is to use the optimizer so libraries like math are 
>> usable. 
> 
> Libraries like math/array would still be usable without the optimizer. 
> 
> What you really want is a version of require (or a require transformer) that 
> would allow untyped code to *selectively* unsafely require typed code. I 
> would want to import as few things unsafely as possible.
> 
> It's impossible to choose what to be unsafe about if it's an all-or-nothing 
> imperative flag like that.
> 
>> On Friday, September 23, 2016, Leif Andersen  wrote:
>> Umm...if you're going to do this, why is it imperative, and not a require 
>> transformer?
>> 
>> Also, I kind of agree with Matthias here...sigh. :'( Like, as far as I can 
>> tell, this is even worse then typed/racket/unsafe, as the optimizer is still 
>> run. O_o
> 
> Also, with typed/racket/unsafe the optimizer *is* still run, so that's not 
> any better *unless* you selectively choose what you want to be unsafe.
> 
> This is worse, but not because of the optimizer; because of the 
> all-or-nothing part.
> 
> Alex Knauth
> 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] [ANN] New package: live-free-or-die

2016-09-22 Thread Leif Andersen
> Also, with typed/racket/unsafe the optimizer *is* still run, so that's
not any better *unless* you selectively choose what you want to be unsafe.

Woops, you are absolutely correct, I meant:

typed/racket/no-check


~Leif Andersen

On Thu, Sep 22, 2016 at 10:27 PM, Alex Knauth  wrote:

>
> On Sep 22, 2016, at 9:39 PM, Jay McCarthy  wrote:
>
> If I knew how, I'd do unsafe-in, but I just know how to fake a typed
> context. The whole point is to use the optimizer so libraries like math are
> usable.
>
>
> Libraries like math/array would still be usable without the optimizer.
>
> What you really want is a version of require (or a require transformer)
> that would allow untyped code to *selectively* unsafely require typed code.
> I would want to import as few things unsafely as possible.
>
> It's impossible to choose what to be unsafe about if it's an
> all-or-nothing imperative flag like that.
>
> On Friday, September 23, 2016, Leif Andersen 
> wrote:
>
>> Umm...if you're going to do this, why is it imperative, and not a require
>> transformer?
>>
>> Also, I kind of agree with Matthias here...sigh. :'( Like, as far as I
>> can tell, this is even worse then typed/racket/unsafe, as the optimizer is
>> still run. O_o
>>
>
> Also, with typed/racket/unsafe the optimizer *is* still run, so that's not
> any better *unless* you selectively choose what you want to be unsafe.
>
> This is worse, but not because of the optimizer; because of the
> all-or-nothing part.
>
> Alex Knauth
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] [ANN] New package: live-free-or-die

2016-09-22 Thread Alex Knauth

> On Sep 22, 2016, at 9:39 PM, Jay McCarthy  wrote:
> 
> If I knew how, I'd do unsafe-in, but I just know how to fake a typed context. 
> The whole point is to use the optimizer so libraries like math are usable. 

Libraries like math/array would still be usable without the optimizer. 

What you really want is a version of require (or a require transformer) that 
would allow untyped code to *selectively* unsafely require typed code. I would 
want to import as few things unsafely as possible.

It's impossible to choose what to be unsafe about if it's an all-or-nothing 
imperative flag like that.

> On Friday, September 23, 2016, Leif Andersen  > wrote:
> Umm...if you're going to do this, why is it imperative, and not a require 
> transformer?
> 
> Also, I kind of agree with Matthias here...sigh. :'( Like, as far as I can 
> tell, this is even worse then typed/racket/unsafe, as the optimizer is still 
> run. O_o

Also, with typed/racket/unsafe the optimizer *is* still run, so that's not any 
better *unless* you selectively choose what you want to be unsafe.

This is worse, but not because of the optimizer; because of the all-or-nothing 
part.

Alex Knauth

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] [ANN] New package: live-free-or-die

2016-09-22 Thread Leif Andersen
Umm...if you're going to do this, why is it imperative, and not a require
transformer?

Also, I kind of agree with Matthias here...sigh. :'( Like, as far as I can
tell, this is even worse then typed/racket/unsafe, as the optimizer is
still run. O_o



~Leif Andersen

On Thu, Sep 22, 2016 at 9:16 PM, Matthew Butterick  wrote:

> On Sep 22, 2016, at 9:23 AM, Matthias Felleisen 
> wrote:
>
> > I checked the calendar, because I thought I had gone into hibernation
> > and woken up on April Fool’s day.
>
>
> Those of us who have lived in New Hampshire take this matter quite
> seriously.
>
> We've also learned to endure the teasing of people who live in
> Taxachusetts.
>
> I raise a butternut munchkin to Jay.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] [ANN] New package: live-free-or-die

2016-09-22 Thread Matthew Butterick
On Sep 22, 2016, at 9:23 AM, Matthias Felleisen  wrote:

> I checked the calendar, because I thought I had gone into hibernation 
> and woken up on April Fool’s day. 


Those of us who have lived in New Hampshire take this matter quite seriously. 

We've also learned to endure the teasing of people who live in Taxachusetts.

I raise a butternut munchkin to Jay.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] [ANN] New package: live-free-or-die

2016-09-22 Thread Matthias Felleisen

I checked the calendar, because I thought I had gone into hibernation 
and woken up on April Fool’s day. 

Argh. 




> On Sep 21, 2016, at 10:33 PM, Jay McCarthy  wrote:
> 
> I've just put a new package on the server: live-free-or-die
> 
> This package lets you escape from Typed Racket's contracts.
> 
> --
> 
> Here's a little example:
> 
> Suppose that "server.rkt" is:
> 
> ```
> #lang typed/racket
> 
> (: f ((Listof Float) -> Float))
> (define (f l)
>  (cond
>[(empty? l)
> 0.0]
>[else
> (+ (first l)
>(f (rest l)))]))
> 
> (provide f)
> ```
> 
> And that "client.rkt" is:
> 
> ```
> #lang racket/base
> (require live-free-or-die)
> (live-free-or-die!)
> 
> (require "server.rkt")
> (f (vector 1 2 3))
> ```
> 
> Then this is what you get when you run the program:
> 
> $ racket "client.rkt"
> zsh: segmentation fault  racket "client.rkt"
> 
> For your convenience, `live-free-or-die!` is also aliased to
> `Doctor-Tobin-Hochstadt:Tear-down-this-wall!`
> 
> --
> 
> Enjoy!
> 
> -- 
> Jay McCarthy
> Associate Professor
> PLT @ CS @ UMass Lowell
> http://jeapostrophe.github.io
> 
>   "Wherefore, be not weary in well-doing,
>  for ye are laying the foundation of a great work.
> And out of small things proceedeth that which is great."
>  - D 64:33
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[racket-users] [ANN] New package: live-free-or-die

2016-09-21 Thread Jay McCarthy
I've just put a new package on the server: live-free-or-die

This package lets you escape from Typed Racket's contracts.

--

Here's a little example:

Suppose that "server.rkt" is:

```
#lang typed/racket

(: f ((Listof Float) -> Float))
(define (f l)
  (cond
[(empty? l)
 0.0]
[else
 (+ (first l)
(f (rest l)))]))

(provide f)
```

And that "client.rkt" is:

```
#lang racket/base
(require live-free-or-die)
(live-free-or-die!)

(require "server.rkt")
(f (vector 1 2 3))
```

Then this is what you get when you run the program:

$ racket "client.rkt"
zsh: segmentation fault  racket "client.rkt"

For your convenience, `live-free-or-die!` is also aliased to
`Doctor-Tobin-Hochstadt:Tear-down-this-wall!`

--

Enjoy!

-- 
Jay McCarthy
Associate Professor
PLT @ CS @ UMass Lowell
http://jeapostrophe.github.io

   "Wherefore, be not weary in well-doing,
  for ye are laying the foundation of a great work.
And out of small things proceedeth that which is great."
  - D 64:33

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.