1 // This file was generated by qlalr - DO NOT EDIT! |
|
2 |
|
3 /**************************************************************************** |
1 /**************************************************************************** |
4 ** |
2 ** |
5 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). |
3 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). |
6 ** All rights reserved. |
4 ** All rights reserved. |
7 ** Contact: Nokia Corporation (qt-info@nokia.com) |
5 ** Contact: Nokia Corporation (qt-info@nokia.com) |
8 ** |
6 ** |
9 ** This file is part of the QtScript module of the Qt Toolkit. |
7 ** This file is part of the QtScript module of the Qt Toolkit. |
10 ** |
8 ** |
11 ** $QT_BEGIN_LICENSE:LGPL$ |
9 ** $QT_BEGIN_LICENSE:LGPL-ONLY$ |
12 ** No Commercial Usage |
|
13 ** This file contains pre-release code and may not be distributed. |
|
14 ** You may use this file in accordance with the terms and conditions |
|
15 ** contained in the Technology Preview License Agreement accompanying |
|
16 ** this package. |
|
17 ** |
|
18 ** GNU Lesser General Public License Usage |
10 ** GNU Lesser General Public License Usage |
19 ** Alternatively, this file may be used under the terms of the GNU Lesser |
11 ** This file may be used under the terms of the GNU Lesser |
20 ** General Public License version 2.1 as published by the Free Software |
12 ** General Public License version 2.1 as published by the Free Software |
21 ** Foundation and appearing in the file LICENSE.LGPL included in the |
13 ** Foundation and appearing in the file LICENSE.LGPL included in the |
22 ** packaging of this file. Please review the following information to |
14 ** packaging of this file. Please review the following information to |
23 ** ensure the GNU Lesser General Public License version 2.1 requirements |
15 ** ensure the GNU Lesser General Public License version 2.1 requirements |
24 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. |
16 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. |
25 ** |
17 ** |
26 ** In addition, as a special exception, Nokia gives you certain additional |
|
27 ** rights. These rights are described in the Nokia Qt LGPL Exception |
|
28 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. |
|
29 ** |
|
30 ** If you have questions regarding the use of this file, please contact |
18 ** If you have questions regarding the use of this file, please contact |
31 ** Nokia at qt-info@nokia.com. |
19 ** Nokia at qt-info@nokia.com. |
32 ** |
|
33 ** |
|
34 ** |
|
35 ** |
|
36 ** |
|
37 ** |
|
38 ** |
|
39 ** |
|
40 ** $QT_END_LICENSE$ |
20 ** $QT_END_LICENSE$ |
41 ** |
21 ** |
42 ****************************************************************************/ |
22 ****************************************************************************/ |
43 |
23 |
|
24 // This file was generated by qlalr - DO NOT EDIT! |
|
25 |
|
26 |
44 #include <QtCore/QtDebug> |
27 #include <QtCore/QtDebug> |
45 |
28 |
46 #include <string.h> |
29 #include <string.h> |
47 |
|
48 #include "qscriptast_p.h" |
|
49 |
30 |
50 #define Q_SCRIPT_UPDATE_POSITION(node, startloc, endloc) do { \ |
31 #define Q_SCRIPT_UPDATE_POSITION(node, startloc, endloc) do { \ |
51 node->startLine = startloc.startLine; \ |
32 node->startLine = startloc.startLine; \ |
52 node->startColumn = startloc.startColumn; \ |
33 node->startColumn = startloc.startColumn; \ |
53 node->endLine = endloc.endLine; \ |
34 node->endLine = endloc.endLine; \ |
1134 error_message += QLatin1String ("Expected "); |
1115 error_message += QLatin1String ("Expected "); |
1135 else |
1116 else |
1136 error_message += QLatin1String (", "); |
1117 error_message += QLatin1String (", "); |
1137 |
1118 |
1138 first = false; |
1119 first = false; |
1139 error_message += QLatin1Char('`'); |
1120 error_message += QLatin1String("`"); |
1140 error_message += QLatin1String (spell [expected_tokens [s]]); |
1121 error_message += QLatin1String (spell [expected_tokens [s]]); |
1141 error_message += QLatin1Char('\''); |
1122 error_message += QLatin1String("'"); |
1142 } |
1123 } |
1143 } |
1124 } |
1144 |
1125 |
1145 if (error_message.isEmpty()) |
1126 if (error_message.isEmpty()) |
1146 error_message = lexer->errorMessage(); |
1127 error_message = lexer->errorMessage(); |