🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gdb.bug
Article #8894

symbol read-in bug with 4.6 on decstation

#8894
From: Robert Andrew Ryan
Date: Thu, 16 Jul 1992 16:32
52 lines
1712 bytes
Consider the 4 files below:

(first one is empty)
a.h:

foo.c:
	main()
	{
	}

b.c:
	#include "a.h"
	blahe()
	{
	}
c.c:
	#include "a.h"
	ick()
	{
	}

Compile with:

cc -g -o f foo.c b.c c.c

./gdb ./f
GDB is free software and you are welcome to distribute copies of it
 under certain conditions; type "show copying" to see the conditions.
There is absolutely no warranty for GDB; type "show warranty" for details.
GDB 4.6, Copyright 1992 Free Software Foundation, Inc...

Undefined command: "include".  Try "help".

Reading symbols from ./f...done.

Setting up the environment for debugging gdb.
Function "fatal" not defined.
(gdb) break main
Reading in symbols for foo.c... and b.c...
stEnd with storage class 1 not handled...done.
Breakpoint 1 at 0x400190: file foo.c, line 4.
(gdb)

The symbols for the source file b.c are read in because apparent gdb
thinks foo.c depends on information in b.c.

Cleary this is ludicrous.  It is interesting to note that if you
transpose b.c and c.c on the compile line then c.c fill be read in after
foo.c (instead of b.c as shown above.)


-Rob Ryan
Technical Details
Message-ID: <geNVIBW00asVApqUJe@andrew.cmu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!andrew.cmu.edu!rr2b+

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f5053,83190b7ce60e11cd,start
X-Google-Attributes: gidf5053,public
X-Google-ArrivalTime: 1992-07-16 13:39:28 PST
Newsgroups: gnu.gdb.bug
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!andrew.cmu.edu!rr2b+
From: rr2b+@andrew.cmu.edu (Robert Andrew Ryan)
Subject: symbol  read-in bug with 4.6 on decstation
Message-ID: <geNVIBW00asVApqUJe@andrew.cmu.edu>
Sender: gnulists@ai.mit.edu
Organization: GNUs Not Usenet
Distribution: gnu
Date: Thu, 16 Jul 1992 16:32:13 GMT
Approved: bug-gdb@prep.ai.mit.edu
Lines: 56