HDTenEightyP/NetNews huggingface dataset:
From: jlg@cochiti.lanl.gov (J. Giles)
Subject: Re: function name as an argument
Organization: Los Alamos National Laboratory
Date: Fri, 11 Dec 1992 20:41:52 GMT

In article <1992Dec10.155427.2271@e2big.mko.dec.com>, lionel@quark.enet.dec.com (Steve Lionel) writes:
|> [...]
|>        PROGRAM DUMB
|>        character*10 func,arg
|>        external func
|>        call sub(func,arg)
|>        end
|> 
|>        SUBROUTINE SUB (func,arg)
|>        character*(*) func,arg       
|>        arg = func()
|>        write(*,*)arg
|>        END
|> 
|>        FUNCTION FUNC()
|>        character*(*) func
|>        func = 'abcdefghijklmnopqrstuvwxyz'
|>        END
|> 
|> How does SUB know how much to allocate for the function result of SUB?  This
|> isn't known at compile time, so the length has to be passed in to SUB somehow
|> so that SUB can allocate the space at run-time.  [...]

Nope, the space can be allocated statically when PROGRAM DUMB is compiled!
The descriptor passed to SUB can contain the length of the space which has
been allocated and a reference to that memory.  This is the same infor-
mation that needs to be passed if FUNC were called *directly* by the
main program.

|> [...]                                     Wait a minute, you say - that
|> means Fortran has dynamic allocation!  [...]

No.  As I pointed out above,  the memory can be statically allocated by
the main program.  In this case, 10 characters worth.

|. [...]                               Well, it would if this was a standard
|> conforming usage, and it is what I was thinking of when I originally wrote
|> that the length had to be passed, but I had forgotten that this is an 
|> extension supported by VAX FORTRAN.  Indeed, the standard says:
|> 
|> 	If a character function is referenced in a program unit,
|> 	the function length specified in the program unit must be
|> 	an integer constant expression.
|> 
|> 			ANSI X3.9-1978, section 15.2, p15-2, lines 5-7

Because of this quote, it is clear that the construct is, strictly
speaking, non-standard.  However, it can be supported easily and without
dynamic memory.  I rather suspect that the committee might have intended
that passed-in character functions be allowed and that this constraint
was intended to require that the size - wherever it came from - should
be statically determinable.

-- 
J. Giles
From: toon@moene.indiv.nluug.nl (Toon Moene)
Newsgroups: comp.lang.fortran
Subject: Re: Real Programmers
Date: 12 Dec 92 19:12:16 GMT
Organization: Moene Computational Physics, Amsterdam, The Netherlands

> Has anyone out there thought about updating RP?  I mean the term Trash80 
> is so old it brings back a flood of memories and tears to my eyes.  I 
> recall my first computer, a Sinclair.

> One could put an appendix on the end with new references pointing out 
> the newly discovered virtues of FORTRAN.

The problem is not so much with the outdated hardware (spacecraft,  
microcomputers) alluded to, as with the target itself: FORTRAN as of 1991  
is a language with semicolons ;-)
--
Toon Moene (toon@moene.indiv.nluug.nl)
Kantershof 269, 1104 GN  Amsterdam, The Netherlands
Tel.: + 31 20 6982029; Fax: + 31 20 6003411
No Disclaimers; a NeXT at home protects against this occupational hazard.
Newsgroups: comp.lang.fortran
From: prener@watson.ibm.com (Dan Prener)
Subject: Re: Uglifier (was Re: Real Programmers)
Date: Wed, 16 Dec 1992 07:10:50 GMT
Disclaimer: This posting represents the poster's views, not necessarily those of IBM
	<DODD.92Dec15142737@mycenae.cchem.berkeley.edu> <gay.724466320@sfu.ca>
	<1992Dec16.025109.24541@coe.montana.edu> <BzC6n8.J2G@news.cso.uiuc.edu>
Organization: IBM T.J. Watson Research Center, Hawthorne, New York

