🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #51990

template function bug in g++ 2.3.x ?

#51990
From: Oran Singer
Date: Sat, 06 Mar 1993 14:41
29 lines
1538 bytes
The following breaks during the assembler stage, with two labels named _f
existing (instead of _f_c and _f_i), under 2.3.x on sparc and iris4d binaries
(actually, the RTL already contains the bug). 2.1 had no problem with this.

template<class T>
inline void f(T a)		// T& etc. makes no difference
{
   cout << a;			// whatever...
}

int main()
{
    int i=9;
    char c=8;

    f(i);
    f(c);
}

Is there an easy workaround for this? The bug persists even if f() is declared
as a friend of a dummy template class.

		Oran

--
_______________________________________________________________________________
  Oran Singer / oran@math.tau.ac.il oran@taurus.bitnet / Computer Science Lab
    School of Mathematics and Computer Science, Tel Aviv University, Israel
Technical Details
Message-ID: <1993Mar6.144123.26815@aristo.tau.ac.il>
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!howland.reston.ans.net!usenet.ins.cwru.edu!neoucom.edu!news.ysu.edu!blekul11!frmop11.cnusc.fr!univ-lille1.fr!univ-lyon1.fr!scsing.switch.ch!aristo.tau.ac.il!oran

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,c9ac8172c1727d10,start
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1993-03-06 09:48:30 PST
Newsgroups: gnu.gcc.help
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!howland.reston.ans.net!usenet.ins.cwru.edu!neoucom.edu!news.ysu.edu!blekul11!frmop11.cnusc.fr!univ-lille1.fr!univ-lyon1.fr!scsing.switch.ch!aristo.tau.ac.il!oran
From: oran@math.tau.ac.il (Oran Singer)
Subject: template function bug in g++ 2.3.x ?
Message-ID: <1993Mar6.144123.26815@aristo.tau.ac.il>
Sender: usenet@aristo.tau.ac.il (USENET)
Organization: School of Math & CS - Tel Aviv University , Tel Aviv , ISRAEL.
X-Newsreader: Tin 1.1 PL5
Date: Sat, 6 Mar 1993 14:41:23 GMT
Lines: 29