digitalmars.D.learn - File IO: C# streams VS iterators?
- DDD (7/7) Nov 07 2013 I was watching a dconf talk about porting C# code to D. One thing
- Lionello Lunesu (11/18) Nov 07 2013 There are several ranges that can be used for file IO, for example
- Jacob Carlborg (6/10) Nov 07 2013 For that, there's Tango:
- Jacob Carlborg (5/12) Nov 07 2013 he must have said ranges. A range is like a pair of iterators. It's
Walter said he thinks iterators (unless I remember wrong) is superior. The speaker agreed but said it isn't a drop in replacement so that is an issue if you want to port. I haven't access file in D and i'm completely confused. What are iterators in regards to file IO?
Nov 07 2013
On 11/8/13, 8:57, DDD wrote:thinks iterators (unless I remember wrong) is superior. The speaker agreed but said it isn't a drop in replacement so that is an issue if you want to port. I haven't access file in D and i'm completely confused. What are iterators in regards to file IO?There are several ranges that can be used for file IO, for example such capability, which is why you have TextReader and TextWriter on top of streams, etc.. However, sometimes it's useful to have polymorphism for accessing would be pretty trivial to port the base classes to D and implement them using the D ranges. L.
Nov 07 2013
On 2013-11-08 04:22, Lionello Lunesu wrote:However, sometimes it's useful to have polymorphism for accessing would be pretty trivial to port the base classes to D and implement them using the D ranges.For that, there's Tango: https://github.com/SiegeLord/Tango-D2 http://www.dsource.org/projects/tango/docs/current/ -- /Jacob Carlborg
Nov 07 2013
On 2013-11-08 01:57, DDD wrote:thinks iterators (unless I remember wrong) is superior. The speaker agreed but said it isn't a drop in replacement so that is an issue if you want to port. I haven't access file in D and i'm completely confused. What are iterators in regards to file IO?he must have said ranges. A range is like a pair of iterators. It's heavily used in D. -- /Jacob Carlborg
Nov 07 2013