public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: libstdc++/8550: undefined reference to fill and fill_n
@ 2002-11-19 18:08 Gabriel Dos Reis
0 siblings, 0 replies; 4+ messages in thread
From: Gabriel Dos Reis @ 2002-11-19 18:08 UTC (permalink / raw)
To: paolo; +Cc: gcc-prs
The following reply was made to PR libstdc++/8550; it has been noted by GNATS.
From: Gabriel Dos Reis <gdr@integrable-solutions.net>
To: "Brian T. N. Gunney" <gunney@tux75.llnl.gov>
Cc: gcc-gnats@gcc.gnu.org
Subject: Re: libstdc++/8550: undefined reference to fill and fill_n
Date: 12 Nov 2002 20:36:13 +0100
"Brian T. N. Gunney" <gunney@tux75.llnl.gov> writes:
| >State: open
| >Class: sw-bug
This is user confusion.
[...]
| The fill and fill_n functions are missing when compiled with -fno-implicit-template,
| leading to an error at link time.
Which matches the documented behaviour.
|
| This is similar to bug 8172, in which I reported a missing operator+ for strings.
| >How-To-Repeat:
|
| Program text:
| #include <algorithm>
| using namespace std;
| int main() {
| double x[10];
| fill_n( x, 10, 1.0 );
| fill( x, x+10, 2.0 );
| return 0;
| }
|
| Compile command:
| g++ -fno-implicit-templates nofill.cc
The above tells g++ not to implicitly instantiate the required
definitions. Which means you *ought* to manually provide them --
usually through explicit instantiation.
The simple way fo fix this is: don't do that.
-- Gaby
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: libstdc++/8550: undefined reference to fill and fill_n
@ 2002-11-19 18:12 gdr
0 siblings, 0 replies; 4+ messages in thread
From: gdr @ 2002-11-19 18:12 UTC (permalink / raw)
To: gcc-bugs, gcc-prs, gunney, paolo
Synopsis: undefined reference to fill and fill_n
State-Changed-From-To: analyzed->closed
State-Changed-By: gdr
State-Changed-When: Tue Nov 12 11:37:13 2002
State-Changed-Why:
User confusion.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8550
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: libstdc++/8550: undefined reference to fill and fill_n
@ 2002-11-19 18:04 paolo
0 siblings, 0 replies; 4+ messages in thread
From: paolo @ 2002-11-19 18:04 UTC (permalink / raw)
To: gcc-bugs, gcc-prs, gunney, nobody, paolo
Synopsis: undefined reference to fill and fill_n
Responsible-Changed-From-To: unassigned->paolo
Responsible-Changed-By: paolo
Responsible-Changed-When: Tue Nov 12 11:02:49 2002
Responsible-Changed-Why:
Working on a fix.
State-Changed-From-To: open->analyzed
State-Changed-By: paolo
State-Changed-When: Tue Nov 12 11:02:49 2002
State-Changed-Why:
Confirmed.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8550
^ permalink raw reply [flat|nested] 4+ messages in thread
* libstdc++/8550: undefined reference to fill and fill_n
@ 2002-11-19 18:03 Brian T. N. Gunney
0 siblings, 0 replies; 4+ messages in thread
From: Brian T. N. Gunney @ 2002-11-19 18:03 UTC (permalink / raw)
To: gcc-gnats
>Number: 8550
>Category: libstdc++
>Synopsis: undefined reference to fill and fill_n
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Nov 12 10:56:04 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: Brian T. N. Gunney
>Release: 3.2
>Organization:
Lawrence Livermore National Lab
>Environment:
System: Linux tux75.llnl.gov 2.4.9-31smp #1 SMP Tue Feb 26 06:55:00 EST 2002 i686 unknown
Architecture: i686
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
configured with: ../gcc-3.2/configure --prefix=/usr/apps/gcc/3.2
>Description:
The fill and fill_n functions are missing when compiled with -fno-implicit-template,
leading to an error at link time.
This is similar to bug 8172, in which I reported a missing operator+ for strings.
>How-To-Repeat:
Program text:
#include <algorithm>
using namespace std;
int main() {
double x[10];
fill_n( x, 10, 1.0 );
fill( x, x+10, 2.0 );
return 0;
}
Compile command:
g++ -fno-implicit-templates nofill.cc
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2002-11-12 19:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-11-19 18:08 libstdc++/8550: undefined reference to fill and fill_n Gabriel Dos Reis
-- strict thread matches above, loose matches on Subject: below --
2002-11-19 18:12 gdr
2002-11-19 18:04 paolo
2002-11-19 18:03 Brian T. N. Gunney
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).