Share via


Introducing the Microsoft “Roslyn” CTP

By Kevin Pilch-Bisson

As Soma mentioned earlier, today we’ve made a Community Technology Preview (CTP) available for download! The Roslyn project is a forward looking effort to make the wealth of language understanding that the compiler generates available to developers in other scenarios. A number of us have been working hard on getting enough of these pieces put together to have something to share with you, and we’re thrilled to be able to do that today.

The foundation of this work is a new C# compiler, written in C# (and a new VB compiler written in VB too, see the VB Team blog for details). This compiler is written as a library that exposes a rich public API. Next up is a new language service written purely using that public API and exposing its own extensibility points to allow 3rd parties to do amazing things inside Visual Studio with that language understanding.

Resources

The Visual Studio blog gives a good overview of the various pieces that the CTP installs, but I thought I’d use this space to look at a little more code that uses the API.

The Roslyn MSDN page contains pointers to an overview document that explains the basic concepts in the Roslyn API in greater detail. There are also several guided walkthroughs that each dive deeper into a particular area of the API. Finally if you install the CTP, there are numerous samples installed to the “My Documents” folder that you can build, run and experiment with.

Watch this space in the next few weeks for a series of posts that will each explore one bit of the API.

Feedback

We’re very interested in your feedback about the Roslyn project! Because it’s early in the project we’re most interested in feedback about the API and general direction. Please get involved in the discussion about Roslyn on our forums. You can also file bugs on our Connect site. Finally, some of the team members are also on Twitter, and will be keeping an eye on the #RoslynCTP hashtag if that is more convenient for you.

Disclaimer

Please note: This is a technology preview and there are known limitations. While the shape of the public API surface is complete, only a subset of the C# and Visual Basic languages have been implemented at this time in the current CTP.

About the author

Kevin is a Development lead at Microsoft responsible for the C# and VB language services in Roslyn. He’s been at Microsoft for 9 years, and has spent all of it working in the language and IDE space. Kevin is a graduate of the University of Waterloo. He used to blog at https://blogs.msdn.com/b/kevinpilchbisson, but has been spending more time on Twitter (@Pilchie) and on getting Roslyn into your hands lately.

Comments

  • Anonymous
    January 06, 2012
    The comment has been removed

  • Anonymous
    January 06, 2012
    Hi Pazu, You're right that the Roslyn CTP ends up taking over that keyboard shortcut.  We did this because our telemetry showed that Ctrl+Enter was one of the least used shortcuts in all of Visual Studio.  Unfortunately, there was no way to remove the existing binding without changing Visual Studio itself, so Roslyn ends up taking over the shortcut again every time it starts up. In the long term, we will likely modify Visual Studio so that Ctrl+Enter is not bound to OpenLineAbove by default, at which point you'll be able to configure it how you want in Tools->Options->Environment->Keyboard.  For now, the following macro should help to reset the shortcut each time VS starts up:    Private Sub DTEEvents_OnStartupComplete() Handles DTEEvents.OnStartupComplete        DTE.Commands.Item("Edit.LineOpenAbove").Bindings = New Object() {"Text Editor::CTRL+ENTER"}        DTE.Commands.Item("Edit.LineOpenBelow").Bindings = New Object() {"Text Editor::CTRL+SHIFT+ENTER"}    End Sub Finally, we haven't actually seen an exception in our testing - could you provide more details about what you are seeing in an email to kevinpi@microsoft.com? Thanks -- Kevin Pilch-Bisson

  • Anonymous
    April 17, 2012
    great blog! Thank you for raising this question! Our standards in MA require state sites to work without Javascript, but it’s getting harder to defend for web-based applications. Accessible Javascript is much more usable-for everybody-than the unenhanced HTML in more and more situations.

  • Anonymous
    June 01, 2012
    C# is not a real language! your program will never work until the .net framework has been installed on the  machine. It is not able to create standalone exe even in Windows. For me c# is like scripting language!

  • Anonymous
    June 05, 2012
    Wow Jef Adams. It's just like Java.

  • Anonymous
    December 29, 2013
    Take a look at qinjection.codeplex.com I'm developping it using Roslyn API. There is still work to ... so any comments will be accepted.