aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4compileddata_p.h
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2014-03-27 19:18:55 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-03-28 16:25:16 +0100
commit1526771ebf473af8a65bce77cfd16be67b6eb944 (patch)
treeb4167f7f93703db93da1a5f5b486da1ada4d007e /src/qml/compiler/qv4compileddata_p.h
parent0ed744c1ef955cdb94cbd89c58283663da490d7d (diff)
V4 string table cleanups
Move the string table (index and data) to the end of the compilation unit. That makes it easier to extend the string table later with new strings - for example when transitioning from JS data to an entire QML unit - because all the other offsets within the JS data remain the same. Change-Id: Ib28caf943ee2ec74b7acc19c2980de0853bb8086 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/compiler/qv4compileddata_p.h')
-rw-r--r--src/qml/compiler/qv4compileddata_p.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/compiler/qv4compileddata_p.h b/src/qml/compiler/qv4compileddata_p.h
index d6d2419d74..afcf2c6a24 100644
--- a/src/qml/compiler/qv4compileddata_p.h
+++ b/src/qml/compiler/qv4compileddata_p.h
@@ -228,10 +228,10 @@ struct Unit
return reinterpret_cast<const JSClassMember*>(ptr + sizeof(JSClass));
}
- static int calculateSize(uint headerSize, uint nStrings, uint nFunctions, uint nRegExps, uint nConstants,
+ static int calculateSize(uint headerSize, uint nFunctions, uint nRegExps, uint nConstants,
uint nLookups, uint nClasses) {
return (headerSize
- + (nStrings + nFunctions + nClasses) * sizeof(uint)
+ + (nFunctions + nClasses) * sizeof(uint)
+ nRegExps * RegExp::calculateSize()
+ nConstants * sizeof(QV4::ReturnedValue)
+ nLookups * Lookup::calculateSize()