[AST] Explicitly track things marked __owned.

This commit is contained in:
Huon Wilson
2018-02-27 17:50:11 -08:00
parent ae0027a225
commit e307e54098
48 changed files with 358 additions and 141 deletions

View File

@@ -1954,7 +1954,7 @@ namespace {
if (auto type = param->getTypeLoc().getType()) {
// FIXME: Need a better locator for a pattern as a base.
Type openedType = CS.openUnboundGenericType(type, locator);
assert(!param->isLet() || !openedType->is<InOutType>());
assert(!param->isImmutable() || !openedType->is<InOutType>());
param->setType(openedType->getInOutObjectType());
param->setInterfaceType(openedType->getInOutObjectType());
continue;