In article <BzC6n8.J2G@news.cso.uiuc.edu> ercolessi@uimrl3.mrl.uiuc.edu (furio ercolessi) writes:

> In article <1992Dec16.025109.24541@coe.montana.edu>, uesu03@giac1.oscs.montana.edu (Lou Glassy)
> writes:
> |>[...] Last year, an instructor
> |>handed out a small numeric code that followed all of the qualities
> |>listed by {Doctor FORTRAN| James|Laurence|Ian}.  No unnecessary spaces
> |>or commas, all caps, 98.7% of variables were 2 or 3 characters in
> |>length, and a whopping 5 comments in about 1500 lines of source.
> |>Blecch!

> Hmmm ...
> did any one ever made a source code uglifier, a filter removing
> all comments, renaming all variables as A1,A2,... (*),  removing all
> extra spaces, replacing character constants with Holleriths, etc?
> It could be a useful tool after all!  Sometimes you do not want to
> give away your sources, you would like to give only the binaries
> but that's impractical ... this would be a brilliant intermediate 
> solution, give uglified code!  :-)

> Also, sounds like a good exercise for some CS course.

You shouldn't joke about such things.  Frequently, when one invents some
absolutely preposterous scenario, one eventually finds that someone is
actually doing it.

In this case, I refer you to various discussions that have taken place,
over the years, about "shrouded C".  This was one of the approaches that
was proposed in OSF's initial investigations into ANDF.  The idea was 
to use the C language, transformed by exactly the sort of uglifier you
suggest, as an architecture-neutral distribution format for software.
The thought was that C is ubiquitous, and that "shrouding" (i.e.,
uglifying) it would offer reasonable protection for proprietary
software.

In my opinion, that would have been a wise choice.
--
                                   Dan Prener (prener@watson.ibm.com)
Newsgroups: comp.lang.fortran
Subject: Re: Need help with named common blocks
From: steve@grace.cri.nz (Stephen White)
Date: 15 Dec 92 21:04:37
Distribution: comp
Organization: Dept. of Scientific and Industrial Research, NZ.

Things seem to be getting a little confused on this topic. It was not clear in
the original posting if the situation was 

 	SUBROUTINE A
	COMMON /SHAR1/ This, That, Somthing, Else(100)
	COMMON /SHAR1/ And, A, Little, More

	This is quite legal and equivalent to 

	COMMON /SHAR1/ This, That, Somthing, Else(100),
       $      And, A, Little, More

	While 

	SUBROUTINE A
	COMMON /SHAR1/ This, That, Somthing, Else(100)

	SUBROUTINE B
	COMMON /SHAR1/ And, A, Little, More

	is also common (although perhaps not wise) and provides a mechanism 
for shareing storage between two routines (perhaps as a large work area).
Many compilers will warn you that you have common blocks of different lengths
if they are in the same file.

Steve White
Newsgroups: comp.lang.fortran
From: jlg@cochiti.lanl.gov (J. Giles)
Subject: Re: How common are long variable names?
Organization: Los Alamos National Laboratory
Date: Mon, 14 Dec 1992 19:42:39 GMT

In article <1992Dec12.231501.12788@sol.UVic.CA>, klassen@sol.UVic.CA (Melvin Klassen) writes:
|> [...]
|> Page 7 (in "Chapter 1. Language") of "VS FORTRAN Version 2, Language and
|> Library Reference, Release 5" (SC26-4221-7) states:
|>      In CMS and MVS, if a global name is longer than seven characters,
|>      the first four and last three characters are used to form the
|>      external symbol.  The external symbol is then used to identify
|>      the global entity.  For example, ...
|> 
|> In the "Release 3" edition (March 1988) of this manual, 
|> similarly-worded text appears on page 8.
|> 
|> It seems clear to me!

