Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
| creating:start [2025/03/29 14:11] – Moved introductory material from scanning tutorial into this page ahelwer | creating:start [2026/11/17 04:43] (current) – Fix stale recommendation not to read closures chapter ahelwer | ||
|---|---|---|---|
| Line 18: | Line 18: | ||
| Developing an intuition of what TLC is doing when it model-checks your spec will enable you to write specifications that make better use of its capabilities. | Developing an intuition of what TLC is doing when it model-checks your spec will enable you to write specifications that make better use of its capabilities. | ||
| And, if you reach the edge of those capabilities - well, you're well-placed to extend TLC to handle it! | And, if you reach the edge of those capabilities - well, you're well-placed to extend TLC to handle it! | ||
| + | |||
| + | This guide was written with the generous support of the [[https:// | ||
| + | |||
| + | ===== Table of Contents ===== | ||
| + | |||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| + | - [[creating: | ||
| ===== Overview ===== | ===== Overview ===== | ||
| Line 24: | Line 39: | ||
| There are two good reasons for this: | There are two good reasons for this: | ||
| - At time of writing, [[codebase: | - At time of writing, [[codebase: | ||
| - | - The high-quality free online textbook [[https:// | + | - The high-quality free online textbook |
| You will need to install the [[https:// | You will need to install the [[https:// | ||
| - | While all code artifacts can be produced entirely by reading this tutorial, if you get out of sync you can find working implementations in [[https:// | + | This tutorial requires Java 21 or higher, for the Java 16 [[https:// |
| + | While all code artifacts can be produced entirely by reading this tutorial, if you get out of sync you can find working implementations in [[https:// | ||
| The tutorial has you construct the TLA⁺ tools from the bottom up. | The tutorial has you construct the TLA⁺ tools from the bottom up. | ||
| Line 44: | Line 60: | ||
| Here is what our minimal language subset includes: | Here is what our minimal language subset includes: | ||
| - | * Named operator definitions | + | * Whole natural numbers |
| - | * Single-line comments like '' | + | * Boolean values |
| - | * Declaration of '' | + | |
| * Finite set literals, like '' | * Finite set literals, like '' | ||
| + | * Parentheses for expression grouping | ||
| + | * '' | ||
| + | * Single-line comments like '' | ||
| + | * The '' | ||
| + | * Some infix operators: '' | ||
| + | * The variable-priming suffix operator | ||
| * Quantification over sets with '' | * Quantification over sets with '' | ||
| * Function construction and application, | * Function construction and application, | ||
| - | * The '' | + | * Named operator definitions like '' |
| - | * Some infix operators: '' | + | * Declaration of '' |
| - | * The variable-priming suffix operator | + | |
| * Vertically-aligned conjunction & disjunction lists | * Vertically-aligned conjunction & disjunction lists | ||
| - | * The '' | ||
| - | * Whole natural numbers like '' | ||
| - | * Boolean values '' | ||
| Notably, we do not use the familiar '' | Notably, we do not use the familiar '' | ||
| Line 71: | Line 88: | ||
| The first two chapters are a nice introduction and overview of language implementation generally. | The first two chapters are a nice introduction and overview of language implementation generally. | ||
| Chapter three specifies a toy language called Lox, to be used as an object of study for the remainder of the book. | Chapter three specifies a toy language called Lox, to be used as an object of study for the remainder of the book. | ||
| - | Our minimal TLA⁺ subset has some similarity to Lox with regard to expressions involving integers and booleans, but also differences - you can skip the section on closures (unless you want to implement higher-order operator parameters yourself) and the section on classes. | + | Our minimal TLA⁺ subset has some similarity to Lox with regard to expressions involving integers and booleans, but also many differences - especially in their ultimate execution model. |
| What's important is that it's similar enough for all the fundamentals to still apply! | What's important is that it's similar enough for all the fundamentals to still apply! | ||
| Line 93: | Line 110: | ||
| </ | </ | ||
| - | Sometimes the code given here is so different from that provided by the book that highlighting is simply | + | Sometimes the code given here is so different from that provided by the book that highlighting is simply |
| A parenthetical will specify the meaning of highlighted code when ambiguous. | A parenthetical will specify the meaning of highlighted code when ambiguous. | ||
| To begin the tutorial, start at page [[creating: | To begin the tutorial, start at page [[creating: | ||
| + | [[creating: | ||