mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-02-28 01:23:14 +01:00
Error if static array is cast to an array such that oldarraysize % newelemsize != 0.
This commit is contained in:
@@ -846,7 +846,7 @@ DValue* DtoCast(Loc& loc, DValue* val, Type* to)
|
||||
return DtoCastClass(val, to);
|
||||
}
|
||||
else if (fromtype->ty == Tarray || fromtype->ty == Tsarray) {
|
||||
return DtoCastArray(val, to);
|
||||
return DtoCastArray(loc, val, to);
|
||||
}
|
||||
else if (fromtype->ty == Tpointer || fromtype->ty == Tfunction) {
|
||||
return DtoCastPtr(loc, val, to);
|
||||
|
||||
Reference in New Issue
Block a user