Live data from Hacker News

Why F# could be the next mainstream programming language (2024)

blog.snork.dev

61–70 of 99 posts

Re: Why F# could be the next mainstream programming language (2024)

#61
post #60
post #28

F# is a chimera of a language. The functional parts of the language are nicely designed: no nulls, discriminated unions (ADTs), you write simple functions in simple modules and there is nothing that is too clever to understand: it's very pragmatic. Then there is a whole lot of stuff like inheritance, classes, interfaces, nulls mainly there for dotnet interoperability that gets very ugly very fast. There are way too m…

> There are way too many variants of the same thing: records, classes, struct records, tuples, struct tuples etc, [...] > At the end I went with Rust because it has one way of doing such stuff. I haven't looked at C# in 20 years, but Rust certainly has a LOT of ways to do similar things too: struct Foo { x: f64, y: f64 } // Struct struct Foo(f64, f64) // Tuple Struct let f = (1.0, 2.0) // Tuple enum U { Foo(f64, f64)…

Heh, I just remembered that Rust has like 6 or 7 ways to do strings too.

Re: Why F# could be the next mainstream programming language (2024)

#62
post #11

Earlier quoted context omitted.

Not only. I don't want to use Microsoft technologies unless forced to or no better alternatives (GitHub/ vscode)

If you feel forced to use vscode due to "lack of better alternative" but then stop at using .NET, then you're really missing out on tools that lack better alternatives. .NET has spoiled me so badly with C#, NuGet, and the debugger that I just don't have the patience for any other languages with their half-assed build systems, janky package managers, and after-thought debuggers. MSBuild and the dotnet CLI tool may not…

> Every .NET project I've worked on in the last 15 years I could pull from the repo and build-and-run immediately. I can't really say that for almost any other platform.

Definitely not for any NPM project. At work when we didn't touch a project for half a year it was impossible to build due to some changes in dependencies. They require continuous maintenance.

Re: Why F# could be the next mainstream programming language (2024)

#63

I think, we’re not far from the day when LLMs will be spitting out highly optimized ilasm/byte-code (dotnet intermediate language representation). So your programming language will well and truly be a bunch of prompts. That’s it.

How to you review the resulting bytecode? Or will you just go on running it blindly on some computer on the Internet?

Re: Why F# could be the next mainstream programming language (2024)

#64
I would be very reluctant to use it because of the fear that at some point Microsoft just kills it. You have to wonder why they are keeping it alive so long as they are probably getting not much value out of it (some people here say they are using it as a testbed for functional features in C# but I don't believe this - I guess the C# team has enough resources to do their explorations on their own). I guess if Don Syme leaves Microsoft or retires that will be the end of it.

Re: Why F# could be the next mainstream programming language (2024)

#65
Speaking as a C# developer, who had in the past wanted to learn F#, but never got very far. What discourages me every time:

- C#'s good enough. Nothing's stopping you from writing functionally-oriented code in C# (and I do prefer that over traditional "enterprisey" object-orientation.)

- It's relatively difficult to have a codebase that is partly in C# and F# for incrementally trying things out. (I understand this is not really F#'s fault, owing to the .NET compilation model where C# and F# compilers each produce their own assemblies. And that Microsoft hardly cares about F#, and the tooling leaves a lot to be desired - admittedly I'm spoiled by C# tooling. )

- F# having its own implementations of concepts like async, option types introduces friction with C# obviously. I get that F# async is more powerful in some ways, but then again... F#'s option type is a reference type unlike C#'s Nullable value type, it's hard to see what's the advantage in that other than worse performance. One almost gets the impression that F# designers don't care about performance (while C# designers do in the past few years with additions to the ecosystem like Span). This makes it hard to justify coding in F# for infrastructure libraries (which is what I often do).

Re: Why F# could be the next mainstream programming language (2024)

#66

Earlier quoted context omitted.

The very first advantage listed is actually a disadvantage for 95% of developers. “Wedded to the dotnet ecosystem.”

Nonsense, .NET is one of the best ecosystems available. Your sentiment is one I tend to hear mostly from people who think it's still .NET Framework and Windows only

There’s nothing wrong with dotnet. There’s lots wrong with being forced to use nothing else.

Re: Why F# could be the next mainstream programming language (2024)

#67
post #35

Earlier quoted context omitted.

If you feel forced to use vscode due to "lack of better alternative" but then stop at using .NET, then you're really missing out on tools that lack better alternatives. .NET has spoiled me so badly with C#, NuGet, and the debugger that I just don't have the patience for any other languages with their half-assed build systems, janky package managers, and after-thought debuggers. MSBuild and the dotnet CLI tool may not…

> NET has spoiled me so badly with C#, NuGet, and the debugger that I just don't have the patience for any other languages with their half-assed build systems, janky package managers, and after-thought debuggers. Rust and cargo are pretty good and only getting better. I don't really see a good use case for anything dotnet when JVM exists

To be fair dotnet is much better than JVM, mainly from having learned from Java’s mistakes.

I don’t want to use either though.

Re: Why F# could be the next mainstream programming language (2024)

#68

Functional programming people have been hoping for their favorite functional language to go mainstream for a long time but it never happens.

Every now and then one starts to rise up ... XSLT, Scala, etc. But for some reason, it never makes it all the way to the mainstream.

Re: Why F# could be the next mainstream programming language (2024)

#69
post #51
post #47

This feels like "This year is the year of Linux on the Desktop" I've been hearing about F# hitting mainstream for over a decade. Unlike Linux, which is now fairly popular on the Desktop, I predict that F# won't ever be mainstream.

not to get into this debate, but linux is far from mainstream

(he types from his android phone)
Post reply on HN