Fix an array size parameter error in gen9.f90

Also use assumed shaped for dummy argument arrays where possible.

If a  Fortran procedure has  an interface declaration,  which includes
all procedures exported  from modules, then dummy  arguments should be
declared as assumed shape if possible.  This allows compiler generated
array bounds checking and compile time array shape checking.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6456 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Bill Somerville 2016-02-01 13:41:11 +00:00
parent 35fd23c392
commit 020803e901
2 changed files with 9 additions and 9 deletions

View File

@ -44,8 +44,8 @@ subroutine gen9(msg0,ichk,msgsent,i4tone,itype)
nsym2=206
call encode232(i1Msg8BitBytes,nsym2,i1EncodedBits) !Encode K=32, r=1/2
call interleave9(i1EncodedBits,1,i1ScrambledBits) !Interleave bits
call packbits(i1ScrambledBits,nsym2,3,i4DataSymbols) !Pk 3-bits into words
call graycode(i4DataSymbols,69,1,i4GrayCodedSymbols) !Apply Gray code
call packbits(i1ScrambledBits,nsym2/3,3,i4DataSymbols) !Pk 3-bits into words
call graycode(i4DataSymbols,nsym2/3,1,i4GrayCodedSymbols) !Apply Gray code
! Insert sync symbols at ntone=0 and add 1 to the data-tone numbers.
j=0

View File

@ -7,8 +7,8 @@ subroutine packbits(dbits,nsymd,m0,sym)
! Pack 0s and 1s from dbits() into sym() with m0 bits per word.
! NB: nsymd is the number of packed output words.
integer sym(nsymd)
integer*1 dbits(*)
integer sym(:)
integer*1 dbits(:)
k=0
do i=1,nsymd
@ -30,8 +30,8 @@ subroutine packbits(dbits,nsymd,m0,sym)
! NB: nsymd is the number of input words, and m0 their length.
! there will be m0*nsymd output bytes, each 0 or 1.
integer sym(nsymd)
integer*1 dbits(*)
integer sym(:)
integer*1 dbits(:)
k=0
do i=1,nsymd
@ -405,7 +405,7 @@ subroutine packbits(dbits,nsymd,m0,sym)
parameter (NBASE=37*36*10*27*27*27)
parameter (NBASE2=262178562)
character*22 msg0,msg
integer dat(12)
integer dat(:)
character*12 c1,c2
character*4 c3
character*6 grid6
@ -512,7 +512,7 @@ subroutine packbits(dbits,nsymd,m0,sym)
parameter (NBASE=37*36*10*27*27*27)
parameter (NGBASE=180*180)
integer dat(12)
integer dat(:)
character c1*12,c2*12,grid*4,msg*22,grid6*6,psfx*4,junk2*4
logical cqnnn
@ -901,7 +901,7 @@ subroutine packbits(dbits,nsymd,m0,sym)
subroutine pack50(n1,n2,dat)
integer*1 dat(11),i1
integer*1 dat(:),i1
i1=iand(ishft(n1,-20),255) !8 bits
dat(1)=i1