Files
mercury/tests/hard_coded/field_syntax.exp
Ralph Becket 6dd11c5583 Allow field access syntax at the top-level of func and mode declarations and
Estimated hours taken: 3
Branches: main

Allow field access syntax at the top-level of func and mode declarations and
in function clause heads.

NEWS:
	Report the new feature.

doc/reference_manual.texi:
	Document the new feature.

compiler/prog_io.m:
	Implement the new feature.

tests/hard_coded/Mmakefile:
tests/hard_coded/field_syntax.exp:
tests/hard_coded/field_syntax.m:
	Added a test case.
2003-01-16 02:34:35 +00:00

5 lines
158 B
Plaintext

A = array([1, 2, 3])
A ^ elem(0) = 1
A ^ elem_from_end(0) = 3
(A ^ elem_from_end(2) := 4) = array([4, 2, 3])