Rich Grise wrote:
> On Sat, 18 Feb 2006 00:37:18 -0800, Le Chaud Lapin wrote:
> ...
> > expert who has participated in the standards process, Stan Lippman,
> > called "Pure C++".
> > (http://msdn.microsoft.com/msdnmag/issues/05/02/PureC/default.aspx)
The
> > first thing you notice about the code written in this column is that
it
> > is anything but pure C++. Instead, there is .NET fecal matter
>
> I never got to anything like "C++"; this stopped me:
> " It sup****ts a static object model that is optimized for the speed
and
> size of its executables. However, it doesn't sup****t runtime
modification
> of the program other than heap allocation."
>
> Well, duh! That's kinda the _point_ of C++, isn't it?
But C++ does allow program modification at compile-time, through
programmatic code generation with templates. Extending that capability
from compile-time to runtime would seem to be an obvious, and not
particularly momentous, step. So the fact that C++ currently lacks
runtime program modification I would view as a limitation of the
current language - rather than to reflect a conscious design decision
informed by some deeply-held, overaching philosophy. Moreover a
philosophical basis for not sup****ting this feature would be completely
moot. Since C++ has no underlying runtime with which to sup****t dynamic
program modification, it's simply inconceivable that C++ could ever
sup****t such a feature in a practical way. So any discussion about
adding runtime program modification to C++ would - in almost all
certainty - be no kind of a discussion at all.
Now the word "limitation" in the paragraph above has a strictly neutral
connotation. After all, this limitation may not be one that anyone who
uses C++ has ever cared about. But by the same token, it is difficult
to see how a limitation that some group of programmers do care about,
is ever likely to be a net benefit for a programming language. After
all there are at least some current language features in C++ (goto,
macros, #defines come to mind) that are widely disdained by many C++
programmers. Yet the fact that C++ does sup****t such unpopular language
features probably does not deter large numbers of programmers from
writing software in C++. And the explanation is simply that it is quite
straightfoward to write a C++ program that simply avoids using these
constructs. Likewise, even those adamently opposed to runtime program
modification as a practice, could simply refrain from modifying their
program at runtime were C++ suddenly (and somewhat magically) able to
sup****t such behavior.
And for the benefit of anyone who has dreamt of using runtime program
modification in C++, it is certainly legitimate to point out that
C++/CLI has such sup****t and that C++ does not. It would be extremely
difficult for C++ advocates to criticize such language feature
comparisons, precisely because one of the more effective (and quite
legitimate) selling points used for years to promote C++ over C as a
better programming language, has been to enumerate all of the language
features that C++ sup****ts and which C does not.
Greg
[ See http://www.gotw.ca/resources/clcm.htm
for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]


|