MCPcopy Create free account
hub / github.com/argotorg/solidity / resolveInheritDoc

Method resolveInheritDoc

libsolidity/analysis/DocStringAnalyser.cpp:182–203  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

180}
181
182CallableDeclaration const* DocStringAnalyser::resolveInheritDoc(
183 std::set<CallableDeclaration const*> const& _baseFuncs,
184 StructurallyDocumented const& _node,
185 StructurallyDocumentedAnnotation& _annotation
186)
187{
188 if (_annotation.inheritdocReference == nullptr)
189 return nullptr;
190
191 if (auto const callable = findBaseCallable(_baseFuncs, _annotation.inheritdocReference->id()))
192 return callable;
193
194 m_errorReporter.docstringParsingError(
195 4682_error,
196 _node.documentation()->location(),
197 "Documentation tag @inheritdoc references contract \"" +
198 _annotation.inheritdocReference->name() +
199 "\", but the contract does not contain a function that is overridden by this function."
200 );
201
202 return nullptr;
203}

Callers

nothing calls this directly

Calls 6

findBaseCallableFunction · 0.85
docstringParsingErrorMethod · 0.80
documentationMethod · 0.80
idMethod · 0.45
locationMethod · 0.45
nameMethod · 0.45

Tested by

no test coverage detected