mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
Indexer fix
This commit is contained in:
parent
c53ef1c346
commit
e5d90d42db
2 changed files with 7 additions and 5 deletions
|
@ -46,19 +46,21 @@ DeferredTupleAssignData::~DeferredTupleAssignData()
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
BfBaseClassWalker::BfBaseClassWalker(BfType* typeA, BfType* typeB, BfModule* module)
|
BfBaseClassWalker::BfBaseClassWalker(BfType* typeA, BfType* typeB, BfModule* module, bool allowInterfaces)
|
||||||
{
|
{
|
||||||
mMayBeFromInterface = false;
|
mMayBeFromInterface = false;
|
||||||
|
|
||||||
if (typeB == typeA)
|
if (typeB == typeA)
|
||||||
typeB = NULL;
|
typeB = NULL;
|
||||||
|
|
||||||
if ((typeA != NULL) && (!typeA->IsInterface()))
|
if ((typeA != NULL) &&
|
||||||
|
((!typeA->IsInterface()) || (allowInterfaces)))
|
||||||
mTypes[0] = typeA->ToTypeInstance();
|
mTypes[0] = typeA->ToTypeInstance();
|
||||||
else
|
else
|
||||||
mTypes[0] = NULL;
|
mTypes[0] = NULL;
|
||||||
|
|
||||||
if ((typeB != NULL) && (!typeB->IsInterface()))
|
if ((typeB != NULL) &&
|
||||||
|
((!typeB->IsInterface()) || (allowInterfaces)))
|
||||||
mTypes[1] = typeB->ToTypeInstance();
|
mTypes[1] = typeB->ToTypeInstance();
|
||||||
else
|
else
|
||||||
mTypes[1] = NULL;
|
mTypes[1] = NULL;
|
||||||
|
@ -21973,7 +21975,7 @@ void BfExprEvaluator::HandleIndexerExpression(BfIndexerExpression* indexerExpr,
|
||||||
BfPropertyDef* foundProp = NULL;
|
BfPropertyDef* foundProp = NULL;
|
||||||
BfTypeInstance* foundPropTypeInst = NULL;
|
BfTypeInstance* foundPropTypeInst = NULL;
|
||||||
|
|
||||||
BfBaseClassWalker baseClassWalker(target.mType, NULL, mModule);
|
BfBaseClassWalker baseClassWalker(target.mType, NULL, mModule, true);
|
||||||
|
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
|
|
|
@ -311,7 +311,7 @@ public:
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BfBaseClassWalker();
|
BfBaseClassWalker();
|
||||||
BfBaseClassWalker(BfType* typeA, BfType* typeB, BfModule* module);
|
BfBaseClassWalker(BfType* typeA, BfType* typeB, BfModule* module, bool allowInterfaces = false);
|
||||||
void AddConstraints(BfType* srcType, BfGenericParamInstance* genericParam);
|
void AddConstraints(BfType* srcType, BfGenericParamInstance* genericParam);
|
||||||
void AddInterfaces(BfType* srcType, BfTypeInstance* typeInst);
|
void AddInterfaces(BfType* srcType, BfTypeInstance* typeInst);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue