1250963Sachim! { dg-do run }
2250963Sachim! PR40853 Error in namelist IO.
3250963Sachim! Test case derived from example given in PR. < jvdelisle@gcc.gnu.org >
4program test
5  implicit none
6  type tao_title_struct
7    character(2) justify
8  end type
9  type tao_plot_page_struct
10    real shape_height_max
11    type (tao_title_struct) title ! Comment this line out and the bug goes away.
12    real size(2)
13  end type
14  type (tao_plot_page_struct) plot_page
15  namelist / params / plot_page
16  open (10, status="scratch")
17  write(10,'(a)')"  &params"
18  write(10,'(a)')"  plot_page%size=5 , 2,"
19  write(10,'(a)')"/"
20  rewind(10)
21  read (10, nml = params)
22  if (any(plot_page%size .ne. (/ 5, 2 /))) call abort
23  close (10)
24end program
25
26