Has any of you used functional programming in production?

I'm really considering starting my next project either in Clojure or Haskell.

Attached: 1530443319112.jpg (1023x1024, 200K)

Other urls found in this thread:

aosabook.org/en/ghc.html
twitter.com/NSFWRedditImage

No. Functional programming is a meme.

i've never seen any of the code or worked on any of it myself, but i know that erlang is used in production by at least a few telecom companies

'moanads'

I had one project where I memed quite a bit with point-free functions and a Y combinator, and this stuff runs in production as we speak. It was ECMAScript, so it might not qualify as a functional language, but whatever.
>t. someone who enjoys FP

all of that shit and you can't even greentext properly.

Proper greentexting is a social construct

HAHAHAHA of course not, functional programming and recursions are meemes create by people who cant get a job

is that electric retard

functional programming is reatarded. For example, if an instance method has no side effects, it really doesn't need to exist as an instance method does it?
Also it's mostly a more convoluted way of saying hurr durr globals are evil
hurr durr goto is evil
hurr durr large inheritance graphs are evil
hurr durr qt et al must be evil because all of the above
WE PROUDLY PRODUCE SOFTWARE THAT DOESN'T DO ANYTHING!

>reatarded
Says the retard. Your vision of software is what makes modern applications so shitty and slow.

>fp
>instance method
this combination exists? ouside javascipt? for other purpose than namespacing?

Don't do Haskell. Anything Haskell does can Lua or Pascal do better.

I wasn't referring to the fp-gimped languages.
oh my a typo. fyi all my shit is fast

didn't write it myself but currently managing a Scala server and it's a pita because no one knows how to read this shit

here's roughly how a conversation with a colleague that has converted as a fp disciple overnight went
>but how can you have functions with 'no side effects' if all programs have state?
>Oh, well it's only inputs and outputs... you see...
>isn't that producing side effects?
>oh, well you control all the side effects and they cancel out or something
>So what, like it all goes in main() or something
>no, it's called a 'moenad'
>what's that
>I don't know yet

Attached: (You).jpg (491x307, 24K)

top kek. Best thing I've read all day. You, my fellow gentooman, need some mental help.

oop is industry standard, tried functional once and almost got fired for it.

>do blocks in haskell
>abandoning tab alltogether, just tap spaces everywhere because we are retarded
I was working on some simple program that was converting some values. I never worked in LUA in my whole life, I got it done in like half hour even though I had to basically learn what to do while doing it. In Pascal it was the same. Intuitive, works, good. In Haskell? After 2 months I can't get a fucking do block done because it isn't working like while -> do -> end, but it works on some stupid retarded meme mechanism while counting number of spaces because fuck you. Haskell is like getting fucked to ass and then bragging just so you can talk about it on Jow Forums.

friendly reminder that haskell only performs well on toy problems

The curry men fear the Haskell

Attached: adjoints.png (1200x486, 413K)

Dem Brits finally got their revenge.

meme in praxis, shame it's useless

>non-ascii characters in code
academic computer scientist detected

literally niggers, you can just wait and see, somebody will come up soon with functional language where emojis will be valid operators

(c c' ))

:-)))

>functional language where emojis will be valid operators
based

t. zoomer

That's not what you think it is. I forget what it's called, but some fonts support mapping to more visual characters. Like, you still have to insert '->' but the editor displays the unicode right arrow instead. I don't like it, I prefer to read what I write, but it's popular especially in the web dev community.

>popular in web dev community
>doing same shit in hasklol
>hasklol is not cancer
mkay

Ligatures?

I don't know what that is

Pattern matching and function clauses are nice syntax feature. First-class functions, anonymous and lambdas, closures, some notion of iterators is standard in modern imperative languages nowadays. Things like reducing global state or at least encapsulating it is a good practice in general,
I tried to do compiler in Standard ML, but could not make myself it enjoy it. Sure the type system is better than C in every way and mlton makes a blazing programs, but recursion and list comprehensions are not always easy to read and reason about compared to imperative equivalent and syntax kept failing on me with weird rules and structure.
Beside Erlang there isn't any that would excite me. And it was for everything but being FP.
I really hate writing and reading S-expressions (the good think I can say about them is that they are simple to write lexer/parser for) so never got into Lisps. I'm too brainlet to appreciate the mathematical beauty of type systems. I don't write critical software to make use of proof assistants.
And strictly typed FPs make a bad dynamic language (but some optional specs decorators can add the robustness).

