Skip to content

Commit 0e80b4e

Browse files
committed
Expand type refinement contexts to encompass attributes
1 parent a11baaf commit 0e80b4e

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

lib/Sema/TypeCheckAvailability.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -634,13 +634,7 @@ class TypeRefinementContextBuilder : private ASTWalker {
634634
return Range;
635635
}
636636

637-
// For pattern binding declarations, include the attributes in the source
638-
// range so that we're sure to cover any property wrappers.
639-
if (auto patternBinding = dyn_cast<PatternBindingDecl>(D)) {
640-
return D->getSourceRangeIncludingAttrs();
641-
}
642-
643-
return D->getSourceRange();
637+
return D->getSourceRangeIncludingAttrs();
644638
}
645639

646640
// Creates an implicit decl TRC specifying the deployment

0 commit comments

Comments
 (0)