Common Intermediate Language

Common Intermediate Language (CIL) is a low-level programming language defined by the Common Language Infrastructure (CLI) specification and is used in both the .NET Framework and Mono. This Wikibook is meant to be both an introduction to CIL and a useful reference.

Contents

 * Getting Started : Writing and compiling a simple "Hello, World!" program.

Basics

 * Basic Syntax : The basic syntax of CIL.
 * Variables : Creating and using variables.
 * Methods : Declaring and calling methods.
 * Exception Handling : Catching and throwing errors.

Instructions

 * Stack
 * Arithmetic
 * Control Flow
 * Logic

Classes and Objects

 * Classes
 * Visibility Modifiers
 * Enumerations
 * Interfaces
 * Value Types
 * Attributes
 * Namespaces
 * Inheritance
 * More Modifiers
 * Generics
 * Garbage Collection and Object Lifetimes

Advanced Topics

 * Code Generation
 * Marshalling and Unmanaged Code