Microsoft Corporation
May 2009
[This documentation targets the Microsoft "Oslo" May
2009 CTP and is subject to change in future releases. Blank topics are included
as placeholders.]
The Language Specification provides guidance on the
structure of the "M" language. NOTE:
This document includes the former "MGrammar" Language
Specification and SQL Mapping Specification documents.
The Microsoft "Oslo" Language Specification is the
authoritative source for "M" grammar and syntax. It contains detailed
information about all aspects of the language. The "Oslo" Modeling
Language (commonly referred to as "M") is a language for defining
domain models and languages (the latter are often referred to as textual DSLs).
"M" was created to allow developers to efficiently capture their
intention in a form that is natural to author but also efficient to store and
query using off-the-shelf database technology.
Download the complete
"M" language specification
Docx
Format
XPS
Format
PDF
Format
The "M" Language Specification is also available
in book form, published by
Addison-Wesley.
Sections:
Introduction to "M" – This section provides
an introduction to the fundamental concepts in "M".
Lexical Structure – This section defines
how Unicode characters are combined to form line terminators, white space,
comments, tokens, and pre-processing directives.
Text Pattern Expressions – Text pattern
expressions perform operations on the sets of possible text values that one or
more terms recognize.
Productions– A production is a pattern and an optional constructor.
Rules– A rule is a named collection of alternative productions.
Languages – A language is a named
collection of rules for imposing structure on text.
Types – This section
describes how both intrinsic and derived types are defined and used within the "M"
language.
Computed and Stored Values – This section
describes the definition and scope of computed values and stored values (a.k.a.
fields).
Expressions – This section defines
the syntax, order of evaluation of operands and operators, and meaning of
expressions.
Modules –Modules in "M"
contain declarations of types, extents, and computed values.
Attributes – Attributes provide
metadata which can be used to interpret the language feature they modify.
Catalog – This section contains
a definition of the "M" Catalog using "M" itself.
SQL Mapping – This section
describes the SQL the “M” compiler emits for all supported syntax, and calls
out what “M” features are unsupported in SQL compilation.
Glossary – This section provides
the definition of words used elsewhere in the specification.