Yes, quite clear.  Clearly bad.  I would prefer it to say, "because
of limitiations in the system environment, global identifiers are limited
to 7 characters; attempts to declare longer global identifiers result
in a fatal syntax error."  That would be a good implementation.  Allowing
longer names and then altering them to fit is a trap and a source of
errors which are difficult to find and correct.  It is also unnecessary.

-- 
J. Giles
From: khb@chiba.Eng.Sun.COM (Keith Bierman fpgoup)
Newsgroups: comp.lang.fortran
Subject: Re: elapsed time
Date: 14 Dec 92 16:26:01
Organization: SunPro
Distribution: usa
NNTP-Posting-Host: chiba
In-reply-to: bandy@netnews.jhuapl.edu's message of 14 Dec 92 18:15:47 GMT


In article <Bz9HEB.Dy5@netnews.jhuapl.edu> bandy@netnews.jhuapl.edu (Mike Bandy) writes:

,,,
   You'll have to look at the system services offered by the operating
   system under which your program runs.  Fortran, unlike C, does
   not a standard portfolio of common system services.

True for '77 but not "90".

13.9.1  Date and time subroutines

The subroutines DATE_AND_TIME and SYSTEM_CLOCK return data from the
date and real-time clock.  The time returned is local, but there are
facilities for finding out the difference between local time and
Coordinated Universal Time.

...

  DATE_AND_TIME (DATE, TIME, ZONE, VALUES)
  Optional DATE, TIME,  ZONE, VALUES

...

  SYSTEM_CLOCK (COUNT, COUNT_RATE, COUNT_MAX)
  Optional COUNT, COUNT_RATE,  COUNT_MAX
--
----------------------------------------------------------------
Keith H. Bierman    keith.bierman@Sun.COM| khb@chiba.Eng.Sun.COM
SunPro 2550 Garcia MTV 12-40             | (415 336 2648) fax 964 0946
Mountain View, CA 94043  <speaking for myself, not Sun*> Copyright 1992

Newsgroups: comp.lang.fortran
From: hybl@umbc4.umbc.edu (Dr. Albert Hybl (UMAB-BIOPHYS))
Subject: Re: Real Programmers
Organization: Univ. of MD, Baltimore County
Date: Wed, 16 Dec 1992 20:02:22 GMT

In article <1gngdqINN8b5@nz12.rz.uni-karlsruhe.de> ig25@rz.uni-karlsruhe.de writes:
>In article <DODD.92Dec16060307@mycenae.cchem.berkeley.edu> dodd@mycenae.cchem.berkeley.edu (Lawrence R. Dodd) writes:
>
>>so are we agreed that the final version would be the following?
>>
>>85367 FORMAT(100(3H:-))/22HFOR THE HUMOR-IMPARED.)
>>      WRITE(6,85367)
>
>Oh my god...  where's the leading space?  What sort of carriage control
>do you use?
>
>Apart from that, I'd find
>
>      WRITE(6,43H(1H 100(3H:-))/1X22HFOR THE HUMOR-IMPARED.))
>
How about:
853660WRITE(6,85367)
853670WRITE(6,43H(1H 100(3H:-))/1X22HFOR THE HUMOR-IMPARED.))

Happy Holidays,
Albert (hybl@umbc4.umbc.edu)
Newsgroups: comp.lang.fortran
From: uesu03@giac1.oscs.montana.edu (Lou Glassy)
Subject: Re: Real Programmers
Keywords: n
Organization: Montana State University, Bozeman  MT
Date: Wed, 16 Dec 1992 02:51:09 GMT

Various attributions barbarously deleted to save space:

!>>  Doctor>   101 Format (100 (' :-)'), /, ' For the Humor-impared.')
!>>  Doctor>       Write (Kout, 101)
!>>
!>> line 2: Error: attempt to use undefined variable "kout"
!>> line 2: Error: bad unit specifier type in write statement
!>> Compilation failed
!
!>  James> Real FORTRAN programmers always write to unit 6, and then bitch about
!>  James> the compiler being broken when it doesn't work.  write(*,101) is for
!>  James> sissies :-)
!
!>  [no, REAL PROGRAMMERS code like this...]
!
!>  85367 FORMAT(100(':-)')/'FOR THE HUMOR-IMPARED.')
!>        WRITE(6,85367)
!
![and Ian adds: "Don't real programmers say 3H:-) etc?"]

