Internals: Add missing package null test. No functional change intended.
This commit is contained in:
parent
43213fcdc2
commit
67fab0b4fc
13
src/V3Ast.h
13
src/V3Ast.h
|
|
@ -2722,10 +2722,10 @@ class AstNodeFTaskRef : public AstNodeStmt {
|
||||||
// Functions are not statements, while tasks are. AstNodeStmt needs isStatement() to deal.
|
// Functions are not statements, while tasks are. AstNodeStmt needs isStatement() to deal.
|
||||||
private:
|
private:
|
||||||
AstNodeFTask* m_taskp = nullptr; // [AfterLink] Pointer to task referenced
|
AstNodeFTask* m_taskp = nullptr; // [AfterLink] Pointer to task referenced
|
||||||
|
AstNodeModule* m_packagep = nullptr; // Package hierarchy
|
||||||
string m_name; // Name of variable
|
string m_name; // Name of variable
|
||||||
string m_dotted; // Dotted part of scope the name()ed task/func is under or ""
|
string m_dotted; // Dotted part of scope the name()ed task/func is under or ""
|
||||||
string m_inlinedDots; // Dotted hierarchy flattened out
|
string m_inlinedDots; // Dotted hierarchy flattened out
|
||||||
AstNodeModule* m_packagep = nullptr; // Package hierarchy
|
|
||||||
bool m_pli = false; // Pli system call ($name)
|
bool m_pli = false; // Pli system call ($name)
|
||||||
public:
|
public:
|
||||||
AstNodeFTaskRef(AstType t, FileLine* fl, bool statement, AstNode* namep, AstNode* pinsp)
|
AstNodeFTaskRef(AstType t, FileLine* fl, bool statement, AstNode* namep, AstNode* pinsp)
|
||||||
|
|
@ -2739,10 +2739,7 @@ public:
|
||||||
addNOp3p(pinsp);
|
addNOp3p(pinsp);
|
||||||
}
|
}
|
||||||
ASTNODE_BASE_FUNCS(NodeFTaskRef)
|
ASTNODE_BASE_FUNCS(NodeFTaskRef)
|
||||||
virtual const char* broken() const override {
|
virtual const char* broken() const override;
|
||||||
BROKEN_RTN(m_taskp && !m_taskp->brokeExists());
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
virtual void cloneRelink() override {
|
virtual void cloneRelink() override {
|
||||||
if (m_taskp && m_taskp->clonep()) { m_taskp = m_taskp->clonep(); }
|
if (m_taskp && m_taskp->clonep()) { m_taskp = m_taskp->clonep(); }
|
||||||
}
|
}
|
||||||
|
|
@ -2942,6 +2939,12 @@ inline VNumRange AstNodeArrayDType::declRange() const {
|
||||||
return VNumRange(msb(), lsb(), rangep()->littleEndian());
|
return VNumRange(msb(), lsb(), rangep()->littleEndian());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline const char* AstNodeFTaskRef::broken() const {
|
||||||
|
BROKEN_RTN(m_taskp && !m_taskp->brokeExists());
|
||||||
|
BROKEN_RTN(m_packagep && !m_packagep->brokeExists());
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
inline void AstIfaceRefDType::cloneRelink() {
|
inline void AstIfaceRefDType::cloneRelink() {
|
||||||
if (m_cellp && m_cellp->clonep()) m_cellp = m_cellp->clonep();
|
if (m_cellp && m_cellp->clonep()) m_cellp = m_cellp->clonep();
|
||||||
if (m_ifacep && m_ifacep->clonep()) m_ifacep = m_ifacep->clonep();
|
if (m_ifacep && m_ifacep->clonep()) m_ifacep = m_ifacep->clonep();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue