Should out/ref parameters require the caller to specify out/ref like in C#?

Nick Sabalausky (Abscissa) via Digitalmars-d digitalmars-d at puremagic.com
Sun May 28 22:39:41 PDT 2017


On 05/29/2017 12:57 AM, Ola Fosheim Grostad wrote:
> On Monday, 29 May 2017 at 01:56:19 UTC, Nick Sabalausky (Abscissa) wrote:
>> On 05/28/2017 03:06 PM, Meta wrote:
>>>
>>> If you didn't know that the function takes its parameters by ref or 
>>> out... You're should've RTFM.
>>
>> That's the same reasoning that's been used to excuse just about every 
>> API blunder in C's infamously unsafe bug-riddled history.
> 
> This is information that a good IDE could be designed to provide. To 
> require "ref" is rather pointless as it would make the feature 
> redundant, just use a pointer and "&" instead and argue in favour of 
> nonnullable static analysis...

Did you intend that as a response to my post or to the OP? Sounds more 
like it was directed at the OP.

The web interface really should add an extra "Reply" button way at the 
bottom that creates a reply to the OP (Or better yet, default to tree 
view.) I've noticed that the stupid default of "remove all threading 
information" combined with individual message replies creates a lot of 
confusion with cases where people try to reply to the OP, but wind up 
*actually* replying to whatever random leaf just happened the be the 
latest post (I also suspect the web interface's "remove threading" 
default is probably also the ultimate source of most of the animosity 
towards OT. Prentending that there's no threading in an inherently 
threaded newsgroup just begs for these sorts of problems)


More information about the Digitalmars-d mailing list