Bug 242887 - kdevelop4: Wrong default parameters shown.
Summary: kdevelop4: Wrong default parameters shown.
Status: RESOLVED FIXED
Alias: None
Product: kdevelop
Classification: Applications
Component: Language Support: CPP (old) (show other bugs)
Version: git master
Platform: openSUSE Linux
: NOR normal
Target Milestone: 4.0.1
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-26 17:58 UTC by Sascha Peilicke
Modified: 2012-12-22 22:19 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sascha Peilicke 2010-06-26 17:58:21 UTC
Version:           SVN (using Devel) 
OS:                Linux

When having defined a default parameter value of '0' for pointer types, KDevelop's editor pretends that the value is the NULL macro. The inspection popup also insists on it being the NULL macro, but in the source code file it is not. The file is not marked as changed by KDevelop, so I'd suspect it's a parser error.

As an example, the real code: void foo(bar *p = 0) {}
KDevelop shows the following: void foo(bar *p = NULL) {}

Reproducible: Always

Steps to Reproduce:
load a project that contains pointers initialized with '0'


Expected Results:  
The real default parameter should be shown.

Besides, NULL or `0` is a matter of style, KDevelop should neither assume nor enforce one or the other.