Remove deprecated methods
This commit is contained in:
parent
e8d372d555
commit
cd1d9b9e3f
16
src/lib.rs
16
src/lib.rs
@ -1240,16 +1240,6 @@ impl<'conn> Transaction<'conn> {
|
||||
})
|
||||
}
|
||||
|
||||
#[deprecated = "call `lazy_query` on `Statement` instead"]
|
||||
#[allow(missing_docs)]
|
||||
pub fn lazy_query<'trans, 'stmt>(&'trans self,
|
||||
stmt: &'stmt Statement,
|
||||
params: &[&ToSql],
|
||||
row_limit: i32)
|
||||
-> Result<LazyRows<'trans, 'stmt>> {
|
||||
stmt.lazy_query(self, params, row_limit)
|
||||
}
|
||||
|
||||
/// Like `Connection::is_active`.
|
||||
pub fn is_active(&self) -> bool {
|
||||
self.conn.conn.borrow().trans_depth == self.depth
|
||||
@ -1591,12 +1581,6 @@ impl<'stmt> Rows<'stmt> {
|
||||
pub fn result_descriptions(&self) -> &'stmt [ResultDescription] {
|
||||
self.stmt.result_descriptions()
|
||||
}
|
||||
|
||||
#[deprecated = "now a no-op"]
|
||||
#[allow(missing_docs)]
|
||||
pub fn finish(self) -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
impl<'stmt> Iterator for Rows<'stmt> {
|
||||
|
@ -385,15 +385,6 @@ FROM (SELECT gs.i
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_result_finish() {
|
||||
let conn = or_panic!(Connection::connect("postgres://postgres@localhost", &SslMode::None));
|
||||
or_panic!(conn.execute("CREATE TEMPORARY TABLE foo (id BIGINT PRIMARY KEY)", &[]));
|
||||
let stmt = or_panic!(conn.prepare("SELECT * FROM foo"));
|
||||
let result = or_panic!(stmt.query(&[]));
|
||||
assert!(result.finish().is_ok());
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_lazy_query() {
|
||||
let conn = or_panic!(Connection::connect("postgres://postgres@localhost", &SslMode::None));
|
||||
|
Loading…
Reference in New Issue
Block a user