Clarify that resize doesn't initialize memory
Some users might expect resize() to initialize added elements to zero. This clarifies that it is not the case.
This commit is contained in:
parent
512211b61c
commit
56f66aa8fc
3 changed files with 3 additions and 0 deletions
|
@ -112,6 +112,7 @@
|
||||||
<argument index="0" name="idx" type="int" />
|
<argument index="0" name="idx" type="int" />
|
||||||
<description>
|
<description>
|
||||||
Sets the size of the array. If the array is grown, reserves elements at the end of the array. If the array is shrunk, truncates the array to the new size.
|
Sets the size of the array. If the array is grown, reserves elements at the end of the array. If the array is shrunk, truncates the array to the new size.
|
||||||
|
[b]Note:[/b] Added elements are not automatically initialized to 0 and will contain garbage, i.e. indeterminate values.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="set">
|
<method name="set">
|
||||||
|
|
|
@ -65,6 +65,7 @@
|
||||||
<argument index="0" name="idx" type="int" />
|
<argument index="0" name="idx" type="int" />
|
||||||
<description>
|
<description>
|
||||||
Sets the size of the array. If the array is grown, reserves elements at the end of the array. If the array is shrunk, truncates the array to the new size.
|
Sets the size of the array. If the array is grown, reserves elements at the end of the array. If the array is shrunk, truncates the array to the new size.
|
||||||
|
[b]Note:[/b] Added elements are not automatically initialized to 0 and will contain garbage, i.e. indeterminate values.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="set">
|
<method name="set">
|
||||||
|
|
|
@ -65,6 +65,7 @@
|
||||||
<argument index="0" name="idx" type="int" />
|
<argument index="0" name="idx" type="int" />
|
||||||
<description>
|
<description>
|
||||||
Sets the size of the array. If the array is grown, reserves elements at the end of the array. If the array is shrunk, truncates the array to the new size.
|
Sets the size of the array. If the array is grown, reserves elements at the end of the array. If the array is shrunk, truncates the array to the new size.
|
||||||
|
[b]Note:[/b] Added elements are not automatically initialized to 0 and will contain garbage, i.e. indeterminate values.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="set">
|
<method name="set">
|
||||||
|
|
Loading…
Reference in a new issue