Below is the complete example from which some examples in this section are taken.
# Structure type AddressRecord
structure AddressRecord is string Street
City
State
Zip end structure
# Structure type EmergencyContactRecord
structure EmergencyContactRecord is
string Name
structure AddressRecord Address
string Phone
end structure
# Structure type Employee Record
structure EmployeeRecord is
string Name
structure AddressRecord Address
integer NumDependents
structure Dependents is
string DependentName
structure AddressRecord DependentAddress
end structure DependentList[10]
structure EmergencyContactRecord EmergencyContact
float Salary
end structure
# Structure variable declaration:
structure EmployeeRecord Employee
# Subroutine declarations:
subroutine GetEmployeeData
(structure EmployeeRecord: Emprec)
subroutine UpdateEmployeeDB
(structure EmployeeRecord: Emprec)
# Examples of valid references to fields:
copy "Boston" to Employee.Address.City
copy "John" to Employee.DependentList[1].DependentName
copy "Tom" to Employee.EmergencyContact.Name
send Employee.Salary to errorlog
# Examples of valid references to structure variables:
call GetEmployeeData (Employee)
call UpdateEmployeeDB (Employee)