mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-03 00:20:40 +03:00
Resolving nested context for structs.
* * * Another fix for nested structs * * * Yet another fix for nested structs
This commit is contained in:
parent
e3afcf8a8d
commit
360a99caa9
7 changed files with 63 additions and 22 deletions
|
@ -364,10 +364,16 @@ void DtoAssign(Loc& loc, DValue* lhs, DValue* rhs)
|
|||
if (!t->equals(t2)) {
|
||||
// FIXME: use 'rhs' for something !?!
|
||||
DtoAggrZeroInit(lhs->getLVal());
|
||||
#if DMDV2
|
||||
TypeStruct *ts = (TypeStruct*) lhs->getType();
|
||||
if (ts->sym->isNested() && ts->sym->vthis)
|
||||
DtoResolveNestedContext(loc, ts->sym, lhs->getLVal());
|
||||
#endif
|
||||
}
|
||||
else {
|
||||
DtoAggrCopy(lhs->getLVal(), rhs->getRVal());
|
||||
}
|
||||
|
||||
}
|
||||
else if (t->ty == Tarray) {
|
||||
// lhs is slice
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue