Re: RE : VC++6.0 and 7.0 are not supported anymore from ROOT4-04-2 or newer

From: Roland Kuhn <rkuhn_at_e18.physik.tu-muenchen.de>
Date: Thu, 12 May 2005 14:44:34 +0200


Hi Rene!

On May 12, 2005, at 7:52 AM, Rene Brun wrote:

> Hi Christian,
>
> I understand some of your points. Myself, I am not a fan
> of the "modern" cast syntax because, as you say, it makes
> the code opaque to most readers and the pretext that you have
> more type safety is just an illusion.

Well, in principle a const_cast allows the rest of the type to be checked, but I agree that it is so inconvenient that it is rendered useless. (That could have been avoided by choosing a more compact syntax.)

> I also agree with you that exposing a templated interface
> to users is not good , or at least premature.
> However, I don't think that we can go away from the general trend
> with C++. We have started using templates internally where we
> believe that we have more to gain than to loose. We are not in
> 1992! compilers have evolved to support the current C++ standard.
> It would be a mistake to restrict ROOT to a subset of C++ in the
> future. Young programers could not understand!

Seconded! Using templates internally is for sure a win if the alternative would be stupid copy-and-paste. I have certainly profited very much over the last years from using templates in my own analysis code, because if they're done right they increase readability and maintainability. Afterwards I discovered some of the uses in the "Design Patterns" literature, which clearly shows that templates do have intuitive properties, which should be exploited.

On the other hand some corners of "templates"-land are rather obscure, plus there have been annoying compiler bugs (I remember a gcc2.96 issue with exceptions thrown from inline template methods, which could not be caught anywhere in the program). Most of the bugs have been ironed out, I have not encountered a compiler error in a long time with my code.

So, my principle is: use features which make life easier, but stay away from the over-complicated obscure cases.

> In this move, it is not our intention to destroy what we have,
> even if sometime we have to make compromises with different
> cultures.
> I believe that the recent merge of SEAL with ROOT was essential.
> Users will see the benefits in the coming months.
> I am on the floor since long enough to be extremely cautious
> on all facets of software development. I was very pleased to
> see that our recent workshop between CINT and Reflex experts
> was very positive, a first step to improved products in the
> medium term.
>
> Anyhow, we welcome comments like yours. It would be good if
> more people could express their opinion.
>

Okay, you asked for it: There's a standard, use it!

Ciao,

                                        Roland

--
TU Muenchen, Physik-Department E18, James-Franck-Str. 85747 Garching
Telefon 089/289-12592; Telefax 089/289-12570
--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on a mailing list?

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GS/CS/M/MU d-(++) s:+ a-> C+++ UL++++ P-(+) L+++ E(+) W+ !N K- w--- M+ 
!V Y+
PGP++ t+(++) 5 R+ tv-- b+ DI++ e+++>++++ h---- y+++
------END GEEK CODE BLOCK------


Received on Thu May 12 2005 - 14:44:47 MEST

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:07 MET