Re: can't load a funtion

From: mdobbs@uvic.ca
Date: Fri Jul 23 1999 - 20:43:11 MEST


Hi matt,

.l is the command for "list local variable"
you need .L "load [file]"

try 
	.L macro2.c
	main()

which works fine on my system. Good luck!, Matt

_________________________________________________________________________
                           Matt   D O B B S
Department of Physics and Astronomy   CERN Address:
University of Victoria                40-1-C15, ATLAS Bldg.
P.O. Box 3055                         Office Tel: 41.22.76.71272
Victoria, British Columbia		
Canada    V8W 3P6			
Email: mdobbs@uvic.ca                 Matthew.Adam.Dobbs@Cern.CH
Office Tel.: (250) 721-7728           http://wwwhep.phys.uvic.ca/~mdobbs/
Home Tel.: (250) 995-1235

On Fri, 23 Jul 1999, Matt Fritts wrote:

> I've been experimenting with loading functions and haven't gotten past
> square one. I use the example from the tutorials
> 
>    // macro2.c
>    #include <iostream.h>
> 
>    int main()
>   {
>      cout << " Hello" << endl;
>      float x = 3.;
>      float y = 5.;
>      int   i= 101;
>      cout << " x = " << x << " y = " << y << " i = " << i << endl;
>      return 0;
>   }
> 
> and enter the line
> 
>    .l macro2.c
> 
> into the interpreter and I get the response
> 
>     No variable table
> 
> and when I type
> 
>     main()
> 
> I get "no symbol main() in current scope". Any idea why? I am using Root
> Version 2.21/08 with interpreter version 5.13.92 on a Dell OptiPlex G1
> running Windows NT.
> 
> Thanks
> 
> -Matt Fritts
> 
> 



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