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.
I'm working on C++ numerical computing and need to use heavily templated libraries for performance. The problem is netbeans code parser fails to resolve some identifiers, mainly member function of templated objects. It can resolve the name of the templated objects but not the member functions. I have tested with Eigen and Blitz++. Eigen (http://eigen.tuxfamily.org/index.php?title=Main_Page) is a very small header-files-only library and the problem can be reproduced with a piece of simple code: (Identifier "Random" and "row" not resolved. I did order netbeans to reparse the project.) *****************************code**************************** #include <cstdlib> #include <iostream> #include <eigen3/Eigen/Dense> //need Eigen head files using namespace std; using namespace Eigen; int main(int argc, char** argv) { MatrixXd mat(MatrixXd::Random(4, 4)); //Unable to resolve identifier Random cout << mat.row(2) << endl; //Unable to resolve identifier row return EXIT_SUCCESS; } *****************************code*************************** Note not all templated object will suffer from this problem. For instance, STL vector work without such problem. Probably because STL objects are not so heavily templated as high performance numerical libraries like Eigen and Blitz. I also tested with other IDEs on linux. Eclipse+CDT worked perfectly while Kdevelop behaved similarly to Netbeans.
Sorry I forgot to say the code can be compiled and executed without problem (tested with g++ and Intel icpc). So the Eigen library and the simple code should be OK. Must be a parser problem.
Probably Eigen should be added to accuracy tests
Integrated into 'main-silver', will be available in build *201601280002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/9696cc42ffa8 User: Petr Kudryavtsev <petrk@netbeans.org> Log: Fixed #216095 - Not able to resolve some identifiers from heavily templated C++ libraries (transplanted from 79a64f33ed9dff4eb54d0c9105e164d2f392a3e5)
Fixed at enum: 305722:79a64f33ed9d
Verified in NetBeans 8.1 patch1