Q_ASSERT usage
Nick Shaforostoff
shaforostoff at gmail.com
Wed Dec 17 05:34:35 UTC 2008
in kdevplatform/language/duchain/declaration.cpp i found this code:
// If the parent-context already has dynamic data, like for example
any temporary context,
// always delete the declaration, to not create crashes within more
complex code like C++ template stuff.
if (context() && !d_func()->m_anonymousInContext) {
if(!topContext->deleting() || !topContext->isOnDisk() ||
context()->d_func()->isDynamic())
Q_ASSERT(context()->m_dynamicData->removeDeclaration(this));
}
when compiled in release mode, this is equivalent of
if (context() && !d_func()->m_anonymousInContext) {
if(!topContext->deleting() || !topContext->isOnDisk() ||
context()->d_func()->isDynamic())
;
}
is this intended behaviour?
More information about the KDevelop-devel
mailing list