Menu
Sign In Search Podcasts Libraries Charts People & Topics Add Podcast API Blog Pricing

Simon Peyton Jones

πŸ‘€ Speaker
962 total appearances

Appearances Over Time

Podcast Appearances

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

So it's nice pure int to int function or dirty int to int function.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

So you may say, perhaps you're about to say, that's a bit of a blunt instrument.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

Either completely pure or completely dirty, right?

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

It gets you an awfully long way.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

But nevertheless, it would be cool if you could say, oh, I am into effectful doing reading of files only int.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

So in the type, you'd like to say, what kind of effects can it have?

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

Can it throw exceptions?

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

Can it spawn new threads?

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

So you'd like to enumerate the effects this computation could have, right?

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

That will be cool.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

That's called an effect system.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

And there's, you know, a bazillion programming language papers about effect systems.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

And it turns out that you can indeed, in the type system of Haskell, and indeed OCaml is rapidly becoming the same, you can express not just all or nothing, does it do IO, game over,

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

but rather which particular effects does it do, including no effects at all.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

That's pure.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

A good place to start is a library called Bluefin, which my colleague Tom Ellis has designed.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

It's a very nice take on how to do effects systems in Haskell.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

Yep.

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

And because you have to thread, because the type system gets in your face, you were trying to

The Peterman Pod
Co-Creator of Haskell: Functional Programming, Thinking in Types, Useless Languages | Simon Jones

Like map, say.