Chapter 8. The Common Language Runtime

The Common Language Runtime (CLR) provides a runtime environment that manages the execution of code and provides services such as security, versioning, and garbage collection. Metadata about our programs is generated during compilation. The runtime environment uses this metadata to locate and load classes, lay out objects in memory, and so on.

When we build our programs or components, both metadata and code are stored in self-contained units called assemblies. An assembly stores information about the components and resources against which it is compiled, as well as the types defined within it. The CLR accesses this information to guarantee that the application has the correct versions of its dependencies. ...

Get C# Primer: A Practical Approach now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.