DefinitionContainer: Create a DefinitionContainer object for managing resolved...

Description Usage Arguments Value Author(s) See Also

Description

This function is the constructor function for creating a DefinitionContainer object. Such an object is simply an environment that we use for mutability across function calls as we recursively process nodes and across top-level calls to resolveType. This manages the types returned by resolveType and avoids reprocessing the same node from different paths in the graph. Also, this therefore avoids problems of resolving recursively defined nodes, e.g. structs with an element which is a pointer to that type being defined such as a linked list.

There are names and apply methods for finding out what is in the container and looping over the elements.

Usage

1
2
DefinitionContainer(parser = NULL, e = structure(new.env(TRUE), class = "DefinitionContainer"), 
                     nodes = NULL, reportDuplicates = FALSE,  verbose = FALSE, force = FALSE)

Arguments

parser

the parser, i.e. array of nodes to be associated with the node-type mapping. Don't use a definition container populated from one set of nodes with a different set of nodes!

e

the environment to use

nodes

the TU parser object which is the container for the TU nodes.

reportDuplicates

a logical value which specifies whether to emit a warning if two different nodes are resolved and map to the same human-readable name, i.e. other than their node index name.

verbose

a logical value which if TRUE causes lots of information to be displayed on the console when the container is managing the transactions of querying and inserting the table.

force

a logical value indicating whether to force the creation of a new DefinitionContainer (TRUE) or to use the one already in the parser (FALSE). This is rarely used in regular calls but for use internally when creating the TU parser and DefinitionContainer.

Value

An object of class DefinitionContainer.

Author(s)

Duncan Temple Lang

See Also

resolveType


omegahat/RGCCTranslationUnit documentation built on May 24, 2019, 1:53 p.m.