summaryrefslogtreecommitdiffstats
path: root/src/corelib/serialization/qcborvalue_p.h
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2018-09-20 13:36:05 +0200
committerEdward Welbourne <edward.welbourne@qt.io>2018-10-08 14:11:08 +0000
commitff7f09d18708119bebb94202d3a3dcb26149ee5a (patch)
treeaa15d57cd1fdb9eed9776db38360ab0b4e59cb64 /src/corelib/serialization/qcborvalue_p.h
parent7f079bf9d0f534fcec747f965565d99845df7aba (diff)
Change QCborArray to pad with invalid on inserting past end
Likewise have mutating operator[] insert an invalid entry at its target index, if beyond the end of the array. This makes it possible to fill an array from high index to low, for example. Change-Id: If71699c20e2623142214ce2c11c4d6e4a120c989 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/serialization/qcborvalue_p.h')
-rw-r--r--src/corelib/serialization/qcborvalue_p.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/corelib/serialization/qcborvalue_p.h b/src/corelib/serialization/qcborvalue_p.h
index 3a28707056..4050d18fa9 100644
--- a/src/corelib/serialization/qcborvalue_p.h
+++ b/src/corelib/serialization/qcborvalue_p.h
@@ -136,6 +136,7 @@ public:
void compact(qsizetype reserved);
static QCborContainerPrivate *clone(QCborContainerPrivate *d, qsizetype reserved = -1);
static QCborContainerPrivate *detach(QCborContainerPrivate *d, qsizetype reserved);
+ static QCborContainerPrivate *grow(QCborContainerPrivate *d, qsizetype index);
qptrdiff addByteData(const char *block, qsizetype len)
{