diff options
Diffstat (limited to 'src/libs/qmljs/qmljscheck.h')
| -rw-r--r-- | src/libs/qmljs/qmljscheck.h | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/src/libs/qmljs/qmljscheck.h b/src/libs/qmljs/qmljscheck.h index 2d7352f1515..6864de4f8c9 100644 --- a/src/libs/qmljs/qmljscheck.h +++ b/src/libs/qmljs/qmljscheck.h @@ -35,17 +35,29 @@ namespace QmlJS { +namespace Interpreter { + class Engine; + class Value; + class ObjectValue; + class FunctionValue; +} // end of namespace Interpreter + class QMLJS_EXPORT Check: protected AST::Visitor { public: - Check(); + Check(Interpreter::Engine *engine); virtual ~Check(); - void operator()(QmlJS::Document::Ptr doc); + const Interpreter::Value *operator()(AST::ExpressionNode *ast, const Interpreter::ObjectValue *scope); + const Interpreter::Value *check(AST::ExpressionNode *ast); protected: void accept(AST::Node *node); + Interpreter::Engine *switchEngine(Interpreter::Engine *engine); + const Interpreter::Value *switchResult(const Interpreter::Value *result); + const Interpreter::ObjectValue *switchScope(const Interpreter::ObjectValue *scope); + // Ui virtual bool visit(AST::UiProgram *ast); virtual bool visit(AST::UiImportList *ast); @@ -142,6 +154,9 @@ protected: private: QmlJS::Document::Ptr _doc; + Interpreter::Engine *_engine; + const Interpreter::ObjectValue *_scope; + const Interpreter::Value *_result; }; } // end of namespace Qml |