Ugh!  That explains it!  Hollerith Constants!  Last year, an instructor
handed out a small numeric code that followed all of the qualities
listed by {Doctor FORTRAN| James|Laurence|Ian}.  No unnecessary spaces
or commas, all caps, 98.7% of variables were 2 or 3 characters in
length, and a whopping 5 comments in about 1500 lines of source.
Blecch!  He did with things with EQUIVALENCE no maintenance programmer
would repeat in polite company...

:-)

Lou
-- 
Lou Glassy (uesu03@giac1.oscs.montana.edu)  //  That was the equation!
Earth Sci. Dept., Montana State University  \\  Existence!...Survival must
Bozeman, Montana 59715 USA   {on planet 3,  //  cancel out programming! 
Sol System, Orion Arm, Milky Way Galaxy}    \\                -- Rok 
Newsgroups: comp.lang.fortran
From: knox@spruce.gsfc.nasa.gov (Robert Knox)
Subject: Re: Uglifier (was Re: Real Programmers)
Reply-To: knox@spruce.gsfc.nasa.gov
Organization: NASA/GSFC
Date: Fri, 18 Dec 1992 23:35:25 GMT

Re. output from Mortran:

On my first largish Fortran projects I used a pre-processor 
call FLECS, for CDC 170 series machines.  (You know 60-bit,
10-byte words, no lower case support, etc.)   This preprocessor 
added a nice range of useful control structures, WHILE, UNTIL, 
block IF and ELSE, even named PROCEDUREs, but then translated 
them into ASSIGN statements which were all piled at the bottom 
of each FORTRAN 66 compilation unit.  It made some phases of 
debugging a true delight.  At least with classical spaghetti 
code there is usually some logic to the sequence of jumps, 
here nearly all branches went to the end of the program first 
and then back to some arbitrary location with a machine 
generated label number.


- Bob Knox
- Biospheric Sciences Branch, Code 923.0
- NASA/Goddard Space Flight Center, Greenbelt, MD 20771 
- knox@spruce.gsfc.nasa.gov
From: eng10406@nusunix1.nus.sg (TAN KAR GEE)
Newsgroups: comp.lang.fortran
Subject: WANTED URGENTLY!!PLEASE!!
Date: 20 Dec 92 12:41:57 GMT
Organization: National University of Singapore
X-Newsreader: TIN [version 1.1 PL6]

My sister is doing a Fortran77 project on the game Othello. Our command
of the Fortran language is not powerful enough to write a good program.
Since this project will take up 50% of her final examinations, she is
very worried right now. Can anyone send a sample of the algorithm to
rescue her? Please send to either eng10406@nusunix2 or
eng10104@nusunix2. Thank you in advance!! Merry Christmas and Happy New
Year!!

Kar-Gee Tan
Singapore.
From: tregilli@s7.msi.umn.edu (Ian Lee Tregillis [Astro])
Newsgroups: comp.lang.fortran
Subject: Random-number responses
Date: 16 Dec 92 18:35:41 GMT
Organization: University of Minnesota

Greetings,
	Several people have expressed an interest
in the responses to my request for a random-number
generator.  I think it's only fair that I share since
everybody was so quick to respond.  
	I haven't been on the net long, however, so
I'm not sure what the net.eitquette is here.  If nobody
has any objections, I'll try to edit out all of the 
extraneous material from the mailings and post what's
been sent to me.  If there's a better way, let me know.

Timidly,
Ian
Newsgroups: comp.lang.fortran
From: gay@selkirk.sfu.ca (Ian D. Gay)
Subject: Re: Real Programmers
Organization: Simon Fraser University, Burnaby, B.C., Canada
Date: Wed, 16 Dec 1992 00:38:40 GMT

