MCPcopy Create free account
hub / github.com/KDE/kdevelop / isArrowOperator

Function isArrowOperator

kdevplatform/language/duchain/stringhelpers.cpp:104–110  ·  view source on GitHub ↗

check for operator-> but don't get confused by operator-->

Source from the content-addressed store, hash-verified

102
103// check for operator-> but don't get confused by operator-->
104bool isArrowOperator(QStringView str, int pos)
105{
106 Q_ASSERT(pos >= 0 && pos < str.size());
107
108 Q_ASSERT(str[pos] == QLatin1Char('>'));
109 return pos > 0 && str[pos - 1] == QLatin1Char('-') && (pos == 1 || str[pos - 2] != QLatin1Char('-'));
110}
111
112bool isOperatorOrArrowOperator(QStringView str, int pos)
113{

Callers 1

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected