mirror of
				https://gitlab.com/freepascal.org/fpc/source.git
				synced 2025-11-04 06:39:25 +01:00 
			
		
		
		
	* Fix stabs generation problem reported by Jonas
This commit is contained in:
		
							parent
							
								
									2c01fc3afd
								
							
						
					
					
						commit
						c22f863764
					
				@ -345,12 +345,18 @@ implementation
 | 
			
		||||
                        begin
 | 
			
		||||
                          ttypesym(p).isusedinstab:=true;
 | 
			
		||||
{                          ttypesym(p).concatstabto(debuglist);}
 | 
			
		||||
                          {not stabs for forward defs }
 | 
			
		||||
                          if not Ttypesym(p).isstabwritten then
 | 
			
		||||
                            begin
 | 
			
		||||
                              stab_str:=Ttypesym(p).stabstring;
 | 
			
		||||
                              if assigned(stab_str) then
 | 
			
		||||
                                debuglist.concat(Tai_stabs.create(stab_str));
 | 
			
		||||
                              Ttypesym(p).isstabwritten:=true;
 | 
			
		||||
                              if Ttypesym(p).restype.def.typesym=p then
 | 
			
		||||
                                Tstoreddef(Ttypesym(p).restype.def).concatstabto(debuglist)
 | 
			
		||||
                              else
 | 
			
		||||
                                begin
 | 
			
		||||
                                  stab_str:=Ttypesym(p).stabstring;
 | 
			
		||||
                                  if assigned(stab_str) then
 | 
			
		||||
                                    debuglist.concat(Tai_stabs.create(stab_str));
 | 
			
		||||
                                  Ttypesym(p).isstabwritten:=true;
 | 
			
		||||
                                end;
 | 
			
		||||
                            end;
 | 
			
		||||
                        end;
 | 
			
		||||
{$endif GDB}
 | 
			
		||||
@ -673,7 +679,10 @@ implementation
 | 
			
		||||
