Re: Help Constructing Fictional Cross-Religious Movement
- From: Brooks Moses <bmoses-nospam@xxxxxxxxxxxxxxxxxx>
- Date: Sat, 27 Aug 2005 17:13:47 -0700
Wilson Heydt wrote:
In article <m2wtm8i75q.fsf@xxxxxxxxxxxxxxxxxxxxxxx>, Charlton Wilbur <cwilbur@xxxxxxxxxxxxxx> wrote:"WH" == Wilson Heydt <whheydt@xxxxxxxxxxx> writes:I suspect we're running into a nomenclature issue here, but I'm not familiar enough with COBOL to know for sure. When you say "subroutine," are you speaking of what I'd call a function in C? i.e., a chunk of code that takes some number of arguments, possibly modifies them, and possibly returns a value? one entry point?
With the caveat that, while a COBOL subroutine can return a value, it isn't normally done that way. Usually one passes some number of parameters and one of those is where any return data is stuffed. One can write single subroutines, or collect them into either statically or dynamically linked libraries.
I believe you'd also made the caveat earlier that COBOL subroutines can have multiple entry points. In Fortran, the multiple entry points can also have different argument lists.
Also, I'm not completely sure if C has the capability to save the values of a function's local variables between calls to the function. I suspect it probably does, though.
The result of this is that it seems to be nearly equivalent to the computer-science ideal of a function, but it can be used to implement an object that's limited to having exactly one instance (and that instance being in global namespace, I think). The fact that it can be used to do this is probably one of those things that is trivially obvious to people with Hal's experience, but doesn't occur to many people who are writing Java books. :)
- Brooks
-- The "bmoses-nospam" address is valid; no unmunging needed. .
- Follow-Ups:
- Re: Help Constructing Fictional Cross-Religious Movement
- From: Chris Dollin
- Re: Help Constructing Fictional Cross-Religious Movement
- From: David M. Palmer
- Re: Help Constructing Fictional Cross-Religious Movement
- References:
- Re: Help Constructing Fictional Cross-Religious Movement
- From: Richard D. Latham
- Re: Help Constructing Fictional Cross-Religious Movement
- From: Wilson Heydt
- Re: Help Constructing Fictional Cross-Religious Movement
- From: Charlton Wilbur
- Re: Help Constructing Fictional Cross-Religious Movement
- From: Wilson Heydt
- Re: Help Constructing Fictional Cross-Religious Movement
- Prev by Date: Re: No Exit & Sartre
- Next by Date: Re: Help Constructing Fictional Cross-Religious Movement
- Previous by thread: Re: Help Constructing Fictional Cross-Religious Movement
- Next by thread: Re: Help Constructing Fictional Cross-Religious Movement
- Index(es):
Relevant Pages
|