News for hackers. Stuff that matters.
Re:Why is learning functional programming so damned hard? (2... by guerrilla on Sunday August 15, 2021 @10:42AM (#28189123)
I think it's more that you shouldn't use a tool that you're incompetent at. It has nothing to do with how common or not it is. Just know what you're doing or don't do it.
Re:Why is learning functional programming so damned hard? (2... by PragmaticPulp on Sunday August 15, 2021 @10:47AM (#28189183)
> I think it's more that you shouldn't use a tool that you're incompetent at. It has nothing to do with how common or not it is.

These two points are closely related, though.

Common tools will always have more available programmers, more documentation, more tutorials, more help, more libraries, more maturity.

We had a server written in a functional language at a company I worked at. It was fine, but when the two people who wrote it left the company it became a huge pain point to even hire someone to work on it. Consultants knew this and demanded exorbitant fees for basic work on the project.

Eventually we just rewrote it from scratch in a common language and saved a huge amount of time and money compared to trying to build teams and schedules around this obscure language.

Re:Why is learning functional programming so damned hard? (2... by cerved on Sunday August 15, 2021 @10:52AM (#28189223)
which language?
Re:Why is learning functional programming so damned hard? (2... by guerrilla on Sunday August 15, 2021 @01:51PM (#28190733)
> more documentation, more tutorials, more help, more libraries, more maturity.

Haskell's got all that but I can't argue with it needing more programmers.

Re:Why is learning functional programming so damned hard? (2... by AzzieElbab on Sunday August 15, 2021 @11:08AM (#28189356)
What if I told you that common languages are rapidly adopting futures from functional languages? Go being a notable exception.
Re:Why is learning functional programming so damned hard? (2... by PragmaticPulp on Sunday August 15, 2021 @11:51AM (#28189721)
> What if I told you that common languages are rapidly adopting futures from functional languages?

I use functional paradigms in mainstream languages. No need to be snarky or sarcastic.

That’s not what this article is about, though. Using Elm and Haskell for projects is not mainstream.

Re:Why is learning functional programming so damned hard? (2... by jatone on Sunday August 15, 2021 @09:05PM (#28193975)
id tell you duh, and go actually has (or will have soon) the pieces for the majority of the daily useful functional programming concepts. namely first class and polymorphic functions.
Re:Why is learning functional programming so damned hard? (2... by Jasper_ on Sunday August 15, 2021 @11:12AM (#28189402)
As far as I know, the Future concept for async/await started with Twisted's Deferred, which is a framework for Python. It's not really from functional land.
Re:Why is learning functional programming so damned hard? (2... by nextaccountic on Sunday August 15, 2021 @11:34AM (#28189582)
Futures were first proposed in 1976, in a book called "The Impact of Applicative Programming on Multiprocessing". [0]

Applicative programming is an older term for functional programming[1], but note this isn't pure functional programming like in Haskell; it's functional programming like in Scheme and Javascript.

[0] I can't find a pdf of the book, but it was mentioned here https://en.wikipedia.org/wiki/Futures_and_promises - the book calls it promises

[1] https://en.wikipedia.org/wiki/Applicative_programming_langua...

Re:Why is learning functional programming so damned hard? (2... by dragonwriter on Friday August 20, 2021 @10:15AM (#28246241)
> Futures were first proposed in 1976, in a book called "The Impact of Applicative Programming on Multiprocessing".

According to Wikipedia, Promises were, Futures (which are similar but not identical) were proposed in a 1977 paper. All of the closely related concepts of promises, futures, logic variables, and dataflow variables were used in functional languages first, and long before their use in, or the existence of, Twisted.

Re:Why is learning functional programming so damned hard? (2... by rowanG077 on Sunday August 15, 2021 @06:35PM (#28193188)
I don't think python invited a single thing tbh.
Re:Why is learning functional programming so damned hard? (2... by cerved on Sunday August 15, 2021 @11:27AM (#28189521)
futures have been around since the 80s afaik
Re:Why is learning functional programming so damned hard? (2... by AzzieElbab on Sunday August 15, 2021 @08:57PM (#28193934)
lol I meant to say "features", not futures. Sorry