dodd@mycenae.cchem.berkeley.edu (Lawrence R. Dodd) writes:


>>>>>> "James" == James Davies <jrbd@craycos.com> writes:

>  James> In article <DODD.92Dec15053719@mycenae.cchem.berkeley.edu> dodd@roebling.poly.edu writes:
>>
>>>>>>> "Doctor" == Doctor FORTRAN <jsvrc@rc.rit.edu> writes:
>>
>>  Doctor>   101 Format (100 (' :-)'), /, ' For the Humor-impared.')
>>  Doctor>       Write (Kout, 101)
>>
>> line 2: Error: attempt to use undefined variable "kout"
>> line 2: Error: bad unit specifier type in write statement
>> Compilation failed

>  James> Real FORTRAN programmers always write to unit 6, and then bitch about
>  James> the compiler being broken when it doesn't work.  write(*,101) is for
>  James> sissies :-)

>Real FORTRAN programmers don't use lowercase letters, no excess space, no
>commas unless the compiler complains, and no unit number that can be
>remembered. so

> 85367 FORMAT(100(':-)')/'FOR THE HUMOR-IMPARED.')
>       WRITE(6,85367)
>       

Don't real programmers say 3H:-) etc?
Newsgroups: comp.lang.fortran
From: mroussel@alchemy.chem.utoronto.ca (Marc Roussel)
Subject: Re: Uglifier (was Re: Real Programmers)
Organization: Department of Chemistry, University of Toronto
Date: Fri, 18 Dec 1992 01:34:51 GMT

