There are many benefits to compiling application code including:
- Performance Compiled code is much faster than scripting languages such as ECMAScript or VBScript because it is a closer representation to machine code and does not require additional parsing.
- Security Compiled code is more difficult to reverse engineer than non-compiled source code because it lacks the readability and abstraction of a high-level language. Additionally, there are obfuscation tools that make compiled code even more resistant to reverse engineering.
- Stability Code is checked at compile time for syntax errors, type safety, and other problems. By catching these errors at build-time you can eliminate many errors in your code.
- Interoperability Because MSIL code supports any .NET language, you can use assemblies that were originally written in other languages in your code. For example, if you are writing an ASP.NET Web page in C#, you can add a reference to a .dll file that was written in Visual Basic.
- Multiple language support.
- Automatic compilation.
- Flexible deployment.
- Extensible build system.