Please help me understand this function signature: std.stdio.File.byLine

Scotpip geoff at variosoft.co.uk
Thu Jul 15 18:46:34 UTC 2021


On Thursday, 15 July 2021 at 18:36:30 UTC, Tejas wrote:
> Sorry I'm on mobile right now so can't help much, but if you're 
> a beginner, please read the book "programming in D" by Ali 
> Cehreli.
>
>
> http://ddili.org/ders/d.en/
>
> If you just want to learn about files for now, visit this link, 
> it contains a chapter of his book(regrettably it doesn't cover 
> your exact usecase but maybe ```readln``` might work out for 
> you)
>
> http://ddili.org/ders/d.en/files.html

Thanks - I'm aware of the book - it's what gave me the confidence 
to have a go at D - but as you say it doesn't cover this 
use-case. I also have the old Alexandrescu book but it doesn't 
cover this either.

I'm new to systems work, but I'm not new to programming - I wrote 
my first programme on punch cards... I must have learned a dozen 
languages over the years, but this signature is the most cryptic 
I've ever encountered. Maybe if you're a C++ maven it makes 
sense, but it's pretty opaque to anyone else. When the examples 
are thin it really does make it hard for people trying to work 
their way into the community. So specific help on the issue of 
understanding this signature and reading in a Windows text file 
would still be very much appreciated.


More information about the Digitalmars-d-learn mailing list