Re: Error in opening the Library module file




Mike wrote:
Jugoslav Dujic wrote:
Mike wrote:
| Mike wrote:
|| Originally they pick up some modules, however, they didn't pick up
|| modules which
|| are calling each other. I think this problem is called cyclic
|| dependencies, right?

Right, "cyclic" or "circular". What you had is (as far as I can tell)
allowed by the standard but it will confuse most compilers -- they
expect the dependency hierarchy to be "tree-like" and cannot tell which
module should be compiled first (esp. when they're in the same source
file).

By all means, try to avoid the situation -- the solution is often
to move the mutually shared stuff to a third module, which is
compilable separately.
How to avoid cyclic dependency at first?
What's the general idea to avoid it?

Mike
Jugoslav has said that"
to move the mutually shared stuff to a third module, which is
compilable separately".
But I mean this is the solution when problem happened.
So, how to avoid cyclic dependency before making mistake?
Yes. The solution is also what Jugoslav said.
But when I write a new subroutine/function with some many USEd
modules, do I really need to
see the dependencies ? It's quite troublesome.

Mike

.



Relevant Pages

  • Re: Error in opening the Library module file
    ... | Mike wrote: ... || How to avoid cyclic dependency at first? ... | Jugoslav has said that" ... how to avoid cyclic dependency before making mistake? ...
    (comp.lang.fortran)
  • Re: PIC 18F not so popular yet?
    ... Mike Page wrote: ... > Jonathan Kirwan wrote: ... >> I have purchased my C compilers for the PICs, ... Maybe there is a gcc for PIC in the pipeline somewhere? ...
    (comp.arch.embedded)
  • Re: Project dependency of CVF 6.6c
    ... Mike wrote: ... The .mod file scheme (some U*x compilers also use .M extension) is ...
    (comp.lang.fortran)
  • Re: operator precedence in c - clarifications needed
    ... In article, mike ... understood that according to the "standard" it is undefined. ... but rather that those who write the compilers do not have to take any ... undefined behaviour> But I think that we can all guarantee that there is ...
    (comp.programming)
  • Re: call a function
    ... Mike wrote: ... you can often do nonstandard things with some compilers. ... net | experience comes from bad judgement. ...
    (comp.lang.fortran)