Live data from Hacker News

F# is gaining independence from .NET

onurgumus.github.io

111–120 of 181 posts

Re: F# is gaining independence from .NET

#111
post #71

If F# ever got something akin to Scala Native, or Kotlin Native, I think it'd do really well. In my limited understanding of the F# ecosystem, I don't believe there are a lot of voices calling towards a multiplatform future beyond the NET world. Fable is cool, but native is a must-have for a lot of people, myself included. The docs are bad but not inexcusably so, it's a nice project within MS, I get it. The underlyin…

Well neither Scala Native, nor Kotlin/Native are examples of world changing projects, so thankfully F# hasn't gone down that route. In fact, Kotlin/Native is a poster child example of how not to design a language breaking the memory semantics with the rest of the eco-system.

Can you elaborate more on "In fact, Kotlin/Native is a poster child example of how not to design a language breaking the memory semantics with the rest of the eco-system."?

Re: F# is gaining independence from .NET

#112

Earlier quoted context omitted.

I've spent the past 3 months or so working with F# with zero .net experience - I love the language alot but yeah, you will eventually end up learning C# (not that that's a bad thing) if you want to use its extensive and powerful ecosystem. If you look at the MS documentation for .net, none of the examples are in F#. I guess that's okay since it probably wouldn't be idiomatic F#... but still, the docs have examples in…

Similar experience with Clojure, as well, one needs to know java to be reasonably productive with it.

I've been productive with Clojure for years and without needing anything from Java other than, say, a date library.

Re: F# is gaining independence from .NET

#113
post #100

Earlier quoted context omitted.

similarly to how C# is very much java.net ??

This is a bit inappropriate since for a long time now Java was busy catching up to C#. When Project Valhalla merges, Java's type system will become very close to what C# is now: reified generics and first-class value types. Algebraic data types will also come to town. But only after Project Loom merges, Java will be firmly ahead again with a fresh take on all matters async.

But C# was literally Microsoft's Java implementation that they forked after they were sued by Sun, was it not? So it is quite appropriate.

Re: F# is gaining independence from .NET

#114
post #112

Earlier quoted context omitted.

Similar experience with Clojure, as well, one needs to know java to be reasonably productive with it.

I've been productive with Clojure for years and without needing anything from Java other than, say, a date library.

Not everyone is writing toy personal projects.

Re: F# is gaining independence from .NET

#115

If F# ever got something akin to Scala Native, or Kotlin Native, I think it'd do really well. In my limited understanding of the F# ecosystem, I don't believe there are a lot of voices calling towards a multiplatform future beyond the NET world. Fable is cool, but native is a must-have for a lot of people, myself included. The docs are bad but not inexcusably so, it's a nice project within MS, I get it. The underlyin…

I think the best way to think about such things is in terms of niches and ecosystem. The niche of functional and native is small and already well served by Haskell, Ocaml and even Rust to an extent.

The .net, python and JVM contain some of the largest ecosystems. Even if small relative to C#, the niche size and health of a functional language on .NET is much larger than if it were another native langauge. Speed, documentation and tooling might not exactly match C#, but are excellent in comparison to other functional languages.

In a similar vein, niche size for a transpiled functional language is much larger, more so if the language prioritizes playing well with its parent ecosystem. There is room enough for Fable, Clojurescript, elm, purescript and Reason to co-exist.

Re: F# is gaining independence from .NET

#117

"...If you are sold with F# there is one important point to highlight. Do not treat F#, just another language with different syntax especially if you are familiar with Python, Ruby, JavaScript, C#, etc. You have to embrace functional programming as a paradigm...." I want to provide a little nuance around this, because I'd give the opposite advice. Because F# is based on OCAML and an extremely popular IDE/framework, i…

>functional messes are an order-of-magnitude worse than imperative/OO ones

I find them an order of magnitude easier and safer to refactor. And I have done it a few times with production messes I was not familiar with. Immutable values instead of variables and idempotent functions (those not having side effects) makes refactoring a joy and the if it builds it works mantra is pretty much true.

Re: F# is gaining independence from .NET

#119
post #44

If F# ever got something akin to Scala Native, or Kotlin Native, I think it'd do really well. In my limited understanding of the F# ecosystem, I don't believe there are a lot of voices calling towards a multiplatform future beyond the NET world. Fable is cool, but native is a must-have for a lot of people, myself included. The docs are bad but not inexcusably so, it's a nice project within MS, I get it. The underlyin…

Isn't F# pretty much OCaml.NET? So if you want native, you may also go with OCaml (or ReasonML if you prefer curly-delimited code blocks). For frontend dev't I really like Elm lately. (the article makes many refs to Elmish, the Elm-on-F# project).

> Isn't F# pretty much OCaml.NET?

Kinda yes, kinda no. There's a whole interesting story to it:

https://dl.acm.org/doi/pdf/10.1145/3386325

Re: F# is gaining independence from .NET

#120
post #86

Earlier quoted context omitted.

.NET has native ahead-of-time compile options that are getting better all the time. F# actually works better with these tools than other .NET languages because it is less reliant on reflection etc. to build its abstractions. You can write C bindings for F# libraries compiled this way.

I've toyed around on a weekend or two looking at the different ways to AOT stuffs for F#. Here is what I found: Same hello-world console app from C# runs alright with AOT. The F# does not as it relies on heavier reflection stuffs (at least thats what it seems like). The F# version did compile but just crashed on run. The suspect appears to be the way to console print seems to call a different non AOT function. The in…

Sounds like things have shifted since I last used it. Here's hoping they resolve this stuff soon!
Post reply on HN