TupleDeclaration
This declaration models a tuple of different VariableDeclaration nodes. This is primarily used in languages that support multiple assignments in a declaration, such as Go. The tuple is needed because the initializer of this declaration is flowing into the tuple (and then split among its elements) rather than flowing into the declarations individually. For example the following code
var a,b = call()
corresponds to:
two VariableDeclaration nodes
a
andb
, with an empty VariableDeclaration.initializera TupleDeclaration, with the auto-generated name
(a,b)
and TupleDeclaration.elementsa
andb
an TupleDeclaration.initializer that holds a CallExpression to
call
.
Implementation Note #1: The VariableDeclaration.initializer of the element variables MUST be empty; only the TupleDeclaration.initializer must be set. Otherwise we are potentially parsing the initializer twice.
Implementation Note #2: Currently, we only support TupleDeclaration with an initial AutoType (set in newTupleDeclaration); its actual TupleType will be inferred by the TupleDeclaration.initializer (see VariableDeclaration.typeChanged for the implementation).
The same applies to the elements in the tuple. They also need to have an AutoType, and their respective type will be based on a registered type observer to their tuple and implemented also in VariableDeclaration.typeChanged
Properties
Additional problem nodes. These nodes represent problems which occurred during processing of a node (i.e. only partially processed).
The aliases which this node has.
Returns a list of all Nodes, starting from the current Node, which are the beginning of an EOG path created by the EvaluationOrderGraphPass. Typical examples include all top-level declarations, such as functions and variables. For a more detailed explanation, see EOGStarterHolder.
List of annotations associated with that node.
Index of the argument if this node is used in a function call or parameter list.
This property refers to a list of Type nodes which are assigned to that Node. This could be different from the HasType.type. A common example is that a node could contain an interface as a HasType.type, but the actual implementation of the type as one of the assignedTypes. This could potentially also be empty, if we don't see any assignments to this expression.
Returns all Assignment child edges in this graph, starting with this Node.
Returns all AssignExpression child edges in this graph, starting with this Node.
Virtual property to return a list of the node's children. Uses the SubgraphWalker to retrieve the appropriate nodes.
Returns all BreakStatement child edges in this graph, starting with this Node.
Returns all CallExpression children in this graph, starting with this Node.
Returns all CastExpression children in this graph, starting with this Node.
Returns all ContinueStatement child edges in this graph, starting with this Node.
Because we are updating type information in the properties of the node, we need a reference to managers such as the TypeManager instance which is responsible for this particular node. All managers are bundled in TranslationContext. It is set in Node.applyMetadata when a ContextProvider is provided.
Returns all DoStatement child edges in this graph, starting with this Node.
The list of elements in this tuple.
Returns all FieldDeclaration children in this graph, starting with this Node.
Returns the Assignment.value of the first (by EOG order beginning from) Assignment that this variable has as its Assignment.target in the scope of the variable.
Returns all ForEachStatement child edges in this graph, starting with this Node.
Returns all ForStatement child edges in this graph, starting with this Node.
Returns all FunctionDeclaration children in this graph, starting with this Node.
Returns all IfStatement child edges in this graph, starting with this Node.
Returns all ImportDeclaration children in this graph, starting with this Node.
The (optional) initializer of the declaration.
Specifies, whether this node is implicit, i.e. is not really existing in source code but only exists implicitly. This mostly relates to implicit casts, return statements or implicit this expressions.
C++ uses implicit constructor calls for statements like A a;
but this only applies to types that are actually classes and not just primitive types or typedef aliases of primitives. Thus, during AST construction, we can only suggest that an implicit constructor call might be allowed by the language (so this is set to true for C++ but false for Java, as such a statement in Java leads to an uninitialized variable). The final decision can then be made after we have analyzed all classes present in the current scope.
If a node is marked as being inferred, it means that it was created artificially and does not necessarily have a real counterpart in the scanned source code. However, the nodes represented should have been part of parser output and represents missing code that is inferred by the CPG construction, e.g. missing functions, records, files etc.
Returns all LabelStatement child edges in this graph, starting with this Node.
The language of this node. This property is set in Node.applyMetadata by a LanguageProvider at the time when the node is created.
Location of the finding in source code.
Returns all MemberCallExpression children in this graph, starting with this Node.
Returns all MemberExpression children in this graph, starting with this Node.
Returns all MethodDeclaration children in this graph, starting with this Node.
Returns all RecordDeclaration children in this graph, starting with this Node.
The nodes which are control-flow dominated, i.e., the children of the Control Dependence Graph (CDG).
Virtual property for accessing nextDFGEdges without property edges.
Outgoing data flow edges
Virtual property for accessing nextEOGEdges without property edges.
Outgoing control flow edges.
Virtual property for accessing nextDFGEdges that have a de.fraunhofer.aisec.cpg.graph.edges.flows.FullDataflowGranularity.
Outgoing Program Dependence Edges.
Returns all OperatorCallExpression children in this graph, starting with this Node.
Returns all OperatorDeclaration children in this graph, starting with this Node.
Returns all ParameterDeclaration children in this graph, starting with this Node.
The nodes which dominate this node via the control-flow, i.e., the parents of the Control Dependence Graph (CDG).
Virtual property for accessing prevDFGEdges without property edges.
Incoming data flow edges
Virtual property for accessing prevEOGEdges without property edges.
Incoming control flow edges.
Virtual property for accessing nextDFGEdges that have a de.fraunhofer.aisec.cpg.graph.edges.flows.FullDataflowGranularity.
Incoming Program Dependence Edges.
Return all ProblemNode children in this graph (either stored directly or in Node.additionalProblems), starting with this Node.
Returns all RecordDeclaration children in this graph, starting with this Node.
Returns all ReturnStatement child edges in this graph, starting with this Node.
The scope this node "lives" in / in which it is defined. This property is set in Node.applyMetadata by a ScopeProvider at the time when the node is created.
Returns all SwitchStatement child edges in this graph, starting with this Node.
We need a way to store the templateParameters that a VariableDeclaration might have before the ConstructExpression is created.
Returns all ThrowExpression child edges in this graph, starting with this Node.
Returns the TranslationUnitDeclaration where this node is located in.
Returns all TryStatement child edges in this graph, starting with this Node.
A list of TypeObserver objects that will be informed about type changes, usually by informObservers.
Links to all the References accessing the variable and the respective access value (read, write, readwrite).
All usages of the variable/field.
Returns all VariableDeclaration children in this graph, starting with this Node.
Returns all WhileStatement child edges in this graph, starting with this Node.
Functions
Adds the expression to the list of arguments.
Adds type to the list of HasType.assignedTypes and informs all observers about the change.
Adds all types to the list of HasType.assignedTypes and informs all observers about the change.
Flattens the AST beginning with this node and returns all nodes of type T. For convenience, an optional predicate function predicate can be supplied, which will be applied via Collection.filter
This callback function will be invoked, if the observed node changes its HasType.assignedTypes.
Iterates the next EOG edges until there are no more edges available (or until a loop is detected). Returns a list of possible paths (each path is represented by a list of nodes).
Iterates the next full DFG edges until there are no more edges available (or until a loop is detected). Returns a list of possible paths (each path is represented by a list of nodes).
Iterates the next PDG edges until there are no more edges available (or until a loop is detected). Returns a list of possible paths (each path is represented by a list of nodes).
Iterates the prev full DFG edges until there are no more edges available (or until a loop is detected). Returns a list of possible paths (each path is represented by a list of nodes).
All nodes which depend on this if statement
If a node should be removed from the graph, just removing it from the AST is not enough (see issue #60). It will most probably be referenced somewhere via DFG or EOG edges. Thus, if it needs to be disconnected completely, we will have to take care of correctly disconnecting these implicit edges.
A helper function that can be used for EdgeSingletonList.onChanged. It unregisters this TypeObserver with the old node and registers it with the new one.
This function tries to find the first parent node that satisfies the condition specified in predicate. It starts searching in the searchNode, moving up-wards using the Node.astParent attribute.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with ControlDependence) between the starting node this and the end node fulfilling predicate. The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest evaluation paths between the starting node this and the end node fulfilling predicate. The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with FullDataflowGranularity) between the starting node this and the end node fulfilling predicate. The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with ProgramDependences) between the starting node this and the end node fulfilling predicate. The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with ControlDependence) between the starting node this and the end node fulfilling predicate (backwards analysis). The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest evaluation paths between the end node this and the start node fulfilling predicate. The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with FullDataflowGranularity) between the end node this and the starting node fulfilling predicate. The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with ProgramDependences) between the starting node this and the end node fulfilling predicate (backwards analysis). The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Returns an instance of FulfilledAndFailedPaths where FulfilledAndFailedPaths.fulfilled contains all possible shortest data flow paths (with x specifying how to fetch more nodes) between the starting node this and the end node fulfilling predicate (backwards analysis). The paths are represented as lists of nodes. Paths which do not end at such a node are included in FulfilledAndFailedPaths.failed.
Checks, if expression is part of the arguments.
Implementation of hash code. We are including the name and the location in this hash code as a compromise between including too few attributes and performance. Please note that this means, that two nodes that might be semantically equal, such as two record declarations with the same name but different location (e.g. because of header files) will be sorted into different hash keys.
This function SHOULD be used be an implementing class to inform observers about type changes. While the implementing class can technically do this on its own, it is strongly recommended to use this function to harmonize the behaviour of propagating types.
Checks, whether the given Type is a primitive in the language specified in the LanguageProvider.
Creates a new Annotation. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new AnnotationMember. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new AssertStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new AssignExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new BinaryOperator or a ShortCircuitOperator if the language implements HasShortCircuitOperators and if the operatorCode is contained in HasShortCircuitOperators.operatorCodes. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new Block. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new BreakStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new CallExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new CaseStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new CastExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new CatchClause. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ConditionalExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ConstructExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ConstructorDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ContinueStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new DeclarationStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new DefaultStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new DeleteExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new DistinctLanguageBlock. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new DoStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new EmptyStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new EnumConstantDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new EnumDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ExpressionList. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new FieldDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ForEachStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ForStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new FunctionDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new FunctionTemplateDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new GotoStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new IfStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ImportDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new IncludeDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new InitializerListExpression. This is the top-most Node that a LanguageFrontend or Handler should create. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new KeyValueExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new LabelStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new LambdaExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new LookupScopeStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new MemberCallExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new MemberExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new MethodDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Generates a Name object from the given name. If localNameOnly is set, only the localName is used, otherwise the namespace is added to generate a fqn if the name is not a fqn anyway.
Creates a new NamespaceDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new NewArrayExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new NewExpression. This is the top-most Node that a LanguageFrontend or Handler should create. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new MemberCallExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new OperatorDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ParameterDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ProblemDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ProblemExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new RangeExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new RecordDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new RecordTemplateDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new Reference. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ReturnStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new SubscriptExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new SwitchStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new SynchronizedStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new ThrowExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TranslationUnitDeclaration. This is the top-most Node that a LanguageFrontend or Handler should create. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TryStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TupleDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TypedefDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TypeExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TypeIdExpression. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new TypeParameterDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new UnaryOperator. This is the top-most Node that a LanguageFrontend or Handler should create. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new VariableDeclaration. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
Creates a new WhileStatement. The MetadataProvider receiver will be used to fill different meta-data using Node.applyMetadata. Calling this extension function outside of Kotlin requires an appropriate MetadataProvider, such as a LanguageFrontend as an additional prepended argument.
The "object identifier" of a node can be used to differentiate different "objects" that a node (most likely a Reference) refers to.
This function returns an ObjectType with the given name. If a respective Type does not yet exist (in the current scope), it will be created. In order to avoid unnecessary allocation of simple types, we do a pre-check within this function, whether a built-in type exist with the particular name.
A small utility extension function that uses the language information in a LanguageProvider (such as a Node, a Language, a LanguageFrontend or a Handler) to parse a fully qualified name.
Adds a Node to the list of "held" nodes.
This function constructs a new primitive Type. Primitive or built-in types are defined in Language.builtInTypes. This function will look up the type by its name, if it fails to find an appropriate build-in type, a TranslationException is thrown. Therefore, this function should primarily be called by language frontends if they are sure that this type is a built-in type, e.g., when constructing literals. It can be useful, if frontends want to check, whether all literal types are correctly registered as built-in types.
This function prints a partial graph, limited to a particular set of edges, starting with the current Node as Markdown, with an embedded Mermaid graph. The output can either be pasted into a Markdown document (and then rendered) or directly pasted into GitHub issues, discussions or pull requests (see https://github.blog/2022-02-14-include-diagrams-markdown-files-mermaid/).
Returns the Persistable's properties. This DOES NOT include relationships, but only properties directly attached to the node/edge.
Registers the given typeObservers to be informed about type updates. This also immediately invokes both TypeObserver.typeChanged and TypeObserver.assignedTypeChanged.
Removes the expression from the list of arguments.
Returns a new Inference object starting from this node. This will check, whether inference is enabled at all (using InferenceConfiguration.enabled). Otherwise null, will be returned.
This callback function will be invoked, if the observed node changes its HasType.type.
Creates a new UnknownType and sets the appropriate language, if this MetadataProvider includes a LanguageProvider.
Unregisters the given typeObservers from the list of observers.