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 213101 - enum based specializations are not resolved
Summary: enum based specializations are not resolved
Status: NEW
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Model (show other bugs)
Version: 7.2
Hardware: All All
: P3 normal (vote)
Assignee: petrk
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-28 14:13 UTC by Vladimir Voskresensky
Modified: 2016-10-31 10:09 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 Vladimir Voskresensky 2012-05-28 14:13:56 UTC
even when I turn on all deep template expression evaluations, specializations are not resolved:


enum E {
    VAL1,
    VAL11,
    VAL111,
    VAL1111,
    VAL11111
};

template<int V> struct A{
    
};

template<> struct A<VAL1> {
    void VAL1();
};

template<> struct A<VAL11> {
    void VAL11();
};

template<> struct A<VAL111> {
    void VAL111();
};

template<> struct A<VAL1111> {
    void VAL1111();
};

template<> struct A<VAL11111> {
    void VAL11111();
};

static const E val = VAL11111;

/*
 * 
 */
int main(int argc, char** argv) {
    A<val> var1;
    var1.VAL11111(); // unresolved
    A<4> var21;
    var21.VAL11111(); // unresolved
    return 0;
}

---------------
only resolved construction is (no any flags needed):
    A<VAL11111> var2;
    var2.VAL11111();
Comment 1 Vladimir Voskresensky 2012-05-28 14:14:11 UTC
I used:
-J-Dcnd.modelimpl.expression.evaluator.deep.variable.provider=true -J-Dcnd.modelimpl.expression.evaluator.recursive.calc=true -J-Dcnd.modelimpl.expression.evaluator.extra.spec.params.matching=true