4 ms·
I don't think it's fair to characterize this as "catching up". Both F# and C# are developed by an overlapping group of people at Microsoft. And, until recently,
by brandonbloom 13y ago
I don't think it's fair to characterize this as "catching up". Both F# and C# are developed by an overlapping group of people at Microsoft. And, until recently, the bulk of Haskell's GHC was done by SPJ in a closely collaborating group in Microsoft Research.
The correct characterization is to view this as a pipeline from a research language, to a specialists' language, to a common man's language.
Six years isn't really all that long to wait for a specialist feature to be 1) motivated 2) conceived 3) prototyped 4) validated 5) justified 6) implemented 7) tooled 8) released 9) marketed. Given that there are hundreds of ideas and only so much time, the "minus 100 points rule" [1] basically means that it's no easy feat for a feature like this to show up in a mainstream language. When you consider the quality bar, level of IDE integration, the magnitude of the education effort, and all the other odds and ends, it's something of a minor miracle.
[1]: http://blogs.msdn.com/b/ericgu/archive/2004/01/12/57985.aspx http://blogs.msdn.com/b/ericgu/archive/2004/01/12/57985.aspx
- MichaelGG 13y agoC# operates entirely differently, I understand. The IDE work is massive and necessary. Having said that, a lot of this stuff is "catching up" or implementing stuff from the 70s. To be clear, it's not like type inference or closures were invented with Haskell, F#, or C#. Stuff like that is pretty well-known PL stuff, isn't it? People would be upset if C# didn't have for loops; why aren't they upset the type inference is nearly useless?
- recursive 13y agoProbably because they don't know it's useless. I use and like C#. The type inference seems useful to me. Avoiding generic parameters on almost every linq extension method is a huge savings in comprehensibility. var x = new SuperDuperLongClassName(); is a nice savings in redundancy. Where can I see an example of useful type inference?
- MichaelGG 13y agoOff the top of my head, C# can't type infer: Fields, properties, parameters, return types, lambdas, generic type declarations, type constraints. I did a pretty fair line-by-line translation of a C# app to F#, and the F# version needed 1/20th the number of type annotations.
- pjmlp 13y ago> People would be upset if C# didn't have for loops; why aren't they upset the type inference is nearly useless? Because the existing type inference is good enough for the average enterprise programmer. You know, those guys with good enough CS grades, that just do what they are told and don't even know HN exists.
- recursive 13y agoIt's also good enough for some of us that do know HN exists.
- deleted 13y ago[deleted]
- mehwoot 13y agoPeople would be upset if C# didn't have for loops; why aren't they upset the type inference is nearly useless? Can you honestly not comprehend the answer to this? There are plenty of languages without type inference and shit gets done fine. People don't rely on it. People do rely on for loops.