You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/docs/heyvl/README.md
+1-15Lines changed: 1 addition & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,24 +9,10 @@ The main innovation is that it supports _quantitative_ reasoning via its constru
9
9
Refer to our [publications](../publications.md) for details on the theory.
10
10
11
11
A HeyVL file consists of a sequence of declarations: [procedure](./procs.md) and [domain declarations](./domains.md).
12
+
Refer to those for more information.
12
13
13
14
```mdx-code-block
14
15
import DocCardList from '@theme/DocCardList';
15
16
16
17
<DocCardList />
17
18
```
18
-
19
-
## Use the source, Luke
20
-
21
-
We do not formally describe the syntax of HeyVL in this documentation.
22
-
You can find a more formal definition in the [`src/front/parser/grammar.lalrpop`](https://github.com/moves-rwth/caesar/blob/main/src/front/parser/grammar.lalrpop) file that specifies the syntax used to generate Caesar's parser.
23
-
It is written in the [LALRPOP language](https://lalrpop.github.io/lalrpop/tutorial/index.html).
24
-
25
-
## Examples
26
-
27
-
The [`pgcl/examples-heyvl`](https://github.com/moves-rwth/caesar/tree/main/pgcl/examples-heyvl) directory contains the machine-translated HeyVL code for our pGCL examples.
28
-
Note that they are just sequences of HeyVL statements without wrapping procedure declarations.
29
-
Refer to the page on the [pGCL frontend](../pgcl.md) for more information.
30
-
31
-
Caesar's integration tests in [`tests/`](https://github.com/moves-rwth/caesar/tree/main/tests) can also serve as a reference.
32
-
Refer to the [development guide](../devguide.md#caesar) for more information about these tests.
Copy file name to clipboardExpand all lines: website/docs/heyvl/procs.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,9 @@ Let us decompose the example into its parts:
48
48
3. We have one **output parameter**`x` of type [`UInt`](../stdlib/numbers.md#uint).
49
49
- There may be multiple parameters (input and output), which can be separated by commas (e.g. `init_x: UInt, init_y: UInt`).
50
50
4. The `pre` declares the **pre-expectation**`init_x + 0.5`. It is evaluated in the *initial state* (when calling the proc). This is why it is called "pre" (= before running the proc).
51
+
- The `pre` is an expression of type [`EUReal`](../stdlib/numbers.md#eureal) over the input parameters.
51
52
5. The `post` is the **post-expectation**`x` and evaluated in the final states of the proc (post = after running the proc). We always compare its expected value against the pre.
53
+
- The `post` is an expression of type [`EUReal`](../stdlib/numbers.md#eureal) over the input and output parameters.
52
54
6. The **body of the proc** assigns `init_x` to `x`. We then do a [probabilistic coin flip](../stdlib/distributions.md#symbolic-with-probabilities) and assign `true` to `prob_choice` with probability `0.5` (and `false` with probability `0.5`). It determines the expected value ($\mathbb{E}$) we look at.
53
55
- See [documentation on statements](./statements.md) for more information.
0 commit comments