forked from qt-creator/qt-creator
DocumentModel: Replace optional::value by non-throwing alternative
...to calm down static checker which fears throwing exceptions into dtors Change-Id: I595c79ca6d19c7592e98437585fc33c4071d09c6 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -533,7 +533,7 @@ DocumentModel::Entry *DocumentModel::entryForFilePath(const Utils::FileName &fil
|
||||
const Utils::optional<int> index = d->indexOfFilePath(filePath);
|
||||
if (!index)
|
||||
return nullptr;
|
||||
return d->m_entries.at(index.value());
|
||||
return d->m_entries.at(*index);
|
||||
}
|
||||
|
||||
QList<IDocument *> DocumentModel::openedDocuments()
|
||||
|
Reference in New Issue
Block a user