public interface ICASTKnRFunctionDeclarator extends IASTFunctionDeclarator
IASTNode.CopyStyle
Modifier and Type | Field and Description |
---|---|
static ASTNodeProperty |
FUNCTION_PARAMETER
FUNCTION_PARAMETER represents the relationship between an
K&R function declarator and the full parameter declarations. |
static ASTNodeProperty |
PARAMETER_NAME
PARAMETER_NAME refers to the names qualified in a K&R C
function definition. |
DECLARATOR_NAME, EMPTY_DECLARATOR_ARRAY, INITIALIZER, NESTED_DECLARATOR, POINTER_OPERATOR
r_declaration, r_definition, r_reference, r_unclear
ATTRIBUTE, ATTRIBUTE_SPECIFIER
EMPTY_NODE_ARRAY
Modifier and Type | Method and Description |
---|---|
ICASTKnRFunctionDeclarator |
copy()
Returns a mutable copy of the tree rooted at this node.
|
ICASTKnRFunctionDeclarator |
copy(IASTNode.CopyStyle style)
Returns a mutable copy of the tree rooted at this node.
|
IASTDeclarator |
getDeclaratorForParameterName(IASTName name)
Map declarator to IASTName.
|
IASTDeclaration[] |
getParameterDeclarations()
Get parameters declarations.
|
IASTName[] |
getParameterNames()
Returns parameter names.
|
void |
setParameterDeclarations(IASTDeclaration[] decls)
Sets the parameter lists.
|
void |
setParameterNames(IASTName[] names)
Sets the parameter names.
|
addPointerOperator, getInitializer, getName, getNestedDeclarator, getPointerOperators, setInitializer, setName, setNestedDeclarator
getRoleForName
addAttribute, addAttributeSpecifier, getAttributes, getAttributeSpecifiers
accept, contains, getChildren, getContainingFilename, getFileLocation, getLeadingSyntax, getNodeLocations, getOriginalNode, getParent, getPropertyInParent, getRawSignature, getSyntax, getTrailingSyntax, getTranslationUnit, isActive, isFrozen, isPartOfTranslationUnitFile, setParent, setPropertyInParent
static final ASTNodeProperty PARAMETER_NAME
PARAMETER_NAME
refers to the names qualified in a K&R C
function definition.static final ASTNodeProperty FUNCTION_PARAMETER
FUNCTION_PARAMETER
represents the relationship between an
K&R function declarator and the full parameter declarations.void setParameterNames(IASTName[] names)
names
- IASTName []
IASTName[] getParameterNames()
IASTName []
void setParameterDeclarations(IASTDeclaration[] decls)
decls
- TODO - replace w/zaddIASTDeclaration[] getParameterDeclarations()
IASTDeclaration []
IASTDeclarator getDeclaratorForParameterName(IASTName name)
name
- IASTName
ICASTKnRFunctionDeclarator copy()
IASTNode
copy.getParent() == null copy.getPropertyInParent() == null copy.isFrozen() == falsePreprocessor nodes do not currently support being copied. Implicit name nodes are not copied, instead they can be regenerated if required.
Calling this method is equivalent to copy(CopyStyle.withoutLocations)
.
copy
in interface IASTDeclarator
copy
in interface IASTFunctionDeclarator
copy
in interface IASTNode
ICASTKnRFunctionDeclarator copy(IASTNode.CopyStyle style)
IASTNode
copy.getParent() == null copy.getPropertyInParent() == null copy.isFrozen() == falsePreprocessor nodes do not currently support being copied. Implicit name nodes are not copied, instead they can be regenerated if required.
copy
in interface IASTDeclarator
copy
in interface IASTFunctionDeclarator
copy
in interface IASTNode
style
- IASTNode.CopyStyle
create a copy with or without locations. Please see
IASTNode.CopyStyle
for restrictions on copies with Locations.Copyright (c) IBM Corp. and others 2004, 2020. All Rights Reserved.