Live data from Hacker News

Functional Programming Patterns

slideshare.net

21–30 of 70 posts

Re: Functional Programming Patterns

#22
Excellent presentation. Of the leading type safe functional languages (Haskell, F#, and OCaml) I find F# to be far and away the most accessible in terms of syntax and application.

Writing Scala in my day job currently (which, for the most part, I quite enjoy) but can see jumping ship if Microsoft's move to Linux is successful. Being able to develop and deploy F# applications on Linux with full blown Type Providers and decent IDE support? Pretty compelling combo, and that's just the tip of the iceberg.

Re: Functional Programming Patterns

#24

Some guy almost 20 years ago argued, that if you end up with a bunch of "design patterns" then your language is not good enough.) http://norvig.com/design-patterns/design-patterns.pdf

16 of 23 patterns have qualitatively simpler implementation in Lisp or Dylan than in C++ for at least some uses of each pattern

Things like this are literally why I switched from Python to Racket almost immediately once I discovered the latter. So much time spent fighting an imperative language to do something that seemed like it should just be easier in the first place.

Re: Functional Programming Patterns

#25

Some guy almost 20 years ago argued, that if you end up with a bunch of "design patterns" then your language is not good enough.) http://norvig.com/design-patterns/design-patterns.pdf

Most of these slides are about patterns that are provided for as functions by the language, or are otherwise obsoleted by the more powerful abstraction features of FP languages. The writers of this presentation are very much aware of the smell that is patterns.

Re: Functional Programming Patterns

#26
This is one of the reasons why Higher-Kinded Types are such a boon in the languages which have them. It allows you to translate "patterns" into straight-up libraries. This slideshow is good documentation for what the patterns are, but if you go use them in Haskell (e.g.) then you'll start to see that libraries are designed to completely contain that pattern and ensure compatibility between your use of it and others.

Usually this is achieved by representing the pattern exactly in the language. Usually the patterns are just maths. Usually math happily quantifies over higher-kinded types. Thus, you really want HKTs in your language.

And to be fair, Haskell does not go tremendously far in this direction. The languages which will truly profit from this are still in gestation.

Re: Functional Programming Patterns

#27

Excellent presentation. Of the leading type safe functional languages (Haskell, F#, and OCaml) I find F# to be far and away the most accessible in terms of syntax and application. Writing Scala in my day job currently (which, for the most part, I quite enjoy) but can see jumping ship if Microsoft's move to Linux is successful. Being able to develop and deploy F# applications on Linux with full blown Type Providers an…

Loving learning #F for educational purpose on my spare time and I am loving it, any idea of which is the market for this language or for what you should be use it?

Re: Functional Programming Patterns

#28

Excellent presentation. Of the leading type safe functional languages (Haskell, F#, and OCaml) I find F# to be far and away the most accessible in terms of syntax and application. Writing Scala in my day job currently (which, for the most part, I quite enjoy) but can see jumping ship if Microsoft's move to Linux is successful. Being able to develop and deploy F# applications on Linux with full blown Type Providers an…

Yeah, the idea of F# on Linux is very exciting. Visual studio has a lot to bring to the table, a lot of things that I've missed since I stopped working at an MS shop. I used to do a lot of work with F# and MSSQL, and have missed some of the ease of interopability since switching over.

Of course, I far far far prefer Linux in general terms, but the MS tooling is quite decent. eg. I still haven't found anything that even begins to compare to the MSSQL management studio.

Re: Functional Programming Patterns

#30
post #26

This is one of the reasons why Higher-Kinded Types are such a boon in the languages which have them. It allows you to translate "patterns" into straight-up libraries. This slideshow is good documentation for what the patterns are, but if you go use them in Haskell (e.g.) then you'll start to see that libraries are designed to completely contain that pattern and ensure compatibility between your use of it and others.…

> And to be fair, Haskell does not go tremendously far in this direction. The languages which will truly profit from this are still in gestation.

What are examples of taking it further?

Post reply on HN