Skip to content

Commit 95d2e04

Browse files
committed
Update compile tests
1 parent cfb9506 commit 95d2e04

80 files changed

Lines changed: 256 additions & 256 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

diesel/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ num-traits = { version = "0.2.0", optional = true }
3030
num-integer = { version = "0.1.39", optional = true }
3131
bigdecimal = { version = ">=0.0.13, < 0.3.0", optional = true }
3232
bitflags = { version = "1.2.0", optional = true }
33-
r2d2 = { version = ">= 0.8.0, < 0.9.0", optional = true }
33+
r2d2 = { version = ">= 0.8.2, < 0.9.0", optional = true }
3434
itoa = "0.4.0"
3535

3636
[dependencies.diesel_derives]

diesel_compile_tests/tests/fail/any_is_only_selectable_if_inner_expr_is_selectable.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ struct Stuff {
2525
fn main() {
2626
use self::stuff::dsl::*;
2727

28-
let conn = PgConnection::establish("").unwrap();
28+
let mut conn = PgConnection::establish("").unwrap();
2929

3030
let _ = stuff.filter(name.eq(any(more_stuff::names)))
31-
.load(&conn);
31+
.load(&mut conn);
3232
}

diesel_compile_tests/tests/fail/any_is_only_selectable_if_inner_expr_is_selectable.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
error[E0277]: the trait bound `stuff::table: AppearsInFromClause<more_stuff::table>` is not satisfied
22
--> $DIR/any_is_only_selectable_if_inner_expr_is_selectable.rs:31:10
33
|
4-
31 | .load(&conn);
4+
31 | .load(&mut conn);
55
| ^^^^ the trait `AppearsInFromClause<more_stuff::table>` is not implemented for `stuff::table`
66
|
77
= help: the following implementations were found:

diesel_compile_tests/tests/fail/array_expressions_must_be_correct_type.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ use diesel::dsl::*;
44
use diesel::*;
55

66
fn main() {
7-
let connection = PgConnection::establish("").unwrap();
8-
select(array((1, 3))).get_result::<Vec<i32>>(&connection);
9-
select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
10-
select(array((1f64, 3f64))).get_result::<Vec<f64>>(&connection);
7+
let mut connection = PgConnection::establish("").unwrap();
8+
select(array((1, 3))).get_result::<Vec<i32>>(&mut connection);
9+
select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
10+
select(array((1f64, 3f64))).get_result::<Vec<f64>>(&mut connection);
1111
}

diesel_compile_tests/tests/fail/array_expressions_must_be_correct_type.stderr

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
22
--> $DIR/array_expressions_must_be_correct_type.rs:9:5
33
|
4-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
4+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
55
| ^^^^^^ the trait `SelectableExpression<()>` is not implemented for `f64`
66
|
77
::: $DIESEL/src/query_builder/functions.rs
@@ -17,7 +17,7 @@ error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
1717
error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
1818
--> $DIR/array_expressions_must_be_correct_type.rs:9:5
1919
|
20-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
20+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
2121
| ^^^^^^ the trait `ValidGrouping<()>` is not implemented for `f64`
2222
|
2323
::: $DIESEL/src/query_builder/functions.rs
@@ -33,7 +33,7 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
3333
error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
3434
--> $DIR/array_expressions_must_be_correct_type.rs:9:33
3535
|
36-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
36+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
3737
| ^^^^^^^^^^ the trait `SelectableExpression<()>` is not implemented for `f64`
3838
|
3939
= note: required because of the requirements on the impl of `SelectableExpression<()>` for `(f64, f64)`
@@ -46,7 +46,7 @@ error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
4646
error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
4747
--> $DIR/array_expressions_must_be_correct_type.rs:9:33
4848
|
49-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
49+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
5050
| ^^^^^^^^^^ the trait `ValidGrouping<()>` is not implemented for `f64`
5151
|
5252
= note: required because of the requirements on the impl of `ValidGrouping<()>` for `(f64, f64)`
@@ -58,7 +58,7 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
5858
error[E0277]: the trait bound `f64: QueryId` is not satisfied
5959
--> $DIR/array_expressions_must_be_correct_type.rs:9:33
6060
|
61-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
61+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
6262
| ^^^^^^^^^^ the trait `QueryId` is not implemented for `f64`
6363
|
6464
= note: required because of the requirements on the impl of `QueryId` for `(f64, f64)`
@@ -69,7 +69,7 @@ error[E0277]: the trait bound `f64: QueryId` is not satisfied
6969
error[E0277]: the trait bound `f64: QueryFragment<_>` is not satisfied
7070
--> $DIR/array_expressions_must_be_correct_type.rs:9:33
7171
|
72-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
72+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
7373
| ^^^^^^^^^^ the trait `QueryFragment<_>` is not implemented for `f64`
7474
|
7575
= note: required because of the requirements on the impl of `QueryFragment<_>` for `(f64, f64)`
@@ -83,7 +83,7 @@ error[E0277]: the trait bound `f64: QueryFragment<_>` is not satisfied
8383
error[E0277]: the trait bound `f64: diesel::Expression` is not satisfied
8484
--> $DIR/array_expressions_must_be_correct_type.rs:9:12
8585
|
86-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
86+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
8787
| ^^^^^ the trait `diesel::Expression` is not implemented for `f64`
8888
|
8989
::: $DIESEL/src/pg/expression/array.rs
@@ -97,7 +97,7 @@ error[E0277]: the trait bound `f64: diesel::Expression` is not satisfied
9797
error[E0277]: the trait bound `SelectStatement<()>: SelectDsl<diesel::pg::expression::array::ArrayLiteral<(f64, f64), diesel::sql_types::Integer>>` is not satisfied
9898
--> $DIR/array_expressions_must_be_correct_type.rs:9:5
9999
|
100-
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&connection);
100+
9 | select(array((1f64, 3f64))).get_result::<Vec<i32>>(&mut connection);
101101
| ^^^^^^ the trait `SelectDsl<diesel::pg::expression::array::ArrayLiteral<(f64, f64), diesel::sql_types::Integer>>` is not implemented for `SelectStatement<()>`
102102
|
103103
= help: the following implementations were found:

