This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/11797] Change in inlining behavior vs. previous versions


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11797



------- Additional Comments From mruff at chiaro dot com  2003-08-05 00:20 -------
Subject: RE:  Change in inlining behavior vs. previous versions

I should have mentioned that I tried static, but...

static svector<string>::svector<string>(unsigned size)
: nitems_(size), items_(new string[size])
{
}

produces...

GCC:3.2.2

In file included from PTask.h:26,
                 from PTask.cc:25:
svector.h:105: cannot declare member function `svector<TYPE>::svector(unsigned
   int) [with TYPE = std::string]' to have static linkage

GCC3.3:

In file included from PTask.h:26,
                 from PTask.cc:25:
svector.h:105: error: cannot declare member function `
   svector<TYPE>::svector(unsigned int) [with TYPE = std::string]' to have
   static linkage

I know this is not the place to learn C++, but :-) how would one
declare the member function to be out of line but with file scope?

> -----Original Message-----
> From: pinskia at physics dot uc dot edu
> [mailto:gcc-bugzilla@gcc.gnu.org]
> Sent: Monday, August 04, 2003 6:47 PM
> To: Michael Ruff
> Subject: [Bug c++/11797] Change in inlining behavior vs. previous
> versions
> 
> 
> PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* 
> gcc-bugs@gcc.gnu.org.
> 
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11797
> 
> 
> pinskia at physics dot uc dot edu changed:
> 
>            What    |Removed                     |Added
> --------------------------------------------------------------
> --------------
>              Status|UNCONFIRMED                 |RESOLVED
>          Resolution|                            |INVALID
> 
> 
> ------- Additional Comments From pinskia at physics dot uc 
> dot edu  2003-08-04 23:46 -------
> The code is invalid as it  declears 
> svector<string>::svector<string>(unsigned size) as 
> extern add static or inline in front of it.
> 
> 
> 
> ------- You are receiving this mail because: -------
> You reported the bug, or are watching the reporter.
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]