aboutsummaryrefslogtreecommitdiff
path: root/testsuite/fail_compilation/reference_call_result_field.elna
blob: 5051cc85a50e60202b781267990a770f9beccc98 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
type
  R = record
    x: Int
  end

var
  p: ^Int

proc make() -> R
var
  result: R
begin
  result.x := 1
return result

begin
  p := @make().x (* @Error Expression of type 'Int' is not addressable *)
end.