how is parallelism support in Haskell?

yep

Cleanly separating data flow and side effects is really helpful in large-scale systems. I'm trying to move to Facebook right now to join one of their FP teams.

>guy comments on how functional programming allows the compiler to better optimise code
>doesn't mention that imperative is still going to be faster

>it's easy to parallelize computations
and they have a whole fucking language lmao

What do you mean, "in production"?
Of the billions of lines of code running in millions of companies, some are written in FP language (which FP retards claim as a success).

But no one is really using it for serious systems. Ask any FP retard and they'll mention an airline system from the 70s or "some bank" because a guy there once used OCaskell for two weeks to do some pricing shit.

Look at the actual examples: Jane Street, a financial trading firm like many others, is well-known for using OCaml, to the point where they end up pretty maintaining the compiler, run-time, etc. Does that sound like a sensible thing to do? The rest of the industry is using fucking Java or C++ with no issue (in fact, C++ won the International Conference for Functional Programming contest more often than either OCaml or Haskell...)

It's even worse for Haskell. When you ask Haskell tard what the largest thing written in Haskell is, they will inevitably mention the Glasgow Haskell Compiler. Congrats, retards, your language is self-hosting, now what?

If the promise of functional programming was true, i.e. it's a super-productive language used by elite programmers, we should see awesome video games, digital audio workstations, office suites, etc. written in those languages. But we don't. All this shit is written in C++ or C#.

This is the worst fucking meme about FP.
>It makes one thing super easy!
>Fails to mention that it makes ten other things more difficult.

>Glasgow Haskell Compiler
>Written in: Haskell and C
hmmm

Why not JavaScript?

I'm making a chat app server on Haskell, does that count?

FP is better for production, just by virtue that testing FP code is a lot easier and usually more powerful than on Imperative.

>abusing a dsl from the 90's intended for geocities sites
because not even op is that much of a faggot

Yes, and you chose to interact with the Jow Forums community, and thus can reasonaby be expected to understand and use Jow Forums constructs.

>a programming language which just works on every OS
>pretty much same code for desktop and web
JavaScript is ultimate language. Only a neet would use anything else.

>int

Attached: glaugh.jpg (500x370, 59K)

It just works.
Just like Apple products. JavaScript is as reliable.

1.0

is this bait?

Just do it. You people keep looking for success stories and give up on things when you don't find any, but people don't make success stories because they gave up.

Have you got any idea how shitty programming used to be in the past? It was utter shit. The languages were shit, the programs were shit, nobody had any discipline, people didn't even have basic shit like structs and functions/procedures back then. It was slow as SHIT. Commodore people would literally read programs off of magazines and type them into computers. Even so, people still wrote successful programs that worked and accomplished its purpose.

Do you seriously believe whatever FP language you like is worse than that? You could come up with some random language right now and I bet it'd be better than that. It's suitable for production. Just fucking use it, faggot. Stop doubting things and just use it.

its a meme my dude

what the fuck is a y combinator

No, this is Patrick.
>the typical bait

Getting paid to program VoIP in Haskell and C++.

It's mostly Haskell, the runtime itself is a mix of C and C-- (cee minus minus).
aosabook.org/en/ghc.html

I write some modules of our embedded c++ library in pure functional or atleast declarative style. Our chip has tons of overhead in memory and CPU time so I can do whatever I want in terms of design right now. Some parts are especially suited for it while others aren't

sometimes measure and refactor it down a step
functional -> declarative -> imperative

overall its fun; I have my own pure functional c++ libraries and personal projects with no mutation at all
I'd recommend anyone to write some stuff in it, opens up your mind a bit too

Attached: .png (676x780, 305K)

> Please abide by the Jow Forums CoC