diesel_compile_tests/tests/fail/array_expressions_must_be_same_type.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ use diesel::*;
44
use diesel::dsl::*;
55

66
fn main() {
7-
let connection = PgConnection::establish("").unwrap();
8-
select(array((1, 3))).get_result::<Vec<i32>>(&connection).unwrap();
9-
select(array((1f64, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
7+
let mut connection = PgConnection::establish("").unwrap();
8+
select(array((1, 3))).get_result::<Vec<i32>>(&mut connection).unwrap();
9+
select(array((1f64, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
1010

11-
select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
12-
select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
11+
select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
12+
select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
1313
}

diesel_compile_tests/tests/fail/array_expressions_must_be_same_type.stderr

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
22
--> $DIR/array_expressions_must_be_same_type.rs:11:5
33
|
4-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
4+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
55
| ^^^^^^ the trait `SelectableExpression<()>` is not implemented for `f64`
66
|
77
::: $DIESEL/src/query_builder/functions.rs
@@ -17,7 +17,7 @@ error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
1717
error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
1818
--> $DIR/array_expressions_must_be_same_type.rs:11:5
1919
|
20-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
20+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
2121
| ^^^^^^ the trait `ValidGrouping<()>` is not implemented for `f64`
2222
|
2323
::: $DIESEL/src/query_builder/functions.rs
@@ -33,7 +33,7 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
3333
error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
3434
--> $DIR/array_expressions_must_be_same_type.rs:11:30
3535
|
36-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
36+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
3737
| ^^^^^^^^^^ the trait `SelectableExpression<()>` is not implemented for `f64`
3838
|
3939
= note: required because of the requirements on the impl of `SelectableExpression<()>` for `(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>, f64)`
@@ -46,7 +46,7 @@ error[E0277]: the trait bound `f64: SelectableExpression<()>` is not satisfied
4646
error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
4747
--> $DIR/array_expressions_must_be_same_type.rs:11:30
4848
|
49-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
49+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
5050
| ^^^^^^^^^^ the trait `ValidGrouping<()>` is not implemented for `f64`
5151
|
5252
= note: required because of the requirements on the impl of `ValidGrouping<()>` for `(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>, f64)`
@@ -58,7 +58,7 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied
5858
error[E0277]: the trait bound `f64: QueryId` is not satisfied
5959
--> $DIR/array_expressions_must_be_same_type.rs:11:30
6060
|
61-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
61+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
6262
| ^^^^^^^^^^ the trait `QueryId` is not implemented for `f64`
6363
|
6464
= note: required because of the requirements on the impl of `QueryId` for `(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>, f64)`
@@ -69,7 +69,7 @@ error[E0277]: the trait bound `f64: QueryId` is not satisfied
6969
error[E0277]: the trait bound `f64: QueryFragment<_>` is not satisfied
7070
--> $DIR/array_expressions_must_be_same_type.rs:11:30
7171
|
72-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
72+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
7373
| ^^^^^^^^^^ the trait `QueryFragment<_>` is not implemented for `f64`
7474
|
7575
= note: required because of the requirements on the impl of `QueryFragment<_>` for `(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>, f64)`
@@ -83,7 +83,7 @@ error[E0277]: the trait bound `f64: QueryFragment<_>` is not satisfied
8383
error[E0277]: the trait bound `f64: diesel::Expression` is not satisfied
8484
--> $DIR/array_expressions_must_be_same_type.rs:11:12
8585
|
86-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
86+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
8787
| ^^^^^ the trait `diesel::Expression` is not implemented for `f64`
8888
|
8989
::: $DIESEL/src/pg/expression/array.rs
@@ -97,7 +97,7 @@ error[E0277]: the trait bound `f64: diesel::Expression` is not satisfied
9797
error[E0277]: the trait bound `{integer}: SelectableExpression<()>` is not satisfied
9898
--> $DIR/array_expressions_must_be_same_type.rs:12:5
9999
|
100-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
100+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
101101
| ^^^^^^ the trait `SelectableExpression<()>` is not implemented for `{integer}`
102102
|
103103
::: $DIESEL/src/query_builder/functions.rs
@@ -119,7 +119,7 @@ error[E0277]: the trait bound `{integer}: SelectableExpression<()>` is not satis
119119
error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied
120120
--> $DIR/array_expressions_must_be_same_type.rs:12:5
121121
|
122-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
122+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
123123
| ^^^^^^ the trait `ValidGrouping<()>` is not implemented for `{integer}`
124124
|
125125
::: $DIESEL/src/query_builder/functions.rs
@@ -141,7 +141,7 @@ error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied
141141
error[E0277]: the trait bound `{integer}: SelectableExpression<()>` is not satisfied
142142
--> $DIR/array_expressions_must_be_same_type.rs:12:30
143143
|
144-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
144+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
145145
| ^^^^^^^^^^ the trait `SelectableExpression<()>` is not implemented for `{integer}`
146146
|
147147
= help: the following implementations were found:
@@ -160,7 +160,7 @@ error[E0277]: the trait bound `{integer}: SelectableExpression<()>` is not satis
160160
error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied
161161
--> $DIR/array_expressions_must_be_same_type.rs:12:30
162162
|
163-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
163+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
164164
| ^^^^^^^^^^ the trait `ValidGrouping<()>` is not implemented for `{integer}`
165165
|
166166
= help: the following implementations were found:
@@ -178,7 +178,7 @@ error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied
178178
error[E0277]: the trait bound `{integer}: QueryId` is not satisfied
179179
--> $DIR/array_expressions_must_be_same_type.rs:12:30
180180
|
181-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
181+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
182182
| ^^^^^^^^^^ the trait `QueryId` is not implemented for `{integer}`
183183
|
184184
= help: the following implementations were found:
@@ -195,7 +195,7 @@ error[E0277]: the trait bound `{integer}: QueryId` is not satisfied
195195
error[E0277]: the trait bound `{integer}: QueryFragment<_>` is not satisfied
196196
--> $DIR/array_expressions_must_be_same_type.rs:12:30
197197
|
198-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
198+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
199199
| ^^^^^^^^^^ the trait `QueryFragment<_>` is not implemented for `{integer}`
200200
|
201201
= help: the following implementations were found:
@@ -215,7 +215,7 @@ error[E0277]: the trait bound `{integer}: QueryFragment<_>` is not satisfied
215215
error[E0277]: the trait bound `{integer}: diesel::Expression` is not satisfied
216216
--> $DIR/array_expressions_must_be_same_type.rs:12:12
217217
|
218-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
218+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
219219
| ^^^^^ the trait `diesel::Expression` is not implemented for `{integer}`
220220
|
221221
::: $DIESEL/src/pg/expression/array.rs
@@ -235,7 +235,7 @@ error[E0277]: the trait bound `{integer}: diesel::Expression` is not satisfied
235235
error[E0277]: the trait bound `SelectStatement<()>: SelectDsl<diesel::pg::expression::array::ArrayLiteral<(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>, f64), diesel::sql_types::Integer>>` is not satisfied
236236
--> $DIR/array_expressions_must_be_same_type.rs:11:5
237237
|
238-
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&connection).unwrap();
238+
11 | select(array((1, 3f64))).get_result::<Vec<i32>>(&mut connection).unwrap();
239239
| ^^^^^^ the trait `SelectDsl<diesel::pg::expression::array::ArrayLiteral<(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>, f64), diesel::sql_types::Integer>>` is not implemented for `SelectStatement<()>`
240240
|
241241
= help: the following implementations were found:
@@ -244,7 +244,7 @@ error[E0277]: the trait bound `SelectStatement<()>: SelectDsl<diesel::pg::expres
244244
error[E0277]: the trait bound `SelectStatement<()>: SelectDsl<diesel::pg::expression::array::ArrayLiteral<({integer}, diesel::expression::bound::Bound<diesel::sql_types::Double, f64>), diesel::sql_types::Double>>` is not satisfied
245245
--> $DIR/array_expressions_must_be_same_type.rs:12:5
246246
|
247-
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&connection).unwrap();
247+
12 | select(array((1, 3f64))).get_result::<Vec<f64>>(&mut connection).unwrap();
248248
| ^^^^^^ the trait `SelectDsl<diesel::pg::expression::array::ArrayLiteral<({integer}, diesel::expression::bound::Bound<diesel::sql_types::Double, f64>), diesel::sql_types::Double>>` is not implemented for `SelectStatement<()>`
249249
|
250250
= help: the following implementations were found:

diesel_compile_tests/tests/fail/array_only_usable_with_pg.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ use diesel::dsl::*;
44
use diesel::*;
55

66
fn main() {
7-
let connection = SqliteConnection::establish("").unwrap();
8-
select(array((1,))).get_result::<Vec<i32>>(&connection);
7+
let mut connection = SqliteConnection::establish("").unwrap();
8+
select(array((1,))).get_result::<Vec<i32>>(&mut connection);
99

10-
let connection = MysqlConnection::establish("").unwrap();
11-
select(array((1,))).get_result::<Vec<i32>>(&connection);
10+
let mut connection = MysqlConnection::establish("").unwrap();
11+
select(array((1,))).get_result::<Vec<i32>>(&mut connection);
1212
}

diesel_compile_tests/tests/fail/array_only_usable_with_pg.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
error[E0271]: type mismatch resolving `<diesel::SqliteConnection as diesel::Connection>::Backend == Pg`
22
--> $DIR/array_only_usable_with_pg.rs:8:25
33
|
4-
8 | select(array((1,))).get_result::<Vec<i32>>(&connection);
4+
8 | select(array((1,))).get_result::<Vec<i32>>(&mut connection);
55
| ^^^^^^^^^^ expected struct `Sqlite`, found struct `Pg`
66
|
77
= note: required because of the requirements on the impl of `LoadQuery<diesel::SqliteConnection, Vec<i32>>` for `SelectStatement<(), diesel::query_builder::select_clause::SelectClause<diesel::pg::expression::array::ArrayLiteral<(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>,), diesel::sql_types::Integer>>>`
88

99
error[E0277]: the trait bound `Sqlite: HasSqlType<Array<diesel::sql_types::Integer>>` is not satisfied
1010
--> $DIR/array_only_usable_with_pg.rs:8:25
1111
|
12-
8 | select(array((1,))).get_result::<Vec<i32>>(&connection);
12+
8 | select(array((1,))).get_result::<Vec<i32>>(&mut connection);
1313
| ^^^^^^^^^^ the trait `HasSqlType<Array<diesel::sql_types::Integer>>` is not implemented for `Sqlite`
1414
|
1515
= help: the following implementations were found:
@@ -24,15 +24,15 @@ error[E0277]: the trait bound `Sqlite: HasSqlType<Array<diesel::sql_types::Integ
2424
error[E0271]: type mismatch resolving `<diesel::MysqlConnection as diesel::Connection>::Backend == Pg`
2525
--> $DIR/array_only_usable_with_pg.rs:11:25
2626
|
27-
11 | select(array((1,))).get_result::<Vec<i32>>(&connection);
27+
11 | select(array((1,))).get_result::<Vec<i32>>(&mut connection);
2828
| ^^^^^^^^^^ expected struct `Mysql`, found struct `Pg`
2929
|
3030
= note: required because of the requirements on the impl of `LoadQuery<diesel::MysqlConnection, Vec<i32>>` for `SelectStatement<(), diesel::query_builder::select_clause::SelectClause<diesel::pg::expression::array::ArrayLiteral<(diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>,), diesel::sql_types::Integer>>>`
3131

3232
error[E0277]: the trait bound `Mysql: HasSqlType<Array<diesel::sql_types::Integer>>` is not satisfied
3333
--> $DIR/array_only_usable_with_pg.rs:11:25
3434
|
35-
11 | select(array((1,))).get_result::<Vec<i32>>(&connection);
35+
11 | select(array((1,))).get_result::<Vec<i32>>(&mut connection);
3636
| ^^^^^^^^^^ the trait `HasSqlType<Array<diesel::sql_types::Integer>>` is not implemented for `Mysql`
3737
|
3838
= help: the following implementations were found:

0 commit comments

Comments
 (0)