summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativeinstruction
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2010-04-08 06:55:57 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2010-04-08 07:23:00 (GMT)
commit3baf285917e2ea3183866768807f2495010602ab (patch)
tree46b1b25adc1b7e7b988f97fc039c6c048b29d3cd /tests/auto/declarative/qdeclarativeinstruction
parent7d82f3875cd26c1cb0ad46ae0a9fddeb87e049d6 (diff)
downloadQt-3baf285917e2ea3183866768807f2495010602ab.zip
Qt-3baf285917e2ea3183866768807f2495010602ab.tar.gz
Qt-3baf285917e2ea3183866768807f2495010602ab.tar.bz2
Improve static assignment to QVariant's in the int and double case
Diffstat (limited to 'tests/auto/declarative/qdeclarativeinstruction')
-rw-r--r--tests/auto/declarative/qdeclarativeinstruction/tst_qdeclarativeinstruction.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativeinstruction/tst_qdeclarativeinstruction.cpp b/tests/auto/declarative/qdeclarativeinstruction/tst_qdeclarativeinstruction.cpp
index a1aceb7..f4df130 100644
--- a/tests/auto/declarative/qdeclarativeinstruction/tst_qdeclarativeinstruction.cpp
+++ b/tests/auto/declarative/qdeclarativeinstruction/tst_qdeclarativeinstruction.cpp
@@ -520,6 +520,24 @@ void tst_qdeclarativeinstruction::dump()
data->bytecode << i;
}
+ {
+ QDeclarativeInstruction i;
+ i.line = 51;
+ i.type = QDeclarativeInstruction::StoreVariantInteger;
+ i.storeInteger.value = 11;
+ i.storeInteger.propertyIndex = 32;
+ data->bytecode << i;
+ }
+
+ {
+ QDeclarativeInstruction i;
+ i.line = 52;
+ i.type = QDeclarativeInstruction::StoreVariantDouble;
+ i.storeDouble.value = 33.7;
+ i.storeDouble.propertyIndex = 19;
+ data->bytecode << i;
+ }
+
QStringList expect;
expect
<< "Index\tLine\tOperation\t\tData1\tData2\tData3\tComments"
@@ -575,6 +593,8 @@ void tst_qdeclarativeinstruction::dump()
<< "47\t\tNA\tDEFER\t\t\t7"
<< "48\t\t48\tSTORE_IMPORTED_SCRIPT\t2"
<< "49\t\t50\tXXX UNKOWN INSTRUCTION\t1234"
+ << "50\t\t51\tSTORE_VARIANT_INTEGER\t\t32\t11"
+ << "51\t\t52\tSTORE_VARIANT_DOUBLE\t\t19\t33.7"
<< "-------------------------------------------------------------------------------";
messages = QStringList();