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

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

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