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 242977 - Viability of specialization parameters is not checked during template resolving
Summary: Viability of specialization parameters is not checked during template resolving
Status: NEW
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Completion (show other bugs)
Version: 8.0
Hardware: PC Linux
: P3 normal (vote)
Assignee: petrk
URL:
Keywords:
Depends on: 237140
Blocks:
  Show dependency tree
 
Reported: 2014-03-17 16:29 UTC by petrk
Modified: 2014-11-19 19:11 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 petrk 2014-03-17 16:29:20 UTC
struct my_iter {
    int foo();
};

struct container {
    typedef my_iter iterator;
};

template< typename T > struct exists { typedef void type; };

template< typename C, typename Enable = void> 
struct extract_iterator {
};

template< typename C > 
struct extract_iterator < C, typename exists<typename C::iterator>::type > {
    typedef typename C::iterator type;
};

int main() {   
    extract_iterator<container>::type var; // type is not resolved
    var.foo(); // foo is not resolved
    return 0;
}