forked from qt-creator/qt-creator
typeprettyprinter: fix handling of _ at start of identifiers
This broke e.g. 'AddDefinition' for 'int foo(int const * const _x)'. resulting in 'foo(const int *const_x)' Change-Id: I6aae6c4a47e127de109b5fbefdf202ca050a391f Reviewed-by: Leandro Melo <leandro.melo@nokia.com> Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
This commit is contained in:
@@ -405,7 +405,7 @@ void TypePrettyPrinter::prependWordSeparatorSpace()
|
|||||||
|
|
||||||
const QChar ch = _text.at(0);
|
const QChar ch = _text.at(0);
|
||||||
|
|
||||||
if (ch.isLetterOrNumber())
|
if (ch.isLetterOrNumber() || ch == QLatin1Char('_'))
|
||||||
_text.prepend(" ");
|
_text.prepend(" ");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user