----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/121263/ -----------------------------------------------------------
(Updated Feb. 8, 2015, 2:42 p.m.) Status ------ This change has been discarded. Review request for KDE Frameworks, Christoph Cullmann, Dominik Haumann, and Kevin Funk. Repository: ktexteditor Description ------- In KDevelop we currently hit this often since our old class previously returned a reference for the start/end getters of range and cursor. With the help of C++11 ref qualifiers, we can detect that and let the compiler give the user an error message: error: cannot initialize object parameter of type 'KTextEditor::Cursor' with an expression of type 'KTextEditor::Cursor' documentRange().start().setColumn(42); ^~~~~~~~~~~~~~~~~~~~~~~ Yes, the error message is pretty bad. But better than nothing? We could also mark the && overloads of these functions as explictily deleted, which would slightly improve the error message... Diffs ----- src/include/CMakeLists.txt 94b8e79e2f2b273ec344a963ba6ac81ec5a481c6 src/include/ktexteditor/cursor.h 4ebe38fc1bffb2dad02150884fd225fe3ca9e193 src/include/ktexteditor/global.h PRE-CREATION src/include/ktexteditor/range.h 1a2fc5b200c70364c3d99223e43a2ad6179055de Diff: https://git.reviewboard.kde.org/r/121263/diff/ Testing ------- with the fixes to kdev's codebase, all of ktexteditor, kate and kdev* builds fine. Thanks, Milian Wolff
_______________________________________________ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel