Is there an Eclipse C# Highlight, Code Completion plugin - c#

I need an Eclipse 3 plugin for C# syntax highlight and hopefully code completion.
I am running both Mac and Windows versions of Eclipse.
I have evaluated "Improve C#" but it seems to be not working.

Have a look at Emonic. It is an Eclipse plug-in which allows you to build C# programs with Mono or Microsoft .NET.

Related

Do you know any nice interface for C# Interactive standalone?

You can open the C# Interactive window in Visual Studio to use C# as a scripting an shell language. Unfortunately, this requires you to have Visual Studio open all the time.
I know I can run csi.exe itself, but this does not give me any syntax highlighting or auto completion features.
How can I run the C# Interactive Windows standalone?
I would suggest LINQPad (I don't use it myself but I know this can do that kind of things). I think it's pretty powerful
https://www.linqpad.net/
VSCode has built in support for .NET Interactive Notebooks - if you don't see it, you can install the '.NET Interactive Notebooks' extension

.NET decompiler for Mac or Linux

I need to decompile a small application written in .NET and convert it to C++. I don't have Windows installed and I know there're a number of .NET decompilers for Windows. Since I have only Mac and Linux and don't want to install Windows only to be able to run a decompiler, I wonder, is there any easy way to decompile a .NET application in Mac or Linux? I searched for it and didn't find anything.
Since most of the parts of .NET is open-sourced, ILSpy also works with Linux and Mac.
From project GitHub page:
Decompiler Frontends
Aside from the WPF UI ILSpy (downloadable via Releases, see also
plugins), the following other frontends are available:
Visual Studio 2017/2019 extension marketplace
Visual Studio Code Extension repository | marketplace
ICSharpCode.Decompiler NuGet for your own projects
Linux/Mac/Windows ILSpy UI based on Avalonia - check out https://github.com/icsharpcode/AvaloniaILSpy
Linux/Mac/Windows command line client - check out ICSharpCode.Decompiler.Console in this repository
Linux/Mac/Windows PowerShell cmdlets in this repository
Since VS Code works with Linux and Mac, that front end should work in those operating systems too. Command line client should also work.
In addition, JetBrains has a new IDE for .NET, Rider. It works in Linux and Mac. Rider has a built-in decompiler. Unfortunately, this built-in compiler, dotpeek, is only available for Windows.
Another choice is to use mono decompiler, a tool from monoproject. Try to use it. Note that this is an add-in in MonoDevelop.
There's a variant/fork of ILSpy using Avalonia which is available as a packaged MacOS app.
Download from https://github.com/icsharpcode/AvaloniaILSpy/releases
There are instructions for whitelisting the package (which is unsigned) on the page, e.g.:
There is monodis in command line disassembler for IL in Mono.
It is possible to use it on Linux and macOS even if you already work with .NET 5 or 6.
However you have to install Mono.
You can decompile an EXE using built-in facilities within Visual Studio for Mac [if you are on OSX].
Here's a step by step walkthrough post I wrote!

Exception report component for VisualStudio C++ and C#

I'm using madExcept component in Delphi to catch unmanaged exception and create a full report with email capability.
What component (paid or free) with same features exist for C++ and C# compatible with Visual Studio.
Mandatory features:
Full report creation
email capability
Minor customization
None to minor source code modification
You can use (commercial) SmartAssembly - it has several features (obfuscation, dependency merging...) and comes with a similar capability regarding error/exception reporting with eMail/SOAP etc.
You can use any feature without activating the other features (no source code modification necessary although it comes with an SDK for customization if need be)... BUT it works only with .NET - so if you are not using C++/CLI then this tool only covers the C# part of your question...
(not affiliated just a happy customer)
For Visual C++ try open source CrashRPT for Windows, if your app is written in Visual C++. Doesn't work with C#.
You can try EurekaLog .Net edition, which is equivalent to MadExcept for Delphi and has .Net version for Visual studio.

C# plugin for Eclipse

Is there a good working plugin for C# in Eclipse? I'm using a Linux machine so I do not have access to Visual Studio Express. I already have an Eclipse Environment working perfectly for my needs so I don't want to deal with multiple IDEs if at all possible. It doesn't need code complete but highlighting and compiling would be nice.
Emonic is an actual eclipse plugin for C#: http://emonic.sourceforge.net/.
Here's a handy guide for how to get it set up: http://www.ibm.com/developerworks/library/os-eclipse-migratenetvs/
Monodevelop is great, but won't meet your requirement not to have to work in multiple IDEs.
I'm not sure about eclipse, but MonoDevelop is cross platform.
http://monodevelop.com/
From:
http://www.mono-project.com/Mono_For_Linux_Developers#Eclipse_in_C.23_Mode
Black-Sun
Emonic
eSharp
I don't personally have any experience with the mentioned plugins. Any C# development I've done on Linux has been through MonoDevelop
From Eclipse marketplace:
aCute: C# edition in Eclipse IDE
aCute enables C# application development in the Eclipse IDE.
aCute provides a rich C# editor with error reporting, hover, content assist, jump to references... (using OmniSharp) and syntax highlighting (using TextMate grammar).
aCute also integrates various operations of the dotnet command-line (New, Run, Test, Publish) as typical Eclipse IDE wizards and workflows.
aCute provide supports debugging for .NET applications.

Anders Hejlsberg's C# 4.0 REPL

During the last 10 minutes of Ander's talk The Future of C# he demonstrates a really cool C# Read-Eval-Print loop which would be a tremendous help in learning the language.
Several .NET4 related downloads are already available: Visual Studio 2010 and .NET Framework 4.0 CTP, Visual Studio 2010 and .NET Framework 4 Training Kit. Do you know what happened to this REPL? Is it somewhere hidden among examples?
I know about mono repl. Please, no alternative solutions.
The REPL demo was part of "what might happen next", i.e. after 4.0; in .NET 5.0 or something similar.
This is not 4.0 functionality, and never has been.
It's probably worth mentioning that the Mono project already does have a C# REPL which i tend to use for those small checks you do now and then. Take a look. Also, if I'm testing an idea which I'm uncomfortable Mono is going to handle to well and it's not worth starting a new test project then Snippet Compiler always comes in handy.
The Immediate window (Debug>Windows>Immediate Ctrl+D, I ) is fairly good replacement that's built in. It does require you start the IDE and put a breakpoint on something.
It does give you the context of where you would like to do experimentation.
Marc's answer is entirely correct, the possibility of a repl or script like c# has been discussed by Eric Lippert in two blog posts:
Why doesn't c# implement top level methods
It already is a scripting language
I would add that, the 2010 CTP does contain an f# repl (not much use for c# but if you were interested in some aspect of the BCL or CLR then it might be sufficient for your needs)
I find that LINQPad makes up for the lack of a REPL in many cases. It would be nice to get it integrated into Visual studio so you could interact with your existing code base more easily though.
Take a look at this C# REPL Script Environment which is a great way to quickly run C# script (and learn how to code)
I just published a VisualStudio Extension that provides a REPL environment inside VisualStudio (namely a C# REPL Environment with a Fluent API for .NET and VisualStudio)
In addition to being able to write and execute quick C# snippets (in a REPL environment), you can program VisualStudio IDE in real time!
You can install it using VisualStudio's Extension Manager (search for C# REPL) or via the download link at the VisualStudio Gallery page: VisualStudio C# REPL
The VisualStudio C# REPL page also contains more details and code samples.
There is also an Reddit thread on this extension (which contains more code samples).
Let me know what you think of it
Command-line REPL
To play with the C# REPL outside of Visual Studio, open the Developer Command Prompt for VS2015 and type the command csi to begin your interactive session. Here is a list of arguments that can be passed to csi.
Note: csi stands for "CSharp Interactive"
You can also open an interactive window directly from Visual Studio by navigating to View > Other Windows > C# Interactive.
Check out the Roslyn Wiki on the C# Interactive Window.
I found http://kamimucode.com/Home.aspx/C-sharp-REPL/1 . Which seems to be pretty good and I believe also exposes an API to evaluate expressions dynamically
To update on this old question c# REPL is now available as part of Visual studio IDE (starting VS 2015 update 1).
Introducing the Visual Studio 'C# REPL'
From time to time I want to try out some .NET API instead of wondering about C# language syntax. (There are far more subtleties in API than in the language itself.) If you are only looking for REPL for .NET, good old PowerShell is always with you.
C#:
using System;
using System.Text;
Convert.ToBase64String(Encoding.UTF8.GetBytes("Overflow"));
PowerShell:
[Convert]::ToBase64String([Text.Encoding]::UTF8.GetBytes("Overflow"))

Categories