Using the Scripting API
So far, all the C# code you've seen hasn't been any different from what you've been able to do in C# since version 1.0. That is, you still write C# code, you compile it, and an assembly is generated. Although having the inner workings of the compiler available for public consumption via the Compiler API empowers developers to analyze and transform their code, nothing has substantially altered the flow of the compilation process. However, that changes with the Update 1 release of Visual Studio 2015, because within the Compiler API is a brand-new Scripting API. With the Scripting API, C# can be treated as a scripting language. In this chapter, I'll show you how to use the Scripting API to provide a dynamic way to augment applications. But before we do that, let me briefly define what a scripting language really is.