API reference
python:astx:astx.callables.FunctionPrototype
class FunctionPrototype
FunctionPrototype(name: str, args: Arguments, return_type: AnyType, scope: ScopeKind = ScopeKind.global_, visibility: VisibilityKind = VisibilityKind.public, loc: SourceLocation = NO_SOURCE_LOCATION, parent: Optional[ASTNodes] = None)
Source: packages/astx/src/astx/callables.py:326
AST class for function prototype declaration.
Attributes
-
loc — Type: SourceLocation
-
kind — Type: ASTKind
-
name — Type: str
-
args — Type: Arguments
-
return_type — Type: AnyType
-
scope — Type: ScopeKind
-
visibility — Type: VisibilityKind
Methods
-
__init__ — Initialize the FunctionPrototype instance.
-
get_struct — Get the AST structure that represent the object.