Article View: gnu.g++.bug
Article #2130g++ 1.36.1 bug+fix 01059001 - static operators get errors
From: rfg
Date: Fri, 05 Jan 1990 18:17
Date: Fri, 05 Jan 1990 18:17
32 lines
1292 bytes
1292 bytes
// In g++ 1.36.1, the following example gets errors like
// "wrong number of parameters to `operator XXX'". This appears to be
// happening for any operator which is declared static.
class mine {
public:
static int operator == (mine&);
static int operator [] (mine&);
static int operator ! ();
};
(Michael - please confirm the following fix.)
*** cplus-decl2.c- Sat Dec 30 11:41:33 1989
--- cplus-decl2.c Fri Jan 5 09:54:43 1990
***************
*** 921,926 ****
/* Now we know the number of parameters,
so build the real operator fnname. */
! name = build_operator_fnname (declarator, TYPE_ARG_TYPES (type),
! is_decl > 1);
}
else
--- 921,925 ----
/* Now we know the number of parameters,
so build the real operator fnname. */
! name = build_operator_fnname (declarator, TYPE_ARG_TYPES (type), 0);
}
else
Technical Details
Message-ID:
<9001051017.aa15104@ICS.UCI.EDU>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!tut.cis.ohio-state.edu!ICS.UCI.EDU!rfgShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!tut.cis.ohio-state.edu!ICS.UCI.EDU!rfg From: rfg@ICS.UCI.EDU Newsgroups: gnu.g++.bug Subject: g++ 1.36.1 bug+fix 01059001 - static operators get errors Message-ID: <9001051017.aa15104@ICS.UCI.EDU> Date: 5 Jan 90 18:17:19 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Lines: 32