class
InstanceSymbolRepresents an instance of a module, interface, or program.
Base classes
- class InstanceSymbolBase
- Common functionality for module, interface, program, and primitive instances.
Public static functions
- static auto createDefault(Compilation& compilation, const DefinitionSymbol& definition, const HierarchyOverrideNode* hierarchyOverrideNode = nullptr, const ConfigBlockSymbol* configBlock = nullptr, const ConfigRule* configRule = nullptr, SourceLocation locationOverride = {}) -> InstanceSymbol&
- Creates a default-instantiated instance of the given definition.
-
static auto createVirtual(const ASTContext& context,
SourceLocation loc,
const DefinitionSymbol& definition,
const syntax::
ParameterValueAssignmentSyntax* paramAssignments) -> InstanceSymbol& - Creates a placeholder instance for a virtual interface type declaration.
-
static auto createDefaultNested(const Scope& scope,
const syntax::
ModuleDeclarationSyntax& syntax) -> Symbol& - Creates a default-instantiated instance of a nested definition in the provided scope.
- static auto createInvalid(Compilation& compilation, const DefinitionSymbol& definition) -> InstanceSymbol&
- Creates an intentionally invalid instance by forcing all parameters to null values.
Public variables
- const ResolvedConfig* resolvedConfig
- A config rule that applies to this instance, or a pointer to the parent instance's config rule if there is one up the stack.
Function documentation
static InstanceSymbol& slang:: ast:: InstanceSymbol:: createDefault(Compilation& compilation,
const DefinitionSymbol& definition,
const HierarchyOverrideNode* hierarchyOverrideNode = nullptr,
const ConfigBlockSymbol* configBlock = nullptr,
const ConfigRule* configRule = nullptr,
SourceLocation locationOverride = {})
Creates a default-instantiated instance of the given definition.
All parameters must have defaults specified.
static InstanceSymbol& slang:: ast:: InstanceSymbol:: createInvalid(Compilation& compilation,
const DefinitionSymbol& definition)
Creates an intentionally invalid instance by forcing all parameters to null values.
This allows type checking instance members as long as they don't depend on any parameters.