patterns/fix: Accessing variables in global scope no longer crashes

This commit is contained in:
WerWolv 2021-04-18 20:26:23 +02:00
parent ebbbcafe5c
commit 5b692067d8
1 changed files with 2 additions and 1 deletions

View File

@ -81,6 +81,7 @@ namespace hex::lang {
PatternData *currPattern = nullptr;
// Local member access
if (!this->m_currMembers.empty())
currPattern = this->findPattern(*this->m_currMembers.back(), path);
// If no local member was found, try globally