Bug 335612

Summary: Wrong formating c++11 rvalue references
Product: [Applications] kdevelop Reporter: Marcin <ms27>
Component: AstyleAssignee: kdevelop-bugs-null
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version First Reported In: git master   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Marcin 2014-05-30 21:26:25 UTC
Kdevelop makes reformat source:
   void func(std::string&& str);
on:
  void func(std::string && str);
although pointer aligment is set on 'type'.

Reproducible: Always
Comment 1 Andrew Crouthamel 2018-11-11 04:29:42 UTC
Dear Bug Submitter,

This bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? I am setting the status to NEEDSINFO pending your response, please change the Status back to REPORTED when you respond.

Thank you for helping us make KDE software even better for everyone!
Comment 2 Marcin 2018-11-11 09:45:59 UTC
After test on version 5.2.4 these are my observations:

version:
    void func(std::string&& str);
hasn't change like last time, but...

version:
    void func(std::string && str);
doesn't work (the operator && is still between type and variable).

After change (only for test) pointer aligment to 'name' (variable), it doesn't change its position (version #2 in this comment).
The standard pointer/reference operator work correctly.
Comment 3 Justin Zobel 2022-12-03 09:01:41 UTC
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!