qmljs: add # as comment

Change-Id: I87a043a39eae57306bc81b3c83f7a363d53be4bd
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
Fawzi Mohamed
2021-01-21 07:51:49 +01:00
parent 3cd476e582
commit a802a633f6

View File

@@ -306,6 +306,12 @@ QList<Token> Scanner::operator()(const QString &text, int startState)
la = text.at(index + 1);
switch (ch.unicode()) {
case '#':
if (_scanComments)
tokens.append(Token(index, text.length() - index, Token::Comment));
index = text.length();
break;
case '/':
if (la == QLatin1Char('/')) {
if (_scanComments)