OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.fortran-torture/] [execute/] [common_init_1.f90] - Blame information for rev 707

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 695 jeremybenn
! Program to test initialization of common blocks.
2
subroutine test()
3
  character(len=15) :: c
4
  integer d, e
5
  real f
6
  common /block2/ c
7
  common /block/ d, e, f
8
 
9
  if ((d .ne. 42) .or. (e .ne. 43) .or. (f .ne. 2.0)) call abort ()
10
  if (c .ne. "Hello World    ") call abort ()
11
end subroutine
12
 
13
program prog
14
  integer a(2)
15
  real b
16
  character(len=15) :: s
17
  common /block/ a, b
18
  common /block2/ s
19
  data b, a/2.0, 42, 43/
20
  data s /"Hello World"/
21
 
22
  call test ()
23
end program
24
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.