Microsoft stealth launches 'historic' programming language

Hidden F# strikes right note

Launching a new language is easy - getting it used is hard. The combination of existing code and existing skills is a strong barrier to adoption, and even excellent languages like Ruby and Python have struggled to break out of their niches.

What hope is there for F#, the new language that Microsoft has sneaked into Visual Studio 2010, launched this month?

"I think it's an amazing moment," says its principal designer, Microsoft researcher Don Syme, an Australian now based in Cambridge. "It represents part of the history of programming language design and development here in the UK."

Perhaps it does. But you would not know it from most of Microsoft's marketing effort for the new Visual Studio. F# tends to get lost in the fuss about other new features. I downloaded Microsoft's Why upgrade to Visual Studio 2010? white paper and not only is F# missing from the "Top ten reasons to buy" - it's not actually mentioned at all.

That is a shame. F# is a functional programming language, and there are good reasons why functional programming deserves wider use, such as its suitability for the concurrent programming required for optimal performance on today's multi-core systems.

F# is also succinct. During a talk at the recent QCon London programming conference, Syme showed a series of slides, headed Pleasure and Pain, showing how F# code can be shorter and more expressive than its C# equivalent, sometimes to the extreme.

Following his QCon talk, I spoke to Syme about the new language. How did F# begin?

"I've been doing functional programming since 1992. I had been using the ML family of languages, including standard ML and OCaml, and wanted to see that paradigm being strong on the .NET platform. We started F# as a research project. We could experiment with the functional paradigm in practice, and understand where it was most beneficial and how it would fit in."

So how does F# differ from, say, OCaml?

According to Syme: "The core language of F# is heavily inspired by OCaml. If you look back at the ML languages, the core of these languages has been surprisingly stable, from the early seventies. It's a question of what you do around that. One of the major questions is about object-oriented programming. Another question is what you would historically have called module system design. F# differs on those design decisions from other ML languages because the aim is to build a language which integrates into the .NET component development model. That means we do embrace .NET object-oriented programming.

F# versus C #

F# can be remarkably concise compared to C#

"Another major design difference is with regard to parallel programming, where we embrace the idea of lightweight threads and what we call lightweight agents in the language and in the core language. We use techniques that come from Haskell for that purpose."

Speaking to Syme, Microsoft's main motive for including F# in Visual Studio becomes clear. Functional programming is popular in the financial community, where it is used for quantitative analysis. Finance is an important market.

"We find F# is very attractive to financial analysts and quantitative experts," says Syme, the reason being that it excels in data, parallel and algorithmic programming. "F# is attractive in places where the object oriented paradigm isn't a good fit for the kind of work that's being done," he says.

If F# is mainly intended for a specific programming niche, that would explain why Microsoft is not putting much energy behind promoting it. That said, it deserves more attention because of its suitability for the concurrent programming that has become necessary in order to take advantage of today's multi-core systems.

Other stories you might like

  • Stolen university credentials up for sale by Russian crooks, FBI warns
    Forget dark-web souks, thousands of these are already being traded on public bazaars

    Russian crooks are selling network credentials and virtual private network access for a "multitude" of US universities and colleges on criminal marketplaces, according to the FBI.

    According to a warning issued on Thursday, these stolen credentials sell for thousands of dollars on both dark web and public internet forums, and could lead to subsequent cyberattacks against individual employees or the schools themselves.

    "The exposure of usernames and passwords can lead to brute force credential stuffing computer network attacks, whereby attackers attempt logins across various internet sites or exploit them for subsequent cyber attacks as criminal actors take advantage of users recycling the same credentials across multiple accounts, internet sites, and services," the Feds' alert [PDF] said.

    Continue reading
  • Big Tech loves talking up privacy – while trying to kill privacy legislation
    Study claims Amazon, Apple, Google, Meta, Microsoft work to derail data rules

    Amazon, Apple, Google, Meta, and Microsoft often support privacy in public statements, but behind the scenes they've been working through some common organizations to weaken or kill privacy legislation in US states.

    That's according to a report this week from news non-profit The Markup, which said the corporations hire lobbyists from the same few groups and law firms to defang or drown state privacy bills.

    The report examined 31 states when state legislatures were considering privacy legislation and identified 445 lobbyists and lobbying firms working on behalf of Amazon, Apple, Google, Meta, and Microsoft, along with industry groups like TechNet and the State Privacy and Security Coalition.

    Continue reading
  • SEC probes Musk for not properly disclosing Twitter stake
    Meanwhile, social network's board rejects resignation of one its directors

    America's financial watchdog is investigating whether Elon Musk adequately disclosed his purchase of Twitter shares last month, just as his bid to take over the social media company hangs in the balance. 

    A letter [PDF] from the SEC addressed to the tech billionaire said he "[did] not appear" to have filed the proper form detailing his 9.2 percent stake in Twitter "required 10 days from the date of acquisition," and asked him to provide more information. Musk's shares made him one of Twitter's largest shareholders. The letter is dated April 4, and was shared this week by the regulator.

    Musk quickly moved to try and buy the whole company outright in a deal initially worth over $44 billion. Musk sold a chunk of his shares in Tesla worth $8.4 billion and bagged another $7.14 billion from investors to help finance the $21 billion he promised to put forward for the deal. The remaining $25.5 billion bill was secured via debt financing by Morgan Stanley, Bank of America, Barclays, and others. But the takeover is not going smoothly.

    Continue reading

Biting the hand that feeds IT © 1998–2022