From 6b1243cec203637f675febaa3928936ba32188da Mon Sep 17 00:00:00 2001 From: Alexey Prokhin Date: Tue, 2 Nov 2010 16:38:13 +0300 Subject: [PATCH] Fixed creating of arrays of immutable types --- gen/arrays.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gen/arrays.cpp b/gen/arrays.cpp index 66499802..31c9b076 100644 --- a/gen/arrays.cpp +++ b/gen/arrays.cpp @@ -442,7 +442,7 @@ DSliceValue* DtoNewDynArray(Loc& loc, Type* arrayType, DValue* dim, bool default LOG_SCOPE; // typeinfo arg - LLValue* arrayTypeInfo = DtoTypeInfoOf(arrayType); + LLValue* arrayTypeInfo = DtoTypeInfoOf(arrayType->mutableOf()->merge2()); // dim arg assert(DtoType(dim->getType()) == DtoSize_t()); @@ -493,7 +493,7 @@ DSliceValue* DtoNewMulDimDynArray(Loc& loc, Type* arrayType, DValue** dims, size LOG_SCOPE; // typeinfo arg - LLValue* arrayTypeInfo = DtoTypeInfoOf(arrayType); + LLValue* arrayTypeInfo = DtoTypeInfoOf(arrayType->mutableOf()->merge2()); // get value type Type* vtype = arrayType->toBasetype();