Because it’s great, and people that think otherwise are dead to me.
Curried functions combined with that magnificent pipe operator, overlaid on the .NET runtime. Don Syme et al knocked it out of the park. It's the one programming language that changed how I think about programming. I'm only talking about the version before type providers. Then it got messy. Before that, we could (and I did) recompile fsi.exe to do some custom prompt manipulation. It was a slog, but it worked, but the…
Why F#?
241–250 of 424 posts
Re: Why F#?
#242Earlier quoted context omitted.
You don't really need to split 1 & 2, since F# can define .NET interfaces and abstract classes just fine. For that matter, you don't even need the interfaces if you wouldn't have had them in a C#-only solution. Just define the class in F# and use it directly from C#. You still need a separate assembly for F#, but that doesn't imply dependency injection - again, just reference it and use it.
I've identified a possible use case for F# in a preexisting product; I'm looking for the simplest way to integrate F#.
Re: Why F#?
#243Does anyone else find interesting that people who write blog posts saying "my favourite language is X", it's never a mainstream language..?
C++ intersected the mass of C programmers with the new OO fad, and kept all of C's warts. Had Stroustrup made C++ better, he wouldn't have an army of adopters who already knew C. Maybe merit will win out in the long run [1]? I'm not hopeful.
Java needed to be close enough to C++, and C# to Java. And Brendan Eich joined Netscape to "put Scheme in the browser".
[1] https://www.theregister.com/2025/03/02/c_creator_calls_for_a...
Re: Why F#?
#244Earlier quoted context omitted.
Apache Spark, Delta Lake are written Scala. Being JVM based, it has a large ecosystem. Scala seems like a better choice than F#.
I'm sure it can be the better choice, but for me it was not. It seems there was some incompatibility between me and Scala. I find it such a complex language and I never managed to wrap my head around it. As I said F# was my last choice at the start of my evaluation, and Scala was high on the list due to the Java ecosystem. But in the end it didn't work out for me. F# on the JVM would be great though!
Re: Why F#?
#245Earlier quoted context omitted.
I'm sure it can be the better choice, but for me it was not. It seems there was some incompatibility between me and Scala. I find it such a complex language and I never managed to wrap my head around it. As I said F# was my last choice at the start of my evaluation, and Scala was high on the list due to the Java ecosystem. But in the end it didn't work out for me. F# on the JVM would be great though!
It runs on .NET, for god's sake. This is not a small platform.
Re: Why F#?
#246Earlier quoted context omitted.
Apache Spark, Delta Lake are written Scala. Being JVM based, it has a large ecosystem. Scala seems like a better choice than F#.
I think Clojure is the better option if you want to do FP using the JVM ecosystem. The problem (for me, anyway) I've run into with Scala is that it supports both functional programming and object-oriented programming. Every code base I've worked on in Scala has ended up being a hodgepodge of both, which I find annoying. However, the best functional programming language is, of course, Elixir. :D
Re: Why F#?
#247Earlier quoted context omitted.
A language is just as much about what it can't do, then what it can do.
Can you elaborate on what you mean by this? I assume you are implying that too many choices could confuse a junior developer, which I agree with. However, I don't think this is a concern in the bigger picture when talking about the space of all languages.
For example, C# may have cribbed the language features, but F# is expression based and immutable by default. Try using the same features in this context and the whole game changes.
Re: Why F#?
#248Earlier quoted context omitted.
As far as fluency goes, that’s not very impressive. %w{Peter Julia Xi}.map{"Hello, #{it}"}.each{puts "#{it}! Enjoy your Ruby"} That’s of course trivial examples. And while Ruby now have RBS and Sorbet, it’s yet another tradeoff compared to a syntax that has upfront static analysis as first class citizen in mind. That is, each language will have its strong and weak points, but so far on "fluency" I’m not aware of anyt…
Ruby is dynamically typed, which makes "fluent" API design that much easier at the cost of maintainability elsewhere. If you want to compare apples to apples, you need to compare F# to other statically typed languages.
Re: Why F#?
#249This is a practical side of F# that doesn’t get enough spotlight — but one I’m using daily.
Re: Why F#?
#250Earlier quoted context omitted.
"As far as I can tell F# is one of those things where every single user is extremely happy" Isn't it because language has rather small community of passionate people, who are devoted to their language of choice? F# popularity is somewhere between CHILL, Clipper and Raku langs, that are probably as obscure as F# for typical software dev.
I know Raku from Perl fame, and F# because it’s Microsoft, but CHILL and Clipper are totally new to me, so in my own humble experience these two latter look far more obscure. :D