Jean-Pierre, If you are talking about class members, there is a change between 2.25 and 3.0. In version 3, the Root libs are not linked anymore with the special library libNew.so. This library has the operators new and delete redefined. The new operator presets class members to 0. We thought that there are more pros than cons in using the standard C++ behaviour where you must take care of pointer initialisation yourself. We provide two Root executable modules in $ROOTSYS/bin: root.exe and rootn.exe The rootn.exe module is linked with libNew. If you execute rootn.exe instead of root.exe, your class members that are pointers should be preset to 0. Rene Brun Jean-Pierre Ernenwein wrote: > > Hello all, > > since version 3.0 of ROOT, I have noticed that a pointer on something > is not 0 when declared : > Double_t *b; > b is not 0 > > before, it was 0, and became different only when allocated : > b=Double_t[4] > for example > > is it due to C++ libs used for compilation ? > is it a normal feature of the compilator (and a bonus due to previous root > versions?) > It occurs only for compilated libraries, not with the interpreter > > Thanks > Jean-Pierre Ernenwein, GRPHE > Universite de Haute Alsace, IUT Mulhouse, dept SGM / IReS Strasbourg > Tel: 03 89 33 75 56 (IUT) / 03 88 10 66 19 ou 66 77 (IReS) > Portable : 06 89 26 40 46
This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:51:03 MET