forked from qt-creator/qt-creator
		
	QmlJS: Convert more dynamic_casts to value_casts.
And introduce a good error message for the case when someone forgets the specialization of the value_cast template. Change-Id: Iec55a839e8f5eef5872b1dab8601f66e0e0c88de Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com>
This commit is contained in:
		| @@ -84,11 +84,11 @@ void ScopeBuilder::push(AST::Node *node) | ||||
|                     break; | ||||
|             } | ||||
|             // signals defined in QML | ||||
|             if (const ASTSignal *astsig = dynamic_cast<const ASTSignal *>(value)) { | ||||
|             if (const ASTSignal *astsig = value_cast<ASTSignal>(value)) { | ||||
|                 _scopeChain->appendJsScope(astsig->bodyScope()); | ||||
|             } | ||||
|             // signals defined in C++ | ||||
|             else if (const CppComponentValue *qmlObject = dynamic_cast<const CppComponentValue *>(owner)) { | ||||
|             else if (const CppComponentValue *qmlObject = value_cast<CppComponentValue>(owner)) { | ||||
|                 if (const ObjectValue *scope = qmlObject->signalScope(name)) { | ||||
|                     _scopeChain->appendJsScope(scope); | ||||
|                 } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user