At end of some cpp file (let it be myfoo.cpp) I have commented block (in the past I commented some old function) without empty new line at end of file. In header file I have some function with inline definition, so for example int myFun() { return 5; } I wanted move it into cpp file, so I put cursor inside curly brackets and invoked Ctrl+Alt+S - "Move into source". After I was switching to cpp code I noticed that definition of mentioned function has been put at end of commented block, so function remained commented. When I put new line at end of file all Expected result: Even if at end of cpp file there is commented block and missing empty end of line then definition of function should not be put inside commented block only outside this block. Should be added empty new line and there put definition.
replace: ("missing empty end of line" / "missing empty new line") replace: ("When I put new line at end of file all" / "When I put new line at end of cpp file all works fine."
In last version of KDevelop (5.3.0) I noticed that before inserted empty definition is put single closing curly bracket. It looks like this: } void myclass:myfoo( int param ) {} I don't know if this does matter, but body of function before (last in moment of insertion) looks like: void myclass::lastfoo( int param ) { int a; if (something) { if (anotherthing) do_something1(); } else { if (yetanotherthing) do_something2(); } }
Just update. Last issue I observed in file where at its end were present 2 new line characters
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version? If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Dear Bug Submitter, This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging If you have already provided the requested information, please mark the bug as REPORTED so that the KDE team knows that the bug is ready to be confirmed. Thank you for helping us make KDE software even better for everyone!
This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging Thank you for helping us make KDE software even better for everyone!