end.
 | 
			
		||||
{
 | 
			
		||||
  $Log$
 | 
			
		||||
  Revision 1.76  2004-01-31 18:40:15  daniel
 | 
			
		||||
  Revision 1.77  2004-01-31 22:48:31  daniel
 | 
			
		||||
    * Fix stabs generation problem reported by Jonas
 | 
			
		||||
 | 
			
		||||
  Revision 1.76  2004/01/31 18:40:15  daniel
 | 
			
		||||
    * Last steps before removal of aasmtai dependency in symsym can be
 | 
			
		||||
      accomplished.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -326,9 +326,6 @@ interface
 | 
			
		||||
    var
 | 
			
		||||
       generrorsym : tsym;
 | 
			
		||||
 | 
			
		||||
    const
 | 
			
		||||
       current_object_option : tsymoptions = [sp_public];
 | 
			
		||||
 | 
			
		||||
    { rtti and init/final }
 | 
			
		||||
    procedure generate_rtti(p:tsym);
 | 
			
		||||
    procedure generate_inittable(p:tsym);
 | 
			
		||||
@ -372,12 +369,6 @@ implementation
 | 
			
		||||
    constructor tstoredsym.create(const n : string);
 | 
			
		||||
      begin
 | 
			
		||||
         inherited create(n);
 | 
			
		||||
         symoptions:=current_object_option;
 | 
			
		||||
{$ifdef GDB}
 | 
			
		||||
         isstabwritten := false;
 | 
			
		||||
{$endif GDB}
 | 
			
		||||
{         fileinfo:=akttokenpos;}
 | 
			
		||||
         lastref:=defref;
 | 
			
		||||
         _mangledname:=nil;
 | 
			
		||||
      end;
 | 
			
		||||
 | 
			
		||||
@ -389,9 +380,6 @@ implementation
 | 
			
		||||
      begin
 | 
			
		||||
         inherited loadsym(ppufile);
 | 
			
		||||
         _mangledname:=nil;
 | 
			
		||||
{$ifdef GDB}
 | 
			
		||||
         isstabwritten := false;
 | 
			
		||||
{$endif GDB}
 | 
			
		||||
      end;
 | 
			
		||||
 | 
			
		||||
{    procedure tstoredsym.buildderef;
 | 
			
		||||
@ -2292,9 +2280,8 @@ implementation
 | 
			
		||||
    var stabchar:string[2];
 | 
			
		||||
 | 
			
		||||
    begin
 | 
			
		||||
      if restype.def=nil then
 | 
			
		||||
        stabstring:=nil
 | 
			
		||||
      else
 | 
			
		||||
      stabstring:=nil;
 | 
			
		||||
      if restype.def<>nil then
 | 
			
		||||
        begin
 | 
			
		||||
          if restype.def.deftype in tagtypes then
 | 
			
		||||
            stabchar:='Tt'
 | 
			
		||||
@ -2466,7 +2453,10 @@ implementation
 | 
			
		||||
end.
 | 
			
		||||
{
 | 
			
		||||
  $Log$
 | 
			
		||||
  Revision 1.150  2004-01-31 21:09:58  daniel
 | 
			
		||||
  Revision 1.151  2004-01-31 22:48:31  daniel
 | 
			
		||||
    * Fix stabs generation problem reported by Jonas
 | 
			
		||||
 | 
			
		||||
  Revision 1.150  2004/01/31 21:09:58  daniel
 | 
			
		||||
    * Stabs lineinfo problem fixed
 | 
			
		||||
 | 
			
		||||
  Revision 1.149  2004/01/31 18:40:15  daniel
 | 
			
		||||
 | 
			
		||||
@ -852,11 +852,16 @@ implementation
 | 
			
		||||
      if Tsym(p).typ=typesym then
 | 
			
		||||
        begin
 | 
			
		||||
          ao:=Taasmoutput(arg);
 | 
			
		||||
          Tsym(p).isstabwritten:=false;
 | 
			
		||||
          stabstr:=Tsym(p).stabstring;
 | 
			
		||||
          if stabstr<>nil then
 | 
			
		||||
            ao.concat(Tai_stabs.create(stabstr));
 | 
			
		||||
          Tsym(p).isstabwritten:=true;
 | 
			
		||||
          if Ttypesym(p).restype.def.typesym=p then
 | 
			
		||||
            Tstoreddef(Ttypesym(p).restype.def).concatstabto(ao)
 | 
			
		||||
          else
 | 
			
		||||
            begin
 | 
			
		||||
              Tsym(p).isstabwritten:=false;
 | 
			
		||||
              stabstr:=Tsym(p).stabstring;
 | 
			
		||||
              if stabstr<>nil then
 | 
			
		||||
                ao.concat(Tai_stabs.create(stabstr));
 | 
			
		||||
              Tsym(p).isstabwritten:=true;
 | 
			
		||||
            end;
 | 
			
		||||
        end;
 | 
			
		||||
    end;
 | 
			
		||||
 | 
			
		||||
@ -2359,7 +2364,10 @@ implementation
 | 
			
		||||
end.
 | 
			
		||||
{
 | 
			
		||||
  $Log$
 | 
			
		||||
  Revision 1.132  2004-01-31 18:40:15  daniel
 | 
			
		||||
  Revision 1.133  2004-01-31 22:48:31  daniel
 | 
			
		||||
    * Fix stabs generation problem reported by Jonas
 | 
			
		||||
 | 
			
		||||
  Revision 1.132  2004/01/31 18:40:15  daniel
 | 
			
		||||
    * Last steps before removal of aasmtai dependency in symsym can be
 | 
			
		||||
      accomplished.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -219,6 +219,9 @@ interface
 | 
			
		||||
      memprocnodetree : tmemdebug;
 | 
			
		||||
{$endif MEMDEBUG}
 | 
			
		||||
 | 
			
		||||
    const
 | 
			
		||||
       current_object_option : tsymoptions = [sp_public];
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
implementation
 | 
			
		||||
 | 
			
		||||
@ -228,6 +231,7 @@ implementation
 | 
			
		||||
       symdef,
 | 
			
		||||
       gdb;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
{****************************************************************************
 | 
			
		||||
                                Tdef
 | 
			
		||||
****************************************************************************}
 | 
			
		||||
@ -304,6 +308,11 @@ implementation
 | 
			
		||||
            defref:=tref.create(defref,@akttokenpos);
 | 
			
		||||
            inc(refcount);
 | 
			
		||||
          end;
 | 
			
		||||
         lastref:=defref;
 | 
			
		||||
{$ifdef GDB}
 | 
			
		||||
         isstabwritten := false;
 | 
			
		||||
{$endif GDB}
 | 
			
		||||
         symoptions:=current_object_option;
 | 
			
		||||
      end;
 | 
			
		||||
 | 
			
		||||
    constructor tsym.loadsym(ppufile:tcompilerppufile);
 | 
			
		||||
@ -328,6 +337,9 @@ implementation
 | 
			
		||||
         refs:=0;
 | 
			
		||||
         lastwritten:=nil;
 | 
			
		||||
         refcount:=0;
 | 
			
		||||
{$ifdef GDB}
 | 
			
		||||
         isstabwritten := false;
 | 
			
		||||
{$endif GDB}
 | 
			
		||||
      end;
 | 
			
		||||
 | 
			
		||||
    destructor tsym.destroy;
 | 
			
		||||
@ -1528,7 +1540,10 @@ finalization
 | 
			
		||||
end.
 | 
			
		||||
{
 | 
			
		||||
  $Log$
 | 
			
		||||
  Revision 1.37  2004-01-31 21:09:58  daniel
 | 
			
		||||
  Revision 1.38  2004-01-31 22:48:31  daniel
 | 
			
		||||
    * Fix stabs generation problem reported by Jonas
 | 
			
		||||
 | 
			
		||||
  Revision 1.37  2004/01/31 21:09:58  daniel
 | 
			
		||||
    * Stabs lineinfo problem fixed
 | 
			
		||||
 | 
			
		||||
  Revision 1.36  2004/01/31 18:40:15  daniel
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user