News for hackers. Stuff that matters.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by surban on Tuesday October 15, 2019 @04:12AM (#21256474)
> My wishlist for C# is short: [...]

F# provides all of them, is shipped with .Net Core 3.0 and also works great on Linux.

Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by tonyedgecombe on Tuesday October 15, 2019 @06:13AM (#21257075)
It doesn't give you structural typing, it's still normative:

https://stackoverflow.com/a/3137561/57094

Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by goto11 on Tuesday October 15, 2019 @08:17AM (#21257630)
Nominative, not normative. Nominative means "by name", i.e. you reference types by names. A structural type (aka anonymous type) does not have a name, so cannot be referenced.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by tonyedgecombe on Tuesday October 15, 2019 @08:27AM (#21257687)
Yes, I meant nominative.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by mmavnn on Tuesday October 15, 2019 @10:12AM (#21258521)
It also has syntax for structural typing where needed.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by nbevans on Wednesday October 16, 2019 @03:32AM (#21267974)
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by jeswin on Tuesday October 15, 2019 @04:48AM (#21256665)
Works for personal projects and is certainly a joyful experience. But recruiting developers is near impossible - which is key for the kind of projects/companies I work with.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by jen20 on Tuesday October 15, 2019 @05:30AM (#21256858)
I've heard this before, and frankly, it is not something I recognise.

A few years back, I was the VP of Engineering at a (now well-known) startup that had chosen to use .NET (on Azure, which is a whole other story). Everything was written in F# by default, _occasionally_ branching out to C# or C++ if it was proven that F# was unsuitable for the job.

We managed to hire a very large team in comparatively little time - and because people who apply for F# jobs either know it (indicating someone interested in looking forwards in the industry), or were interested in learning it (we provided training), quality was better and waste was substantially less overall than I have seen elsewhere in a rapidly scaling team.

Despite what Microsoft may think, F# is the crown jewel of the .NET world, and it is a mistake to sideline it over fears such as this.

Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by FpUser on Tuesday October 15, 2019 @05:12AM (#21256776)
What's the problem asking experienced developer to learn F#? That is course assuming they do not refuse the work?
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by jeswin on Tuesday October 15, 2019 @05:26AM (#21256841)
Team dynamics in large companies can be quite challenging. In addition, whoever made that decision might become responsible for project delays, inability to hire, people writing bad code, destroying work-life balance etc. And not just you, everyone up the chain will get blamed for choosing a programming language with a near-zero market share.

Generally large companies and enterprises are resistant to change, and my advice will be to just ask for enough room to get the project executed somewhat within budget and schedule.

Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by gameswithgo on Tuesday October 15, 2019 @09:02AM (#21257904)
At Olo, which is primarily a C# shop, people have been excited to learn F#, and able to pick it up on an as needed basis. We are pretty large and it has been fine. It helps quite a bit that it is a different language but part of the same ecosystem. It is quite a bit easier to manage than it would be adding say, Go, or Rust or something into the company, with entirely new tooling and libraries. for instance a visual studio solution can contain C# and F# projects, and they can refer to each other.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by FpUser on Tuesday October 15, 2019 @07:42AM (#21257481)
Your original point was about inability to recruit developers. That is why I asked. From my experience it was never a problem for seasoned developer to get a grip on new language barring few very exotic cases. I completely understand other factors in enterprise.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by Scarbutt on Tuesday October 15, 2019 @04:11PM (#21263157)
F# is a nightmare you want to use asp.net core.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by akra on Wednesday October 16, 2019 @05:21PM (#21275888)
In a previous role some time back used F# on top of ASP.NET Core. It isn't that bad and people thought the code was quite clean in the end; we had dev's thinking going back to C# even with F# using vanilla ASP.NET would be a downgrade. There's ways to mitigate the pain of the C# specific API. We went the vanilla ASP.NET Core route (for Swashbuckle) and found only the Startup class (which could be replaced by functions in hindsight) and the Controllers (which were still clean code wise) needed to be classes. The rest (majority) of the program was typical F# code with an interfaced object usually created via an F# object expression put into ASP.NET's dependency injection. Helped to separate the web controllers from the logic layer anyway and keep the ASP.NET code to a minimal. Most of the program was written in F# style with ASP.NET used just as a web server for functions basically.

There's just few public examples on how to do this cleanly so people kinda have to work it out themselves which I think could be improved.

Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by TomasJansson on Wednesday October 16, 2019 @03:48AM (#21268033)
What do you base that on? I have had no problem with F# and asp.net core. Just look at safe stack, it uses saturn or giraffe which in turn runs on asp.net. https://safe-stack.github.io/
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by Scarbutt on Wednesday October 16, 2019 @12:07PM (#21271929)
That this abstractions exists on top asp.net core to make things more ergonomic proves my point.
Re:.NET Core 3.0 Concludes the .NET Framework API Porting Pr... by Horusiath on Thursday October 17, 2019 @04:57AM (#21280108)
No, it only proves that C# and F# are two different languages.