File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -731,14 +731,13 @@ void CheckHelper::CheckObjectEntity(
731
731
}
732
732
} else if (!IsIntentInOut (symbol)) { // C1586
733
733
messages_.Say (
734
- " non-POINTER dummy argument of pure %s must have INTENT() or VALUE attribute" _warn_en_US ,
734
+ " non-POINTER dummy argument of pure %s must have INTENT() or VALUE attribute" _err_en_US ,
735
735
what);
736
736
ok = false ;
737
737
}
738
- if (ok && InFunction ()) {
738
+ if (ok && InFunction () && ! InModuleFile () && ! InElemental () ) {
739
739
if (context_.IsEnabled (common::LanguageFeature::RelaxedPureDummy)) {
740
- if (context_.ShouldWarn (common::LanguageFeature::RelaxedPureDummy) &&
741
- !InModuleFile () && !InElemental ()) {
740
+ if (context_.ShouldWarn (common::LanguageFeature::RelaxedPureDummy)) {
742
741
messages_.Say (
743
742
" non-POINTER dummy argument of pure function should be INTENT(IN) or VALUE" _warn_en_US);
744
743
}
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ pure real function f02(a)
53
53
real , value :: a ! ok
54
54
end function
55
55
pure real function f03(a) ! C1583
56
- ! ERROR : non-POINTER dummy argument of pure function must have INTENT() or VALUE attribute
56
+ ! WARNING : non-POINTER dummy argument of pure function must have INTENT() or VALUE attribute
57
57
real :: a
58
58
end function
59
59
pure real function f03a(a)
@@ -83,7 +83,7 @@ pure function f08() ! C1585
83
83
end function
84
84
85
85
pure subroutine s01 (a ) ! C1586
86
- ! ERROR : non-POINTER dummy argument of pure subroutine must have INTENT() or VALUE attribute
86
+ ! WARNING : non-POINTER dummy argument of pure subroutine must have INTENT() or VALUE attribute
87
87
real :: a
88
88
end subroutine
89
89
pure subroutine s01a (a )
You can’t perform that action at this time.
0 commit comments