🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.g++.bug
Article #1250

(none)

#1250
From: Niu Duan
Date: Fri, 11 Dec 1992 15:54
43 lines
2011 bytes
Hi G++ folks,

I would like to report some problems I've encounted while running my g++ program.
I think there may be a bug within the compiler, because I could not find any 
explanation regrading the problem.

This is what happens:  I am trying to generate a tree structure.  Each tree node 
(of of class type GL_states) contains a set of pointers of child nodes and 
a pointer to it parent node.  The first generation of children are OK, while the 
second generation causes trouble.  While setting the my_dad pointer of a child,
the data contained in the parent node has also been changed.  The size of a tree
node is 32bytes, and the 1st and the 6th four bytes of the parent node are always
being effected.   

I was using the constructor function to set up the 'my_dad' pointer of each node.
I tryed to use an explicit member function to set the 'my_dad' value and got the
same error.  

The program environment:

	g++ version 2.3.2
	libg++ version 2.2
	gdb version 4.7
	sun sparc running sun OS 4.1

I am sending you with the next msg a uuencoded tar file which contains the
following files ( the file name after uudecode is bug_report.tar):

	emmn.h		- the header file
	emmlib.cc	- contains the member functions
	emmlibb.cc	- contains the member functions
	main.cc		- the main program
	Makefile	- makefile
	emm.def		- the 1st argument data file
	emmn.def	- the 2nd argument data file	
	bug.report	- output of gdb, where bugs are highlighted 
			- with '******....******'
	bug.msg		- this msg

If it was not a bug, I would appreciate if you could tell me what's wrong with
my program.  Thank you!

- Niu Duan
Technical Details
Message-ID: <92Dec11.205430est.36914@colossus.cs.psu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!cs.psu.edu!duan

Show Full Headers
Complete Article Headers
Newsgroups: gnu.g++.bug
Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!cs.psu.edu!duan
From: duan@cs.psu.edu (Niu Duan)
Subject: (none)
Message-ID: <92Dec11.205430est.36914@colossus.cs.psu.edu>
Sender: gnulists@ai.mit.edu
Organization: GNUs Not Usenet
Distribution: gnu
Date: Fri, 11 Dec 1992 15:54:26 GMT
Approved: bug-g++@prep.ai.mit.edu
Lines: 45