summaryrefslogtreecommitdiff
path: root/doc/classes/Array.xml
diff options
context:
space:
mode:
authorRyan Roden-Corrent <ryan@rcorre.net>2022-12-30 11:59:07 -0500
committerRyan Roden-Corrent <ryan@rcorre.net>2022-12-30 11:59:07 -0500
commit53181e4090555b6776b10f93215cde4f990f86f2 (patch)
tree96f38a4224c7664f39c095fbd6b69349ecd93813 /doc/classes/Array.xml
parent33afa82fb012b92cb24d2af54d871b417c1232fb (diff)
Explain that Array.duplicate will not deep-copy Object.
This was somewhat implied by specifically calling out nested arrays and dictionaries, but I was still unsure and had to test it myself. One might expect that `Resource` objects, which have a `duplicate` method, might be deep-copied.
Diffstat (limited to 'doc/classes/Array.xml')
-rw-r--r--doc/classes/Array.xml2
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/classes/Array.xml b/doc/classes/Array.xml
index 603974d619..3b67eb809c 100644
--- a/doc/classes/Array.xml
+++ b/doc/classes/Array.xml
@@ -243,7 +243,7 @@
<param index="0" name="deep" type="bool" default="false" />
<description>
Returns a copy of the array.
- If [param deep] is [code]true[/code], a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If [code]false[/code], a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array.
+ If [param deep] is [code]true[/code], a deep copy is performed: all nested arrays and dictionaries are duplicated and will not be shared with the original array. If [code]false[/code], a shallow copy is made and references to the original nested arrays and dictionaries are kept, so that modifying a sub-array or dictionary in the copy will also impact those referenced in the source array. Note that any [Object]-derived elements will be shallow copied regardless of the [param deep] setting.
</description>
</method>
<method name="erase">