mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-25 10:48:54 -06:00
(Tutorial) Fix to make calculator example compile
In abstract: startcat needs to be defined to run the commands that are shown later in the doc. In concrete: ss and SS are defined in Prelude.
This commit is contained in:
@@ -4200,7 +4200,8 @@ We construct a calculator with addition, subtraction, multiplication, and
|
|||||||
division of integers.
|
division of integers.
|
||||||
```
|
```
|
||||||
abstract Calculator = {
|
abstract Calculator = {
|
||||||
|
flags startcat = Exp ;
|
||||||
|
|
||||||
cat Exp ;
|
cat Exp ;
|
||||||
|
|
||||||
fun
|
fun
|
||||||
@@ -4226,7 +4227,7 @@ We begin with a
|
|||||||
concrete syntax that always uses parentheses around binary
|
concrete syntax that always uses parentheses around binary
|
||||||
operator applications:
|
operator applications:
|
||||||
```
|
```
|
||||||
concrete CalculatorP of Calculator = {
|
concrete CalculatorP of Calculator = open Prelude in {
|
||||||
|
|
||||||
lincat
|
lincat
|
||||||
Exp = SS ;
|
Exp = SS ;
|
||||||
|
|||||||
Reference in New Issue
Block a user