1! { dg-do run }
2! { dg-options "-O0" }
3!
4! Tests fix for PR21459 - This is the original example.
5!
6program format_string
7  implicit none
8  character(len=*), parameter :: rform='(F15.5)', &
9  cform="(' (', F15.5, ',' F15.5, ') ')"
10  call print_a_number(cform)
11contains
12subroutine print_a_number(style)
13  character(len=*) :: style
14  write(*, style) cmplx(42.0, 99.0) ! { dg-output "99.00000" }
15end subroutine print_a_number
16end program format_string
17