Change SILParser::parseSILIdentifierSwitch to use the template parameter.

In `parseSILIdentifierSwitch`, `Result` has the type of one of the template parameters. Without this patch we are requiring `T` to be a `ValueOwnershipKind` (or convertible to that), which makes the function not usable on other result types and defeats the point of having a templated argument.
This commit is contained in:
Richard Wei
2018-11-13 13:30:27 -08:00
parent 1113bded00
commit 194f352919

View File

@@ -264,7 +264,7 @@ namespace {
return true;
}
Result = ValueOwnershipKind(*Iter);
Result = T(*Iter);
return false;
}