MCPcopy Create free account
hub / github.com/chipsalliance/Surelog / getTypeDef

Method getTypeDef

src/Design/DesignComponent.cpp:135–147  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133}
134
135const TypeDef* DesignComponent::getTypeDef(std::string_view name) const {
136 TypeDefMap::const_iterator itr = m_typedefs.find(name);
137 if (itr == m_typedefs.end()) {
138 const DesignComponent* parent =
139 valuedcomponenti_cast<const DesignComponent*>(getParentScope());
140 if (parent) {
141 return parent->getTypeDef(name);
142 } else
143 return nullptr;
144 } else {
145 return (*itr).second;
146 }
147}
148
149void DesignComponent::insertTypeDef(TypeDef* p) {
150 m_typedefs.emplace(p->getName(), p);

Callers 3

compileTypeDefMethod · 0.80
bindTypedefsPostElab_Method · 0.80
bindDataType_Method · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected