AST: Remove ModuleDecl parameter from more places

This commit is contained in:
Slava Pestov
2024-07-05 12:01:48 -04:00
parent b7117aa877
commit fae01d9776
107 changed files with 288 additions and 420 deletions

View File

@@ -519,7 +519,7 @@ static SILValue emitCodeForConstantArray(ArrayRef<SILValue> elements,
// created array and the second element is a pointer to the internal storage
// of the array.
SubstitutionMap subMap = arrayType->getContextSubstitutionMap(
module.getSwiftModule(), astContext.getArrayDecl());
astContext.getArrayDecl());
FunctionRefInst *arrayAllocateRef =
builder.createFunctionRef(loc, arrayAllocateFun);
ApplyInst *applyInst = builder.createApply(
@@ -683,8 +683,7 @@ static SILValue emitCodeForSymbolicValue(SymbolicValue symVal,
"aggregate symbolic value's type and expected type do not match");
VarDecl *propertyDecl = structDecl->getStoredProperties().front();
Type propertyType = expectedType->getTypeOfMember(
propertyDecl->getModuleContext(), propertyDecl);
Type propertyType = expectedType->getTypeOfMember(propertyDecl);
SymbolicValue propertyVal = symVal.lookThroughSingleElementAggregates();
SILValue newPropertySIL = emitCodeForSymbolicValue(
propertyVal, propertyType, builder, loc, stringInfo);