Fixed #import completion to act the same as #include completion.

This commit is contained in:
Erik Verbruggen
2010-03-23 16:06:00 +01:00
parent 32a056aee0
commit 2f0e30c150

View File

@@ -156,6 +156,10 @@ QList<SimpleToken> SimpleLexer::operator()(const QString &text, int state)
else if (inPreproc && tokens.size() == 1 && simpleTk.is(T_IDENTIFIER) &&
simpleTk.text() == QLatin1String("include"))
lex.setScanAngleStringLiteralTokens(true);
else if (_objCEnabled
&& inPreproc && tokens.size() == 1 && simpleTk.is(T_IDENTIFIER) &&
simpleTk.text() == QLatin1String("import"))
lex.setScanAngleStringLiteralTokens(true);
if (_objCEnabled && tk.is(T_IDENTIFIER))
simpleTk.f._objcTypeQualifier = (classifyObjectiveCContextKeyword(firstChar + tk.offset, tk.f.length) != Token_identifier);