From b9ccb579c4c93f23e6ceeea26b07d418ad4e5562 Mon Sep 17 00:00:00 2001 From: Kent Hansen Date: Wed, 7 Mar 2012 13:56:33 +0100 Subject: Remove QJS exception API MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This API has been deprecated for a while. It's legacy stuff from QtScript. Until someone proves that QJSValue::isError() isn't sufficient to handle JavaScript exceptions, we won't provide any additional API for that. Also removed QJSValuePrivate::lessThan(), which was using the exception mechanism, but the function itself wasn't used anymore (another remnant from the QtScript days). Change-Id: I3dffc6a7835874153f90d25ae2a72c93ea6db39a Reviewed-by: Jędrzej Nowacki Reviewed-by: Lars Knoll --- doc/src/snippets/code/src_script_qjsengine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/src') diff --git a/doc/src/snippets/code/src_script_qjsengine.cpp b/doc/src/snippets/code/src_script_qjsengine.cpp index efde346448..042bdd2760 100644 --- a/doc/src/snippets/code/src_script_qjsengine.cpp +++ b/doc/src/snippets/code/src_script_qjsengine.cpp @@ -73,7 +73,7 @@ QJSValue myNumberPlusOne = myEngine.evaluate("myNumber + 1"); //! [4] QJSValue result = myEngine.evaluate(...); -if (myEngine.hasUncaughtException()) +if (result.isError()) qDebug() << "uncaught exception:" << result.toString(); //! [4] -- cgit v1.2.3