delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/04/07/12:00:07

Message-ID: <3A4F7E81.C767B4B@caresystems.com.au>
Date: Mon, 01 Jan 2001 04:44:17 +1000
From: leon <Leon AT caresystems DOT com DOT au>
X-Mailer: Mozilla 4.5 [en] (Win95; I)
X-Accept-Language: en
MIME-Version: 1.0
To: djgpp AT delorie DOT com
Subject: about compiler or linker
Reply-To: djgpp AT delorie DOT com

Hello 

just have rather simple question...

in terms of templates:

since those are ADT - i presumed previously that compile cannot compile
template code into a single obj.

rather every instaniation of template class will get compiled as a part
of whatever cpp file that included it and used it.

Would like more info on how the compilation is handled.

also about inline methods - if one declares a method inline - how does
the compiler know - where to get source code from (since usually the
client of a class only includes header files and it is possible to
define inline method in source files).

Would then the linker try and introduce source code to objects when
linking or what?

With best regards - Leon.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019