We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8f15c4c commit 051bf9cCopy full SHA for 051bf9c
flang/lib/Semantics/scope.cpp
@@ -272,7 +272,7 @@ std::optional<parser::MessageFixedText> Scope::SetImportKind(ImportKind kind) {
272
? "IMPORT,NONE must be the only IMPORT statement in a scope"_err_en_US
273
: "IMPORT,ALL must be the only IMPORT statement in a scope"_err_en_US;
274
} else if (kind != *importKind_ &&
275
- (kind != ImportKind::Only || kind != ImportKind::Only)) {
+ (kind != ImportKind::Only && *importKind_ != ImportKind::Only)) {
276
return "Every IMPORT must have ONLY specifier if one of them does"_err_en_US;
277
} else {
278
return std::nullopt;
0 commit comments