Re: Not using .cpp files when programming...
- From: CBFalconer <cbfalconer@xxxxxxxxx>
- Date: Wed, 20 Jul 2005 02:02:20 GMT
"Alf P. Steinbach" wrote:
> robertwessel2@xxxxxxxxx:
>
.... snip ...
>>
>> Your compiles will be slower.
>
> Generally correct.
>
>> You'll have routines multiply defined when you include the same
>> .h in multiple programs that are linked together.
>
> Sorry, that's incorrect: it's not programs that are linked
> together, it's compilation units.
>
>> Or, if you make the member functions static or inline in the
>> class to avoid the name space problems,
>
> Sorry, that's incorrect: neither 'inline' nor 'static' is used
> to avoid name space problems.
>
>> you'll make a larger executable because all the code is
>> duplicated in each compiled program, perhaps many times.
>
> Sorry, that's incorrect: the main feature of 'inline' is the
> acceptance & removal of multiple definitions.
So, broadly speaking, you are in full agreement :-)
--
"If you want to post a followup via groups.google.com, don't use
the broken "Reply" link at the bottom of the article. Click on
"show options" at the top of the article, then click on the
"Reply" at the bottom of the article headers." - Keith Thompson
.
- References:
- Not using .cpp files when programming...
- From: Eric Fortier
- Re: Not using .cpp files when programming...
- From: robertwessel2@xxxxxxxxx
- Re: Not using .cpp files when programming...
- From: Alf P. Steinbach
- Not using .cpp files when programming...
- Prev by Date: Re: OO compilers and efficiency
- Next by Date: Re: Naive Bayes Algorithm?
- Previous by thread: Re: Not using .cpp files when programming...
- Next by thread: Re: Not using .cpp files when programming...
- Index(es):
Relevant Pages
|