mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-02 16:11:08 +03:00
Use toParent instead of toParent2 to determine whether inside a function body.
This commit is contained in:
parent
f46f865375
commit
ca91c52c5a
1 changed files with 1 additions and 1 deletions
|
@ -972,7 +972,7 @@ void DtoConstInitGlobal(VarDeclaration* vd)
|
|||
// FIXME: I don't think it's thread safe ...
|
||||
|
||||
bool doLazyInit = false;
|
||||
Dsymbol* par = vd->toParent2();
|
||||
Dsymbol* par = vd->toParent();
|
||||
|
||||
if (par && par->isFuncDeclaration() && vd->init)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue