Re: How to...

From: Valery Fine (fine@bnl.gov)
Date: Fri Feb 27 1998 - 18:53:33 MET


On 27 Feb 98 at 13:59, Manuel Sanchez Garcia wrote:

>     At the moment I've tried to do it with the following code
> 
> Hades::Hades(void) {
>   Hades **p;
>   TGlobal *gl;
> 
>   gHades=this;
> 
>   gROOT->Reset();
>   gROOT->ProcessLine("Hades *gHades;");
>   gROOT->ProcessLine("#include \"HadDef.h\"");
>   gl=gROOT->GetGlobal("gHades",kTRUE);
>   p=(Hades **)gl->GetAddress();
>   *p=gHades;*/
> 
> }


   Just to make things clear. The "REAL" code the example above is 
going to perform is:

> Hades::Hades(void) {
>   Hades **p;
   TGlobal *gl;
 
   gHades=this;
 
  gROOT->Reset();
   {"Hades *gHades;}
   {"#include \"HadDef.h\"");}
   gl=gROOT->GetGlobal("gHades",kTRUE);
   p=(Hades **)gl->GetAddress();
   *p=gHades;*/

 }

  I'd like to call yout attentio on the scope brackets {}'s around of 
Hades.

  Hope this helps.
                    Valery



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:30 MET