Skip to content

Commit b22b94c

Browse files
committed
Migrate to 2018 edition
1 parent 8fe0923 commit b22b94c

File tree

4 files changed

+10
-11
lines changed

4 files changed

+10
-11
lines changed

.circleci/config.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ save_registry: &SAVE_REGISTRY
99
- /usr/local/cargo/registry/index
1010

1111
deps_key: &DEPS_KEY
12-
key: deps-1.19.0-{{ checksum "Cargo.lock" }}-2
12+
key: deps-1.31.0-{{ checksum "Cargo.lock" }}-2
1313

1414
restore_deps: &RESTORE_DEPS
1515
restore_cache:
@@ -25,9 +25,8 @@ save_deps: &SAVE_DEPS
2525
version: 2
2626
jobs:
2727
build:
28-
working_directory: ~/build
2928
docker:
30-
- image: rust:1.19.0
29+
- image: rust:1.31.0
3130
- image: postgres:10.0
3231
environment:
3332
POSTGRES_PASSWORD: password

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
name = "r2d2_postgres"
33
version = "0.14.0"
44
authors = ["Steven Fackler <sfackler@gmail.com>"]
5+
edition = "2018"
56
license = "MIT"
67
description = "Postgres support for the r2d2 connection pool"
78
repository = "https://github.com/sfackler/r2d2-postgres"

src/lib.rs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
//! Postgres support for the `r2d2` connection pool.
22
#![doc(html_root_url="https://docs.rs/r2d2_postgres/0.14")]
33
#![warn(missing_docs)]
4-
pub extern crate r2d2;
5-
pub extern crate postgres;
6-
extern crate postgres_shared;
4+
pub use r2d2;
5+
pub use postgres;
76

87
use postgres::{Connection, Error, Result};
98
use postgres::params::{ConnectParams, IntoConnectParams};
@@ -15,9 +14,9 @@ pub enum TlsMode {
1514
/// Like `postgres::TlsMode::None`.
1615
None,
1716
/// Like `postgres::TlsMode::Prefer`.
18-
Prefer(Box<TlsHandshake + Sync + Send>),
17+
Prefer(Box<dyn TlsHandshake + Sync + Send>),
1918
/// Like `postgres::TlsMode::Require`.
20-
Require(Box<TlsHandshake + Sync + Send>),
19+
Require(Box<dyn TlsHandshake + Sync + Send>),
2120
}
2221

2322
/// An `r2d2::ManageConnection` for `postgres::Connection`s.

tests/test.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
extern crate postgres;
2-
extern crate r2d2;
3-
extern crate r2d2_postgres;
1+
2+
use r2d2;
3+
44

55
use std::sync::mpsc;
66
use std::thread;

0 commit comments

Comments
 (0)