mirror of
https://github.com/isar/rusqlite.git
synced 2025-01-19 19:30:50 +08:00
Fix CSVTab::next method.
This commit is contained in:
parent
ed5637f513
commit
3fbeccdf55
@ -146,12 +146,19 @@ impl VTabCursor<CSVTab> for CSVTabCursor {
|
||||
self.next()
|
||||
}
|
||||
fn next(&mut self) -> Result<()> {
|
||||
{
|
||||
let vtab = self.vtab();
|
||||
if vtab.reader.done() {
|
||||
return Err(Error::ModuleError(format!("eof")));
|
||||
}
|
||||
unimplemented!();
|
||||
// self.row_number = self.row_number + 1;
|
||||
|
||||
vtab.cols.clear();
|
||||
while let Some(col) = vtab.reader.next_str().into_iter_result() {
|
||||
vtab.cols.push(String::from(try!(col)));
|
||||
}
|
||||
}
|
||||
|
||||
self.row_number = self.row_number + 1;
|
||||
Ok(())
|
||||
}
|
||||
fn eof(&self) -> bool {
|
||||
|
Loading…
x
Reference in New Issue
Block a user