This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [PATCH RFC] pascal pointer type names


Pierre Muller writes:
 > Pascal patch n°6:
 > 
 >    In stabsread.c (define_symbol): there is some strange code to avoid
 > putting a name to a
 > type struct if it is a pointer or a function type.   line 1936.
 > 
 >   The forbids to get pascal types that are pointers to be printed out
 > correctly.
 > 
 >   Anyhow, I don't really understand the comment that is associated with this 
 > code and I was wondering if it was not totally obsolete code.
 >   Are named pointer type also allow in other languages?
 > 
 > 

Pierre, this code has me puzzled as well. I tried a few examples in C,
and I am still not sure what the intended effect is. I disabled the
code in my sandbox and I saw no differences in testsuite runs. Which
per se is not a very meaningful data point.  The code has been
introduced in 93 and modified in 94. So I don't really know if it is
still needed. Any old timers out there?

As far as you change, yes it's fine. 

Elena


 > ChangeLog entry :
 > 
 > 2000-09-04 Pierre Muller <muller@ics.u-strasbg.fr>
 >     * stabsread.c (define_symbol): set the type_name of the type
 >     of the new symbol to the symbol name for type symbol.
 > 
 > Index: stabsread.c
 > ===================================================================
 > RCS file: /cvs/src/src/gdb/stabsread.c,v
 > retrieving revision 1.6
 > diff -b -c -r1.6 stabsread.c
 > *** stabsread.c	2000/07/30 01:48:27	1.6
 > --- stabsread.c	2000/09/04 14:22:25
 > ***************
 > *** 1956,1961 ****
 > --- 1956,1966 ----
 >   
 >   	         Fortunately, this check seems not to be necessary
 >   	         for anything except pointers or functions.  */
 > + 	      /* Pascal accepts names for pointer types      */
 > + 	      if (current_subfile->language == language_pascal)
 > + 		{
 > + 		  TYPE_NAME (SYMBOL_TYPE (sym)) = SYMBOL_NAME (sym);
 > +           	}
 >   	    }
 >   	  else
 >   	    TYPE_NAME (SYMBOL_TYPE (sym)) = SYMBOL_NAME (sym);
 > 
 > 
 > 
 > Pierre Muller
 > Institut Charles Sadron
 > 6,rue Boussingault
 > F 67083 STRASBOURG CEDEX (France)
 > mailto:muller@ics.u-strasbg.fr
 > Phone : (33)-3-88-41-40-07  Fax : (33)-3-88-41-40-99

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]