Skip to content

Commit 77dd7e2

Browse files
authored
Merge pull request #80129 from hamishknight/rdar118642163
2 parents b1adb78 + d0e1749 commit 77dd7e2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Sema/TypeCheckAttr.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4638,7 +4638,7 @@ void AttributeChecker::visitCustomAttr(CustomAttr *attr) {
46384638

46394639
// Complain if this isn't the primary result-builder attribute.
46404640
auto attached = decl->getAttachedResultBuilder();
4641-
if (attached != attr) {
4641+
if (attached && attached != attr) {
46424642
diagnose(attr->getLocation(), diag::result_builder_multiple,
46434643
isa<ParamDecl>(decl));
46444644
diagnose(attached->getLocation(), diag::previous_result_builder_here);

0 commit comments

Comments
 (0)