1! { dg-do compile }
2!
3! Tests the fix for PR36454, where the PUBLIC declaration for
4! aint and bint was rejected because the access was already set.
5!
6! Contributed by Thomas Orgis <thomas.orgis@awi.de>
7
8module base
9        integer :: baseint
10end module
11
12module a
13        use base, ONLY: aint => baseint
14end module
15
16module b
17        use base, ONLY: bint => baseint
18end module
19
20module c
21        use a
22        use b
23        private
24        public :: aint, bint
25end module
26
27program user
28        use c, ONLY: aint, bint
29
30        aint = 3
31        bint = 8
32        write(*,*) aint
33end program
34