Re: Newbie making a dumb mistake but can you help?
- From: nospam@xxxxxxxxxxxxx (Richard Maine)
- Date: Wed, 26 Apr 2006 18:09:17 -0700
JustMe2 <do_mail@xxxxxxx> wrote:
guess I'll have to make a make file.
I'm not quite sure how that relates to the stated problems, but ok.
On rereading your original post in this thread, two issues occur to me.
Perhaps you were just wording things sloppily, but then perhaps not, as
both of these are errors I have seen people make.
1. You talked about how you "write and compile the .mod files." Do you
mean that literally? If so, that's an error. A .mod file is not
something you write and compile. To compile a module, you put the module
source code in a .f90 file just like any other Fortran source. The
compiler will make the .mod file during compilation. If you actually
write and try to compile a file with a .mod name, I'm not sure what will
happen, but odds are that it won't be good. Don't do that.
2. You also talked about putting interfaces various places. No, don't do
that for module procedures. If you try to do that, it will cause
problems. The USE statement provides all the interface information for
procedures in the module. If you try to also write an interface body,
that will not work.
As a rough approximation. since you imply that you are familliar with
other languages, the .mod file is somewhat like a C header file, except
that the compiler automatically writes it for you. The analogy isn't
perfect, but its a reasonable first approximation.
--
Richard Maine | Good judgement comes from experience;
email: last name at domain . net | experience comes from bad judgement.
domain: summertriangle | -- Mark Twain
.
- Follow-Ups:
- Re: Newbie making a dumb mistake but can you help?
- From: JustMe2
- Re: Newbie making a dumb mistake but can you help?
- References:
- Newbie making a dumb mistake but can you help?
- From: JustMe2
- Re: Newbie making a dumb mistake but can you help?
- From: Colin Watters
- Re: Newbie making a dumb mistake but can you help?
- From: JustMe2
- Re: Newbie making a dumb mistake but can you help?
- From: Richard Maine
- Re: Newbie making a dumb mistake but can you help?
- From: JustMe2
- Newbie making a dumb mistake but can you help?
- Prev by Date: Re: Newbie making a dumb mistake but can you help?
- Next by Date: FYI: Fortran Library Down Temporarily
- Previous by thread: Re: Newbie making a dumb mistake but can you help?
- Next by thread: Re: Newbie making a dumb mistake but can you help?
- Index(es):
Relevant Pages
|