Bug 411741

Summary: g++ link errror with -frepo
Product: [Fedora] Fedora Reporter: Serge Pavlovsky <pal666>
Component: gccAssignee: Jakub Jelinek <jakub>
Status: CLOSED UPSTREAM QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 8   
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-12-06 12:56:53 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Serge Pavlovsky 2007-12-05 10:00:21 UTC
Description of problem:
link error with -frepo

Version-Release number of selected component (if applicable):
4.1.2 20070925 (Red Hat 4.1.2-33)

How reproducible:
[11:57:09 pal@localhost ~/tmp/1]$ cat a.cpp
template < class T > class A {
public:
        static const T a [ 1 ];
};

template < class T > const T A < T > :: a [ 1 ] = { 'a' };

int main ( ) {
        char a = A < char > :: a [ 0 ];
}
[11:58:20 pal@localhost ~/tmp/1]$ g++ -o a a.cpp
[11:58:27 pal@localhost ~/tmp/1]$ g++ -c a.cpp -frepo
[11:58:33 pal@localhost ~/tmp/1]$ LC_ALL=C g++ -o a a.o -frepo
a.o: In function `main':
a.cpp:(.text+0x7): undefined reference to `A<char>::a'
collect2: ld returned 1 exit status


Actual results:
no error without -frepo, error with - frepo

Expected results:
no errors in both cases

Comment 1 Jakub Jelinek 2007-12-06 12:56:53 UTC
This is already tracked upstream.