File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -73,6 +73,11 @@ void NonisolatedNonsendingByDefaultMigrationTarget::diagnose() const {
73
73
return ;
74
74
}
75
75
76
+ // Only diagnose declarations from the current module.
77
+ if (decl->getModuleContext () != ctx.MainModule ) {
78
+ return ;
79
+ }
80
+
76
81
// If the attribute cannot appear on this kind of declaration, we can't
77
82
// diagnose it.
78
83
if (!DeclAttribute::canAttributeAppearOnDecl (DeclAttrKind::Concurrent,
@@ -153,10 +158,6 @@ void NonisolatedNonsendingByDefaultMigrationTarget::diagnose() const {
153
158
154
159
const auto featureName = feature.getName ();
155
160
if (decl) {
156
- // Only diagnose declarations from the current module.
157
- if (decl->getModuleContext () != ctx.MainModule )
158
- return ;
159
-
160
161
// Diagnose the function, but slap the attribute on the storage declaration
161
162
// instead if the function is an accessor.
162
163
auto *functionDecl = dyn_cast<AbstractFunctionDecl>(decl);
You can’t perform that action at this time.
0 commit comments