From 0a4c461caaab89d93e13c811189799b5883df461 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Fri, 12 Dec 2014 15:38:06 +0100 Subject: [PATCH] Fix the clone() methods for the Array and Dictionary class refs #8065 --- lib/base/array-script.cpp | 4 ++-- lib/base/dictionary-script.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/base/array-script.cpp b/lib/base/array-script.cpp index 006adf0b4..751c552d3 100644 --- a/lib/base/array-script.cpp +++ b/lib/base/array-script.cpp @@ -66,11 +66,11 @@ static void ArrayClear(void) self->Clear(); } -static void ArrayClone(void) +static Array::Ptr ArrayClone(void) { ScriptFrame *vframe = ScriptFrame::GetCurrentFrame(); Array::Ptr self = static_cast(vframe->Self); - self->ShallowClone(); + return self->ShallowClone(); } Object::Ptr Array::GetPrototype(void) diff --git a/lib/base/dictionary-script.cpp b/lib/base/dictionary-script.cpp index 61d43e5e9..c46cdc990 100644 --- a/lib/base/dictionary-script.cpp +++ b/lib/base/dictionary-script.cpp @@ -52,11 +52,11 @@ static bool DictionaryContains(const String& key) return self->Contains(key); } -static void DictionaryClone(void) +static Dictionary::Ptr DictionaryClone(void) { ScriptFrame *vframe = ScriptFrame::GetCurrentFrame(); Dictionary::Ptr self = static_cast(vframe->Self); - self->ShallowClone(); + return self->ShallowClone(); } Object::Ptr Dictionary::GetPrototype(void) -- 2.40.0