MCPcopy Create free account
hub / github.com/KDE/kdevelop / rebuildDynamicData

Method rebuildDynamicData

kdevplatform/language/duchain/problem.cpp:237–255  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

235}
236
237void Problem::rebuildDynamicData(DUContext* parent, uint ownIndex)
238{
239 auto top = dynamic_cast<TopDUContext*>(parent);
240 Q_ASSERT(top);
241
242 m_topContext = top;
243 m_indexInTopContext = ownIndex;
244
245 // deserialize child diagnostics here, as the top-context might get unloaded
246 // but we still want to keep the child-diagnostics in-tact, as one would assume
247 // a shared-ptr works.
248 const auto data = d_func();
249 m_diagnostics.reserve(data->diagnosticsSize());
250 for (uint i = 0; i < data->diagnosticsSize(); ++i) {
251 m_diagnostics << ProblemPointer(data->diagnostics()[i].data(top));
252 }
253
254 DUChainBase::rebuildDynamicData(parent, ownIndex);
255}
256
257QDebug operator<<(QDebug s, const Problem& problem)
258{

Callers 2

itemForIndexMethod · 0.45
loadMethod · 0.45

Calls 3

reserveMethod · 0.45
dataMethod · 0.45
diagnosticsMethod · 0.45

Tested by

no test coverage detected