Commit 57691c48 authored by Christoph Reichenbach's avatar Christoph Reichenbach
Browse files

Elaborated on spec, updated and sorted "expected" files

parent a96c85a7
......@@ -137,25 +137,26 @@ fun main(n : int) : nonnull int = { // line 10
}
```
Your analysis should print the following:
Your analysis should print the following (or something similar, see below):
```
N 14 4 -> null 12 13
N 14 4 -> obj 11 29
N 14 4 -> obj 11 32
N 14 4 -> obj 11 35
N 14 4 -> null 5 14
N 1 10 -> null 12 13
N 1 10 -> null 5 14
N 1 10 -> obj 11 29
N 1 10 -> obj 11 32
N 1 10 -> obj 11 35
N 1 10 -> null 12 13
N 1 40 -> obj 11 29
N 1 40 -> obj 11 32
N 1 40 -> obj 11 35
N 10 0 -> null 5 14
N 10 0 -> obj 11 29
N 10 0 -> obj 11 32
N 10 0 -> obj 11 35
N 10 0 -> null 12 13
```
Where:
- `N` means that we are talking about an assignment to a nonnull variable (here, a field).
- `14 4` refers to the source location that Teal associates with the `return` statement
- `1 10` refers to the source location that Teal associates with the `fst` field. Since we don't expect a field-sensitive analysis, it is fine to point to _any_ nonnull field (i.e., it would also be okay to report the location of `trd`).
- `1 10` refers to the source location that Teal associates with the `fst` field. Since we don't expect a field-sensitive analysis, it is fine to point to _any_ nonnull field of the same structure.
- `1 40` is the location of the `trd` field; it is equivalent to the `fst` field for us.
- `obj 11 35` refers to the literal number `2`
- `null 5 14` is the source location in which `null` occurs in `null_producer` (from which it can make its way into `p.fst`).
......
N 4 6 -> obj 14 4
N 10 2 -> null 12 7
N 10 2 -> obj 9 15
NI 5 9 -> obj 9 21
NI 5 9 -> null 9 25
NO 16 9 -> null 12 7
N 10 2 -> obj 9 15
N 10 2 -> null 12 7
NO 16 9 -> obj 9 15
NO 16 9 -> null 12 7
N 14 4 -> null 12 13
N 14 4 -> obj 11 29
N 14 4 -> obj 11 32
N 14 4 -> null 5 14
N 1 10 -> null 12 13
N 1 10 -> null 5 14
N 1 10 -> obj 11 29
N 1 10 -> obj 11 32
N 1 10 -> null 12 13
N 10 0 -> null 5 14
N 10 0 -> obj 11 29
N 10 0 -> obj 11 32
N 10 0 -> null 12 13
N 8 2 -> obj 4 17
N 8 2 -> obj 5 7
N 8 2 -> obj 4 25
N 8 2 -> obj 4 28
N 8 2 -> null 4 31
N 8 2 -> obj 5 7
N 8 2 -> obj 5 15
N 8 2 -> obj 5 18
N 8 2 -> obj 4 25
N 8 2 -> obj 4 28
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment