[spec] Document ref and out parameters#2452
Conversation
|
Thanks for your pull request and interest in making D better, @ntrel! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please see CONTRIBUTING.md for more information. If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment. Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. |
189e3bc to
cf396cc
Compare
spec/function.dd
Outdated
| Ignored for parameters with no references) | ||
| Ignored for parameters with no references. | ||
| Note: The `scope` attribute is currently only enforced by `dmd` | ||
| when the `-dip1000` switch is passed. |
There was a problem hiding this comment.
Since DIP 25 and DIP 1000 are experimental features (at least I think they are). I'd prefer if we had a separate document in the spec describing their semantics. Then when they are official, their documentation can be folded into the spec.
There was a problem hiding this comment.
-dip25 is already in the docs (I wrote it):
https://dlang.org/spec/function.html#return-ref-parameters
There was a problem hiding this comment.
Thanks. We're lucky to have it. But I think it should be moved until DIP 25 and 1000 are official.
|
Probably this just needs someone to do the |
|
|
|
I forgot about this, but the test error blocking this has long since gone away - which then revealed an actual error, now fixed. |
refexample from theoutexamples, and put it first.scopedescription.