The VDM-SL Language Manual

The VDM-SL Language Manual - CSKSYSTEMSCORPORATION VDMTools...

Info iconThis preview shows pages 1–5. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: CSKSYSTEMSCORPORATION VDMTools The VDM-SL Language Manual ver.1.0 How to contact CSK SYSTEMS CORPORATION: http://www.csk.com/systems Web @ [email protected] General information The VDM-SL Language Manual 1.0 — Revised for VDMTools v8.2 c ⃝ COPYRIGHT 2009 by CSK SYSTEMS CORPORATION The software described in this document is furnished under a license agreement. The software may be used or copied only under the terms of the license agreement. This document is subject to change without notice The VDM-SL Language Manual Contents 1 Introduction 1 2 Conformance Issues 2 3 Concrete Syntax Notation 3 4 Data Type Definitions 3 4.1 Basic Data Types . . . . . . . . . . . . . . . . . . . . . . . . 4 4.1.1 The Boolean Type . . . . . . . . . . . . . . . . . . . . 5 4.1.2 The Numeric Types . . . . . . . . . . . . . . . . . . . . 7 4.1.3 The Character Type . . . . . . . . . . . . . . . . . . . 10 4.1.4 The Quote Type . . . . . . . . . . . . . . . . . . . . . 10 4.1.5 The Token Type . . . . . . . . . . . . . . . . . . . . . 11 4.2 Compound Types . . . . . . . . . . . . . . . . . . . . . . . . 12 4.2.1 Set Types . . . . . . . . . . . . . . . . . . . . . . . . . 12 4.2.2 Sequence Types . . . . . . . . . . . . . . . . . . . . . . 15 4.2.3 Map Types . . . . . . . . . . . . . . . . . . . . . . . . 18 4.2.4 Product Types . . . . . . . . . . . . . . . . . . . . . . 22 4.2.5 Composite Types . . . . . . . . . . . . . . . . . . . . . 22 4.2.6 Union and Optional Types . . . . . . . . . . . . . . . . 26 4.2.7 Function Types . . . . . . . . . . . . . . . . . . . . . . 28 4.3 Invariants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 5 Algorithm Definitions 31 6 Function Definitions 32 6.1 Polymorphic Functions . . . . . . . . . . . . . . . . . . . . . 36 6.2 Higher Order Functions . . . . . . . . . . . . . . . . . . . . . 37 7 Expressions 38 7.1 Let Expressions . . . . . . . . . . . . . . . . . . . . . . . . . 38 7.2 The Define Expression . . . . . . . . . . . . . . . . . . . . . . 41 7.3 Unary and Binary Expressions . . . . . . . . . . . . . . . . . 42 7.4 Conditional Expressions . . . . . . . . . . . . . . . . . . . . . 43 7.5 Quantified Expressions . . . . . . . . . . . . . . . . . . . . . 46 7.6 The Iota Expression . . . . . . . . . . . . . . . . . . . . . . . 48 7.7 Set Expressions . . . . . . . . . . . . . . . . . . . . . . . . . 49 7.8 Sequence Expressions . . . . . . . . . . . . . . . . . . . . . . 50 7.9 Map Expressions . . . . . . . . . . . . . . . . . . . . . . . . . 52 7.10 Tuple Constructor Expressions . . . . . . . . . . . . . . . . . 53 i The VDM-SL Language Manual 7.11 Record Expressions . . . . . . . . . . . . . . . . . . . . . . . 54 7.12 Apply Expressions . . . . . . . . . . . . . . . . . . . . . . . . 55 7.13 The Lambda Expression . . . . . . . . . . . . . . . . . . . . . 57 7.14 Is Expressions . . . . . . . . . . . . . . . . . . . . . . . . . . 58 7.15 Literals and Names . . . . . . . . . . . . . . . . . . . . . . . 59 7.16 The Undefined Expression...
View Full Document

This note was uploaded on 03/31/2010 for the course CAS 707 taught by Professor Ridhakhedri during the Spring '10 term at McMaster University.

Page1 / 172

The VDM-SL Language Manual - CSKSYSTEMSCORPORATION VDMTools...

This preview shows document pages 1 - 5. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online