|
![](/i/fill.gif) |
On Sat, 10 May 2008 22:05:53 +0200, Darren New <dne### [at] san rr com> wrote:
> OK. So the linker is doing duplicate-code removal. It also would seem to
> assume that all your object code is compiled with the same template
> source code? Or does it actually look at the object code to make sure
> it's the same?
It must be the same, or the program is ill-formed.
> I.e., if I compile A.cpp that includes T.chh to instantiate
> xyz:vector<long>, and then I edit T.chh and then compile B.cpp that
> instantiates xyz:vector<long> but that now generated different code,
> does the linker carry around both versions of the object code?
If you change T.chh, then A.cpp - and any other source file that includes
T.chh - must be recompiled.
--
FE
Post a reply to this message
|
![](/i/fill.gif) |