In article <1992Dec15.232933.1@slacvx.slac.stanford.edu>
fairfield@slacvx.slac.stanford.edu writes:
>    The Fortran output produced by Mortran (at least the earlier versions)
>comes pretty close. :-(

     I'm probably labeling myself as a still-wet-behind-the-ears newbie
by asking this question, but so be it.  What's Mortran?

				Marc R. Roussel
                                mroussel@alchemy.chem.utoronto.ca
From: btd@iastate.edu (Benjamin T Dehner)
Newsgroups: comp.lang.fortran
Subject: Re: Dynamic Memory Allocation in FORTRAN, Question
Date: 20 Dec 92 20:07:44 GMT
Organization: Iowa State University, Ames IA

In <Dec.20.02.22.20.1992.7312@spade.rutgers.edu> xiong@spade.rutgers.edu (Xiong) writes:

>Hi, I am wondering if it is possible to allocate memory dynomically in
>FORTRAN as in C? I am loooking for something equivalent to:

>	int * a;
>	a = (int *) malloc (numx * sizeof (int));

>in C.

	As far as I know, in standard fortran, the answer is no.  On Ultrix
systems there is are three system calls:  malloc, free, and falloc, (obviously
stolen and added into C :) which are capable of dynamic memory allocation.
	If you are on an Ultrix system, see the man pages.  If you aren't,
I have no idea where these routines come from (decfort?) or if they are
available.

Ben

-----------------------------------------------------------------------------
Benjamin T. Dehner    Dept. of Physics and Astronomy 
btd@iastate.edu       Iowa State University 
                      Ames, IA 50011
From: dodd@mycenae.cchem.berkeley.edu (Lawrence R. Dodd)
Newsgroups: comp.lang.fortran
Subject: Re: Real Programmers
Date: 12 Dec 92 06:28:44
Organization: Dept of Chemical Engineering, Polytechnic Univ, NY, USA
NNTP-Posting-Host: mycenae.cchem.berkeley.edu
In-reply-to: rolfe@dsuvax.dsu.edu's message of Sat, 12 Dec 1992 06:08:03 GMT


>>>>> "Tim" == Tim Rolfe <rolfe@dsuvax.dsu.edu> writes:

  Tim> With all due respect, look at the DATE of the piece -- 1982.  I'd be
  Tim> GREATLY surprised if the targetting of Galileo hadn't changed in 10
  Tim> years!  I do grant, of course, that some might read the item without
  Tim> care, and it is THOSE readers that you wish to inform.

  Tim> This item has been in the computing culture now for 10 years.  It's not
  Tim> surprising that it isn't the most up-to-date treatment of issues.
  Tim> -- 

Has anyone out there thought about updating RP?  I mean the term Trash80 is so
old it brings back a flood of memories and tears to my eyes.  I recall my
first computer, a Sinclair.

One could put an appendix on the end with new references pointing out the
newly discovered virtues of FORTRAN.


Newsgroups: comp.lang.fortran
From: tamin@hounix.org (Taminun Budjaja)
Subject: How to do I/O preconnection?
Organization: Houston UNIX Users Group (HOUNIX), Houston, TX
Date: Fri, 11 Dec 1992 04:51:01 GMT

C
As suggested by the subject, I am interested in finding out how to do I/O preconnection.  I am running under REAL/IX (SVR3.2 with real-time features) using GLS Fortran (Green Hills Fortran adapted by Modcomp for REAL/IX).  Any help will be greatly appreciated.
From: dodd@mycenae.cchem.berkeley.edu (Lawrence R. Dodd)
Newsgroups: comp.lang.fortran
Subject: Re: Real Programmers
Date: 16 Dec 92 14:03:07 GMT
	<DODD.92Dec15142737@mycenae.cchem.berkeley.edu> <gay.724466320@sfu.ca>
	<1992Dec16.025109.24541@coe.montana.edu>
Organization: Dept of Chemical Engineering, Polytechnic Univ, NY, USA
NNTP-Posting-Host: mycenae.cchem.berkeley.edu
In-reply-to: uesu03@giac1.oscs.montana.edu's message of Wed, 16 Dec 1992 02:51:09 GMT


>>>>> "Lou" == Lou Glassy <uesu03@giac1.oscs.montana.edu> writes:

  Lou> Various attributions barbarously deleted to save space:

  Lou> !>>  Doctor>   101 Format (100 (' :-)'), /, ' For the Humor-impared.')
  Lou> !>>  Doctor>       Write (Kout, 101)
  Lou> !>>
  Lou> !>> line 2: Error: attempt to use undefined variable "kout"
  Lou> !>> line 2: Error: bad unit specifier type in write statement
  Lou> !>> Compilation failed
  Lou> !
  Lou> !>  James> Real FORTRAN programmers always write to unit 6, and then bitch about
  Lou> !>  James> the compiler being broken when it doesn't work.  write(*,101) is for
  Lou> !>  James> sissies :-)
  Lou> !
  Lou> !>  [no, REAL PROGRAMMERS code like this...]
  Lou> !
  Lou> !>  85367 FORMAT(100(':-)')/'FOR THE HUMOR-IMPARED.')
  Lou> !>        WRITE(6,85367)
  Lou> !
  Lou> ![and Ian adds: "Don't real programmers say 3H:-) etc?"]

  Lou> Ugh!  That explains it!  Hollerith Constants!  Last year, an instructor
  Lou> handed out a small numeric code that followed all of the qualities
  Lou> listed by {Doctor FORTRAN| James|Laurence|Ian}.  No unnecessary spaces
  Lou> or commas, all caps, 98.7% of variables were 2 or 3 characters in
  Lou> length, and a whopping 5 comments in about 1500 lines of source.
  Lou> Blecch!  He did with things with EQUIVALENCE no maintenance programmer
  Lou> would repeat in polite company...

sounds like my kinda code. were the comments along the lines of "FIND X AND
OTHER QUANTITIES?" or "THE CODE IS TOO COMPLICATED TO EXPLAIN?"

so are we agreed that the final version would be the following?

85367 FORMAT(100(3H:-))/22HFOR THE HUMOR-IMPARED.)
      WRITE(6,85367)
