Issue 138911
Summary [flang] Missing diagnostic of access private component outside of the module
Labels flang:frontend
Assignees
Reporter DanielCChen
    Consider the following code:
```
module m
    type Base
        private
 procedure(integer), nopass, pointer :: pp1
        procedure(type(Base)), nopass, pointer :: pp2
    end type
end module

program declaration003
use m
    type(Base) :: b1
    b1%pp1 => null()
    b1%pp2 => null()
end
```

Both `pp1` and `pp2` are private components. They shall not be accessible outside of module `m`. 
This usage should be diagnosed. 
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to