poohbar
10/22/2017, 1:25 AMFile(path).bufferedReader().lineSequence()
Now, lineSequence()
warns that I have to take care of closing the input stream but how would I go about doing that? E.g. how do I know the sequence has been exhausted and it's time to close the flie?
I can't use useLines()
in this case, because I am returning this sequence out of a function.