mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[Type checker] Minor crash avoidance tweaks.
This commit is contained in:
@@ -2880,6 +2880,9 @@ ConstraintSystem::getArgumentInfoLocator(ConstraintLocator *locator) {
|
||||
|
||||
Optional<ConstraintSystem::ArgumentInfo>
|
||||
ConstraintSystem::getArgumentInfo(ConstraintLocator *locator) {
|
||||
if (!locator)
|
||||
return None;
|
||||
|
||||
if (auto *infoLocator = getArgumentInfoLocator(locator)) {
|
||||
auto known = ArgumentInfos.find(infoLocator);
|
||||
if (known != ArgumentInfos.end())
|
||||
|
||||
Reference in New Issue
Block a user