AST: Rename old form of {Generic,}FunctionType::get() to getOld()

This makes it easier to grep for and eventually remove the
remaining usages.

It also allows you to write FunctionType::get({}, ...) to call the
ArrayRef overload empty parameter list, instead of picking the Type
overload and calling it with an empty Type() value.

While I"m at it, in a few places instead of renaming just clean up
usages where it was completely mechanical to do so.
This commit is contained in:
Slava Pestov
2018-08-16 00:35:17 -07:00
parent a54251074c
commit 527ff375dc
28 changed files with 237 additions and 225 deletions

View File

@@ -2603,7 +2603,7 @@ ConstraintSystem::simplifyConstructionConstraint(
// constraint itself.
addValueMemberConstraint(MetatypeType::get(valueType, TC.Context),
DeclBaseName::createConstructor(),
FunctionType::get(tv, resultType),
FunctionType::getOld(tv, resultType),
useDC, functionRefKind,
/*outerAlternatives=*/{},
getConstraintLocator(