mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-04-18 01:39:03 +02:00
Add _d_newarrayvT and _d_newarraymvT to create arrays without initialization.
Adjust DtoNewDynArray to use DtoArrayInit for initialization of new arrays. Make Type::tvoid->defaultInit() not error.
This commit is contained in:
@@ -1375,6 +1375,9 @@ Expression *TypeBasic::defaultInit(Loc loc)
|
||||
#endif
|
||||
switch (ty)
|
||||
{
|
||||
case Tvoid:
|
||||
return new IntegerExp(loc, value, Type::tbool);
|
||||
|
||||
case Tchar:
|
||||
value = 0xFF;
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user