diff --git a/src/plugins/clangformat/clangformatbaseindenter.cpp b/src/plugins/clangformat/clangformatbaseindenter.cpp index 5d2bda07d7f..fb8e6938096 100644 --- a/src/plugins/clangformat/clangformatbaseindenter.cpp +++ b/src/plugins/clangformat/clangformatbaseindenter.cpp @@ -679,7 +679,7 @@ bool ClangFormatBaseIndenter::isElectricCharacter(const QChar &ch) const return false; } -std::optional ClangFormat::ClangFormatBaseIndenter::margin() const +Utils::optional ClangFormat::ClangFormatBaseIndenter::margin() const { return styleForFile().ColumnLimit; } diff --git a/src/plugins/texteditor/indenter.h b/src/plugins/texteditor/indenter.h index 1d64dce5e11..d29b5c78e80 100644 --- a/src/plugins/texteditor/indenter.h +++ b/src/plugins/texteditor/indenter.h @@ -120,7 +120,7 @@ public: int cursorPositionInEditor = -1) = 0; - virtual Utils::optional margin() const { return std::nullopt; } + virtual Utils::optional margin() const { return Utils::nullopt; } protected: QTextDocument *m_doc;