[Ironruby-core] IronRuby idiom for using (IDisposable) ?

Ivan Porto Carrero ivan at whiterabbitconsulting.eu
Mon Feb 1 04:35:08 EST 2010


it's not a rubyism as such, so I don't think it actually belongs in the
core. But opinions may vary
---
Met vriendelijke groeten - Best regards - Salutations
Ivan Porto Carrero
Blog: http://flanders.co.nz
Twitter: http://twitter.com/casualjim
Author of IronRuby in Action (http://manning.com/carrero)



On Mon, Feb 1, 2010 at 10:21 AM, Thibaut Barrère
<thibaut.barrere at gmail.com>wrote:

> Thanks Ivan,
>
> I like your version :)
>
> Will something similar be added directly into IronRuby Kernel ?
>
> -- Thibaut
>
> On Mon, Feb 1, 2010 at 10:07 AM, Ivan Porto Carrero <
> ivan at whiterabbitconsulting.eu> wrote:
>
>> yes
>>
>>
>> http://github.com/casualjim/ironnails/blob/master/IronNails/vendor/iron_nails/lib/core_ext/kernel.rb#L17
>> ---
>> Met vriendelijke groeten - Best regards - Salutations
>> Ivan Porto Carrero
>> Blog: http://flanders.co.nz
>> Twitter: http://twitter.com/casualjim
>> Author of IronRuby in Action (http://manning.com/carrero)
>>
>>
>>
>> On Mon, Feb 1, 2010 at 10:03 AM, Thibaut Barrère <
>> thibaut.barrere at gmail.com> wrote:
>>
>>> Hello,
>>>
>>> Is there a built-in way to achieve what C# 'using' does, with IronRuby ?
>>>
>>> Although it's pretty easy to roll your own (
>>> http://myotherpants.com/2009/09/disposable-code), I'd like to use the
>>> built-in way if there's one.
>>>
>>> thanks!
>>>
>>> -- Thibaut
>>>
>>> _______________________________________________
>>> Ironruby-core mailing list
>>> Ironruby-core at rubyforge.org
>>> http://rubyforge.org/mailman/listinfo/ironruby-core
>>>
>>>
>>
>> _______________________________________________
>> Ironruby-core mailing list
>> Ironruby-core at rubyforge.org
>> http://rubyforge.org/mailman/listinfo/ironruby-core
>>
>>
>
> _______________________________________________
> Ironruby-core mailing list
> Ironruby-core at rubyforge.org
> http://rubyforge.org/mailman/listinfo/ironruby-core
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20100201/511c2eda/attachment.html>


More information about the Ironruby-core mailing list