This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 159054 - Unresolved id in case of reference to template as return type
Summary: Unresolved id in case of reference to template as return type
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Model (show other bugs)
Version: 6.x
Hardware: Sun All
: P3 blocker (vote)
Assignee: nnnnnk
URL:
Keywords:
: 151757 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-02-24 12:58 UTC by nnnnnk
Modified: 2009-03-07 09:48 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description nnnnnk 2009-02-24 12:58:14 UTC
Example:
template<typename T>
struct A {
    A<T>& foo();
};

template<typename T>
A<T>&
A<T>::foo() { // unresolved
    return *this;
}

int main() {
    A<int> a;
    a.foo();

    return 0;
}
Comment 1 nnnnnk 2009-02-27 18:04:22 UTC
There is the same situation with *:
template<typename T>
struct A {
    A<T>* foo();
};

template<typename T>
A<T>*
A<T>::foo() { // unresolved
    return *this;
}

int main() {
    A<int> a;
    a.foo();
    return 0;
}
Comment 3 nnnnnk 2009-03-06 13:09:35 UTC
fixed
Comment 4 nnnnnk 2009-03-06 13:13:51 UTC
*** Issue 151757 has been marked as a duplicate of this issue. ***
Comment 5 Quality Engineering 2009-03-07 09:48:23 UTC
Integrated into 'main-golden', will be available in build *200903070353* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/7a5114d0ab67
User: Nick N. Krasilnikov <nnnnnk@netbeans.org>
Log: test for IZ#159054 : Unresolved id in case of reference to template as return type