How stable is the Roslyn CTP as a replacement for dummy console apps?

限于喜欢 提交于 2019-12-10 15:44:27

问题


I frequently find myself making a dummy console app to test something simple out. (For example how does DateTime.Parse like a YYYY-MM-DD-HH-MM-SS formatted string?)

I know that Roslyn has the C# interactive window to allow such simple tests to be run in the IDE with my solution still open. This is the only feature I am really wanting.

But how stable is Roslyn CTP? Is it going to mess up my IDE? Slow me down when I am not using it? Is it only used for the Roslyn features? Or is it going to try to replace my normal compiler for my open solution?


回答1:


Unless you run VS with -rootSuffix Roslyn, the CTP will not change any existing behavior.




回答2:


As SLaks says, the Roslyn CTP doesn't generally affect your IDE for existing scenarios. The changes you should see if you install it are:

  1. A new C# Interactive tool window.
  2. Support for "C# script" files (.csx), using the Roslyn IDE services. However, .cs and .vb files and projects still use the existing code.
  3. Some new project templates for targeting Roslyn.
  4. Some additional items in the Add References dialog for targeting Roslyn
  5. Documentation, etc in the Roslyn directory under your My Documents folder.

Disclaimer: I work for Roslyn on the Roslyn project.




回答3:


Try the C# REPL Script Environment that is part of the O2 Platform

It will give you a perfect environment to try out all C# features and APIs (conceptually the O2 REPL environment is similar to LinqPAD)

On the topic of Roslyn, take a look at these Multiple Roslyn based tools (all running Stand-Alone outside VisualStudio) , the first one is a simple Roslyn REPL



来源:https://stackoverflow.com/questions/8057096/how-stable-is-the-roslyn-ctp-as-a-replacement-for-dummy-console-apps

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!