replica nfl jerseysreplica nfl jerseyssoccer jerseyreplica nfl jerseys forums.silverfrost.com :: View topic - What is the limit on amount of continuations
forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

What is the limit on amount of continuations

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General
View previous topic :: View next topic  
Author Message
DanRRight



Joined: 10 Mar 2008
Posts: 2924
Location: South Pole, Antarctica

PostPosted: Fri Jun 22, 2012 11:41 pm    Post subject: What is the limit on amount of continuations Reply with quote

in current Fortran standard and FTN95? Is it still 19?
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 8211
Location: Salford, UK

PostPosted: Sat Jun 23, 2012 8:25 am    Post subject: Reply with quote

I have had a quick look at the Fortran 95 Standard and cannot see any mention of a limit.
Back to top
View user's profile Send private message AIM Address
davidb



Joined: 17 Jul 2009
Posts: 560
Location: UK

PostPosted: Sat Jun 23, 2012 10:03 am    Post subject: Reply with quote

For FORTRAN 77

maximum is 19

For Fortran 90 and Fortran 95

maximum in fixed-form source files is 19 (same as FORTRAN 77)
maximum in free-form source files is 39

For Fortran 2003 and Fortran 2008

maximum in fixed-form and free-form files is 255
_________________
Programmer in: Fortran 77/95/2003/2008, C, C++ (& OpenMP), java, Python, Perl
Back to top
View user's profile Send private message
JohnCampbell



Joined: 16 Feb 2006
Posts: 2615
Location: Sydney

PostPosted: Mon Jun 25, 2012 1:01 am    Post subject: Reply with quote

Based on this example, the limit is 99 for FTN95 free format.
This appears arbitrary, but can have an effect in extended data statements or long COMMON definitions when using in-line comments (Modules do not have this problem).

Code:
  integer i
  character*5 aaa(101)
  data aaa /    &
     '   1 ',   &
     '   2 ',   &
     '   3 ',   &
     '   4 ',   &
     '   5 ',   &
     '   6 ',   &
     '   7 ',   &
     '   8 ',   &
     '   9 ',   &
     '  10 ',   &
     '  11 ',   &
     '  12 ',   &
     '  13 ',   &
     '  14 ',   &
     '  15 ',   &
     '  16 ',   &
     '  17 ',   &
     '  18 ',   &
     '  19 ',   &
     '  20 ',   &
     '  21 ',   &
     '  22 ',   &
     '  23 ',   &
     '  24 ',   &
     '  25 ',   &
     '  26 ',   &
     '  27 ',   &
     '  28 ',   &
     '  29 ',   &
     '  30 ',   &
     '  31 ',   &
     '  32 ',   &
     '  33 ',   &
     '  34 ',   &
     '  35 ',   &
     '  36 ',   &
     '  37 ',   &
     '  38 ',   &
     '  39 ',   &
     '  40 ',   &
     '  41 ',   &
     '  42 ',   &
     '  43 ',   &
     '  44 ',   &
     '  45 ',   &
     '  46 ',   &
     '  47 ',   &
     '  48 ',   &
     '  49 ',   &
     '  50 ',   &
     '  51 ',   &
     '  52 ',   &
     '  53 ',   &
     '  54 ',   &
     '  55 ',   &
     '  56 ',   &
     '  57 ',   &
     '  58 ',   &
     '  59 ',   &
     '  60 ',   &
     '  61 ',   &
     '  62 ',   &
     '  63 ',   &
     '  64 ',   &
     '  65 ',   &
     '  66 ',   &
     '  67 ',   &
     '  68 ',   &
     '  69 ',   &
     '  70 ',   &
     '  71 ',   &
     '  72 ',   &
     '  73 ',   &
     '  74 ',   &
     '  75 ',   &
     '  76 ',   &
     '  77 ',   &
     '  78 ',   &
     '  79 ',   &
     '  80 ',   &
     '  81 ',   &
     '  82 ',   &
     '  83 ',   &
     '  84 ',   &
     '  85 ',   &
     '  86 ',   &
     '  87 ',   &
     '  88 ',   &
     '  89 ',   &
     '  90 ',   &
     '  91 ',   &
     '  92 ',   &
     '  93 ',   &
     '  94 ',   &
     '  95 ',   &
     '  96 ',   &
     '  97 ',   &
     '  98 ',   &
     '  99 ',   &
     ' 100 ',   &
     ' 101 '  /
!
      do i = 1,size(aaa)
        write (*,*) i,aaa(i)
      end do
      end
Back to top
View user's profile Send private message
DanRRight



Joined: 10 Mar 2008
Posts: 2924
Location: South Pole, Antarctica

PostPosted: Mon Jun 25, 2012 9:32 am    Post subject: Reply with quote

Thanks for the info. I find FTN95 often exceeds the Standard Fortran95 limits
Back to top
View user's profile Send private message
davidb



Joined: 17 Jul 2009
Posts: 560
Location: UK

PostPosted: Mon Jun 25, 2012 10:50 pm    Post subject: Reply with quote

Johns example gives an error that the number of continuations is more than 99. However if you use the /ISO flag, the compiler gives the error that the number of lines is more than 39.
_________________
Programmer in: Fortran 77/95/2003/2008, C, C++ (& OpenMP), java, Python, Perl
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group