summaryrefslogtreecommitdiff
path: root/shared/cplusplus/TranslationUnit.cpp
diff options
context:
space:
mode:
authorRoberto Raggi <qtc-committer@nokia.com>2009-01-09 16:55:25 +0100
committerRoberto Raggi <qtc-committer@nokia.com>2009-01-09 16:55:51 +0100
commit599cdcfa064c91a2a4dcbb3d76dab799b19e4ecf (patch)
treebdbd8011612f4fe0cf3ac18d909914c0fed66919 /shared/cplusplus/TranslationUnit.cpp
parent5f9669d8d264bc0c97afae61269c25e485949b83 (diff)
downloadqt-creator-599cdcfa064c91a2a4dcbb3d76dab799b19e4ecf.tar.gz
More ObjC++
Diffstat (limited to 'shared/cplusplus/TranslationUnit.cpp')
-rw-r--r--shared/cplusplus/TranslationUnit.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/shared/cplusplus/TranslationUnit.cpp b/shared/cplusplus/TranslationUnit.cpp
index c64bbf52c1..caaa9c7d4e 100644
--- a/shared/cplusplus/TranslationUnit.cpp
+++ b/shared/cplusplus/TranslationUnit.cpp
@@ -92,6 +92,12 @@ bool TranslationUnit::qtMocRunEnabled() const
void TranslationUnit::setQtMocRunEnabled(bool onoff)
{ _qtMocRunEnabled = onoff; }
+bool TranslationUnit::objCEnabled() const
+{ return _objCEnabled; }
+
+void TranslationUnit::setObjCEnabled(bool onoff)
+{ _objCEnabled = onoff; }
+
Control *TranslationUnit::control() const
{ return _control; }
@@ -164,6 +170,7 @@ void TranslationUnit::tokenize()
Lexer lex(this);
lex.setQtMocRunEnabled(_qtMocRunEnabled);
+ lex.setObjCEnabled(_objCEnabled);
std::stack<unsigned> braces;
_tokens->push_back(Token()); // the first token needs to be invalid!
@@ -228,6 +235,7 @@ bool TranslationUnit::parse(ParseMode mode)
Parser parser(this);
parser.setQtMocRunEnabled(_qtMocRunEnabled);
+ parser.setObjCEnabled(_objCEnabled);
bool parsed = false;