Proposal: Object/?? Destruction

SrMordred patric.dexheimer at gmail.com
Wed Oct 4 10:43:49 UTC 2017


On Wednesday, 4 October 2017 at 10:03:56 UTC, aberba wrote:
>  Upon reading this, It triggered an idea.
>>
>> On Saturday, 30 September 2017 at 16:10:44 UTC, Jonathan 
>> Marler wrote:
>>> [...]
>
> DIP reminds me of object destruction.
>
> /* extracts success & message from returned type. Could be 
> tuple or structure, etc. May even eliminate use of tuples for 
> multiple return
> */
>
> auto {success, message} = callVoldermortFunction();
>
>  This is concept is used in Kotlin. JavaScript es6 takes it 
> even further (function parameters and arguments support object 
> destruction)

+1


More information about the Digitalmars-d mailing list