On 8/22/18, Perry E. Metzger <perry(a)piermont.com> wrote:
Not necessarily. One could produce a language-independent way of
signaling what the type signatures are (perhaps with normalized
language-dependent strings) and the linker could just check that they
match.
True. And the debugger people have already done the design work in
this area. One could probably use DWARF to pass this info to a
linker.
I've seen several languages (like OCaml) hack
around the lack of this
by providing an auxiliary file for a pre-link phase to check off
of. It would be nicer if the linker could just handle that.
I'm pretty sure that is how VMS Ada solved the problem, too.
-Paul W.