| Summary: | Representation for template classes is incorrect in class view browser | ||
|---|---|---|---|
| Product: | [Applications] kdevelop | Reporter: | Unknown <null> |
| Component: | Language Support: CPP (old) | Assignee: | KDevelop-Devel List <kdevelop-devel> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | esigra |
| Priority: | NOR | ||
| Version First Reported In: | 2.1-beta | ||
| Target Milestone: | --- | ||
| Platform: | Mandrake RPMs | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
Tested with following valid C++ code:
template <class Key, class Value> class FooBase
{
public:
FooBase() {}
};
class Foo : public FooBase<long, int *>
{
public:
Foo() {}
};
Class parser successful in extracting declarations, however in the class view there is
lacking information: there is not the slightest indication of these being template classes.
Suggestion: Output parsed template parameters (it shouldn't be cut'n paste of text from
the declaration). Roberto, we parse the template <....> as in the standard right? If it gets
all typenames correctly, we can easily construct the correct template specification
string.
What I mean here is those template specs should be right ;) For such code as template < std::map < int, pair< QString, QString > >, Tree < double > > StrangeStructure; As seen this is not so easy as it seems. Which Tree that is it should know... It should also be possible navigate directly to say "Tree", or "std::map" templates..... Figure this :) I think a good code to test out whether the template stuff works is blitz++ library. It uses a lot of template expressions. The best acid test for template parsing would probably be a selection from the Boost libraries, for instance Boost.Python and Boost.MPL. Blitz++ is outdated (allthough some people are currently breathing new life into it), and certainly does not contain the latest and greates in horrorshow template syntax. Replaced s_shalnov@hotmail.com with null@kde.org due to bounces by reporter KDevelop3.4 shows the full class declaration as tooltip information, so this is available in the class view. Moving all the bugs from the CPP Parser. It was not well defined the difference between it and C++ Language Support and people kept reporting in both places indistinctively |
(*** This bug was imported into bugs.kde.org ***) Package: kdevelop Version: 2.1beta (using KDE 2.2.2 ) Severity: normal Installed from: Mandrake RPMs Compiler: gcc-2.96 OS: Linux OS/Compiler notes: Not Specified Try to view in classview broser the following class structire: class Foo : public BalancedFoo<long const MyName *> { }; Where balancedFoo is: template <class Key class Value> class BalancedFoo; Two argument for template class is very important for repracentation the bug. So you can see incorrect representation these class structure in graphical class view breoser. (Submitted via bugs.kde.org) (Called from KBugReport dialog. Fields Application KDE Version OS Compiler manually changed)