tustvold commented on code in PR #3470:
URL: https://github.com/apache/arrow-rs/pull/3470#discussion_r1062944065


##########
arrow-csv/src/reader/records.rs:
##########
@@ -42,19 +42,21 @@ impl<R: BufRead> RecordReader<R> {
             reader,
             delimiter,
             num_columns,
-            num_rows: 0,
+            line_number: 1,
             offsets: vec![],
             data: vec![],
         }
     }
 
-    fn fill_buf(&mut self, to_read: usize) -> Result<(), ArrowError> {
+    /// Clears and then fills the buffers on this [`RecordReader`]
+    /// returning the number of records read
+    fn fill_buf(&mut self, to_read: usize) -> Result<usize, ArrowError> {

Review Comment:
   I reworked this to return the quantity read as I thought this made for a 
slightly clearer API



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to