summaryrefslogtreecommitdiffstats
path: root/src/3rdparty
diff options
context:
space:
mode:
authorOlivier Goffart <ogoffart@trolltech.com>2009-07-28 11:04:11 (GMT)
committerOlivier Goffart <ogoffart@trolltech.com>2009-07-28 11:28:27 (GMT)
commitf3927de84b509a1be3f06182327e3c4cdea23b70 (patch)
tree6317d9783430ae754bf0c5d42b3bf1148ceb1860 /src/3rdparty
parentacac0684d0eb13792cbb8b9bde6f077642dcc640 (diff)
downloadQt-f3927de84b509a1be3f06182327e3c4cdea23b70.zip
Qt-f3927de84b509a1be3f06182327e3c4cdea23b70.tar.gz
Qt-f3927de84b509a1be3f06182327e3c4cdea23b70.tar.bz2
Fix tst_QScriptEngine::uncaughtException
The test used to test that passing 0 as line number works. There is no reason to impose the lineNumber to be >= 1, this is an arbitrary limitation. It even works when passing negative value, but as -1 is a magic number, an error on line '-1' will not have lineNumber Reviewed-by: Kent Hansen
Diffstat (limited to 'src/3rdparty')
-rw-r--r--src/3rdparty/webkit/JavaScriptCore/parser/SourceCode.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/3rdparty/webkit/JavaScriptCore/parser/SourceCode.h b/src/3rdparty/webkit/JavaScriptCore/parser/SourceCode.h
index 84360b8..305b804 100644
--- a/src/3rdparty/webkit/JavaScriptCore/parser/SourceCode.h
+++ b/src/3rdparty/webkit/JavaScriptCore/parser/SourceCode.h
@@ -47,7 +47,11 @@ namespace JSC {
: m_provider(provider)
, m_startChar(0)
, m_endChar(m_provider->length())
+#ifdef QT_BUILD_SCRIPT_LIB
+ , m_firstLine(firstLine)
+#else
, m_firstLine(std::max(firstLine, 1))
+#endif
{
}
@@ -55,7 +59,11 @@ namespace JSC {
: m_provider(provider)
, m_startChar(start)
, m_endChar(end)
+#ifdef QT_BUILD_SCRIPT_LIB
+ , m_firstLine(firstLine)
+#else
, m_firstLine(std::max(firstLine, 1))
+#endif
{
}