Newsgroups: comp.lang.fortran
From: lwang@mariner.amc.edu.au (Luo Wang)
Subject: Help needed in using fortran
Organization: Australian Maritime College
Date: Wed, 16 Dec 92 23:12:06 GMT

Hi, 

I have a package programmed with Fortran 77. It was programmed by one of our
teammate in the same research team. But, he left last month. I havn't learned 
any Fortran before.

Before he left, the teammate showed me the procedure to compile the program.
I could run the program just like using an application software such as word
procesor. I mean what I know is just how to use it.

Then the program was running allright. But recently I have some difficulties
in running and compiling the program.

In running:

run-time error R6002
- floating point not loaded

In compiling:( FORTRAN optimizing compiler version 5.00)

Command line warning D4005: could not execute ' link.exe';

Can anyone there tell me what the problem is?

Thank you very much.

Luo Wang
From: fairfield@slacvx.slac.stanford.edu
Subject: Re: Need help with named common blocks
Organization: Stanford Linear Accelerator Center
Distribution: comp
Date: Mon, 14 Dec 1992 05:16:23 GMT

In article <jumper.724304615@fritz.catt.ncsu.edu>, jumper@fritz.catt.ncsu.edu (Michael Lanham) writes:
[...]
> I have several program src files.  In the file with the BLOCK DATA segment,
> the COMMON block is named and shaped as follows:
> 
>       IMPLICIT INTEGER (A-Z)
>       COMMON/SHARE1/TABLE(1770),NOPU(54),FLHS(54),UNUSE0(122),
>      -           XLATE(127),KWT1(50),KWT2(50),STACK1(50),STACK2(50),
>      -           SYMBOL(8),VALUE(8),UNUSE5(16),CHAR(80),VALUXY(12),
>      -           LISTX(61),INTERX(70),SYNTAB(2,26),CHARX(26),TAG(50),
>      -           (50)
> 
> 
> 
> In most of the other modules the common block share1 is entered the same way.
> Now I found an additional SHARE1 that is different.
> 
>       COMMON/SHARE1/NSVT(1000),OSVT(1000),
>      -             OPND(3),LINE(133),UNUSE3(574),
>      -             OUTTAB(50,4),SUPP(100,2),SYMBL(2),UNUSE2(18)
> 
> Is an accurate way of thinking of SHARE1 is the first declaration plus the
> second concatenated to the end of the second?  I need to know this so I can
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> correctly build my union in C to accurately reflect the SHARE1 structure.

    No.  In FORTRAN, the named common is a single storage area.  A mis-feature
of FORTRAN is that common blocks may be declared differently in different
program sections, but each still refers to the same storage area.  Thus, in
the example above, NSVT(1) is the same storage location as TABLE(1), etc.

    Note that the first declaration makes COMMON/SHARE1/ 3130 4-byte integers
long (barring other declaration following, and inacurracies in my arithmetic),
while the second declaration is only 2710 long.  Well, that's probably 
unlikely since something like CHAR(80) is most likely declared later to be
of type CHARACTER*1 (or BYTE or INTEGER*1 or LOGICAL*1)...  The point is
that most compilers allow the total length of a common to be different in
different program sections.  Some will (nicely) take the longest declared
length as the total, others (not so nice) will take the _last_ declared
length.

    In any case, you may want to investigate how /SHARE1/ is being used in
the odd-man-out routine to be sure it's not an out-and-out error...

		Cheers, Ken
-- 
 Dr. Kenneth H. Fairfield    |  Internet: Fairfield@Slac.Stanford.Edu
 SLAC, P.O.Box 4349, MS 98   |  DECnet:   45537::FAIRFIELD (45537=SLACVX)
 Stanford, CA   94309        |  BITNET    Fairfield@Slacvx
 ----------------------------------------------------------------------------
 These opinions are mine, not SLAC's, Stanford's, nor the DOE's...
Newsgroups: comp.lang.fortran