[Issue 10372] New: Document NRVO is applied in simple cases
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Jun 16 01:41:04 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=10372
Summary: Document NRVO is applied in simple cases
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: spec
Severity: normal
Priority: P2
Component: websites
AssignedTo: nobody at puremagic.com
ReportedBy: verylonglogin.reg at gmail.com
Depends on: 10371
--- Comment #0 from Denis Shelomovskij <verylonglogin.reg at gmail.com> 2013-06-16 12:41:03 MSD ---
If documentation will guarantee NRVO is applied in simple cases (i.e. no copy
construction occurs) structs with disabled default construction will be able to
be returned from functions (currently it is not guaranteed to compile):
---
struct S
{ @disable this(this); }
S makeS()
{
S s = S();
return s;
}
void main()
{
S s = makeS();
}
---
Also Issue 10371 have to be fixed first.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list