This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Problems while debugging fortran


> The committee wanted language that would be clear in all sorts of
> hairy corner cases: What about Java, where the entry point isn't
> selected until link time?  What about Ada, where every module can have
> its own main, and they all get run in some order?  What about global
> constructors in C++ --- they're the first user code that gets
> executed?  What about COBOL, where I fell asleep?

Yeah, the case of Ada is a bit particular, because the entry point
and the main procedures are completely distinct. There is no way that
the *compiler* knows whether one procedure is going to be the "main"
or not for a given program. In fact, the same unit, compiled once,
can be used as the main in one program, and as a simple procedure
that you call in another program. Because of that, I'm not sure
that a DWARF-based solution to encoding the name of the main procedure
is practical.

-- 
Joel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]