MGH_STRUCT_BUILD
Name
MGH_STRUCT_BUILD
Purpose
This function builds an anonymous structure, given a list of tag names
and a list of pointers to data values.
Calling Sequence
result = MGH_STRUCT_BUILD(tags, values, POINTER=pointer)
Positional Parameters
tags (input, string array)
List of tag names
values (input, pointer array)
A list of values wrapped in pointers. Must have the same number
of elements as the tags array.
Keyword Parameters
POINTER (input, switch)
Determines whether the output structure includes the data values
or pointers to them.
Procedure
A command to create the structure is constructed and processed by
EXECUTE. To avoid "Program code area full" failures a limit is
placed on the number of tags created at one time; if this limit is
exceeded the structure is built up in a series of steps.
###########################################################################
Copyright (c) 2000-2013 NIWA:
http://www.niwa.co.nz/
Licensed under the MIT open source license:
http://www.opensource.org/licenses/mit-license.php
###########################################################################
Modification History
Mark Hadfield, 2000-11:
Written.
Mark Hadfield, 2005-09:
Added POINTER keyword.
Mark Hadfield, 2010-10:
The result is now initialised with a !NULL, allowing simplification
of the code.
Mark Hadfield, 2013-05:
Tags now processed with MGH_STR_VANILLA before building structure. If a
tag is not a valid identifier, then an error is raised.