aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4compiler_p.h
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2013-08-16 08:57:58 +0200
committerLars Knoll <lars.knoll@digia.com>2013-08-16 10:14:22 +0200
commitd017fe9b38c74d2cc2fa754af3bf9e32357f149c (patch)
treed56a6421c026d4ec03165722b66540c7752a9d1e /src/qml/compiler/qv4compiler_p.h
parentb88626a3a59f7dcd01be6fe2a8236b14ca1176f5 (diff)
Store line number mappings in the compiled function
Change-Id: I4e37aac3618b20ccd52ce4833098781374a3daf6 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/compiler/qv4compiler_p.h')
-rw-r--r--src/qml/compiler/qv4compiler_p.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/qml/compiler/qv4compiler_p.h b/src/qml/compiler/qv4compiler_p.h
index 753e4627e7..1032369a53 100644
--- a/src/qml/compiler/qv4compiler_p.h
+++ b/src/qml/compiler/qv4compiler_p.h
@@ -70,8 +70,11 @@ struct JSUnitGenerator {
int registerRegExp(QQmlJS::V4IR::RegExp *regexp);
+ void registerLineNumberMapping(QQmlJS::V4IR::Function *function, const QVector<uint> &mappings);
+
QV4::CompiledData::Unit *generateUnit();
- void writeFunction(char *f, int index, QQmlJS::V4IR::Function *irFunction);
+ // Returns bytes written
+ int writeFunction(char *f, int index, QQmlJS::V4IR::Function *irFunction);
QHash<QString, int> stringToId;
QStringList strings;
@@ -79,6 +82,7 @@ struct JSUnitGenerator {
QHash<QQmlJS::V4IR::Function *, uint> functionOffsets;
QList<CompiledData::Lookup> lookups;
QVector<CompiledData::RegExp> regexps;
+ QHash<QQmlJS::V4IR::Function *, QVector<uint> > lineNumberMappingsPerFunction;
};
}