diff --git a/diesel/src/mysql/types/primitives.rs b/diesel/src/mysql/types/primitives.rs index cdedd0887d7b..7a680018775f 100644 --- a/diesel/src/mysql/types/primitives.rs +++ b/diesel/src/mysql/types/primitives.rs @@ -23,8 +23,6 @@ where } fn f32_to_i64(f: f32) -> deserialize::Result { - use std::i64; - if f <= i64::MAX as f32 && f >= i64::MIN as f32 { Ok(f.trunc() as i64) } else { @@ -35,8 +33,6 @@ fn f32_to_i64(f: f32) -> deserialize::Result { } fn f64_to_i64(f: f64) -> deserialize::Result { - use std::i64; - if f <= i64::MAX as f64 && f >= i64::MIN as f64 { Ok(f.trunc() as i64) } else { diff --git a/diesel/src/pg/types/money.rs b/diesel/src/pg/types/money.rs index bf534bb67264..50ac2230cc33 100644 --- a/diesel/src/pg/types/money.rs +++ b/diesel/src/pg/types/money.rs @@ -117,7 +117,7 @@ fn add_assign_money() { #[test] #[should_panic(expected = "overflow adding money amounts")] fn add_money_overflow() { - let c1 = PgMoney(::std::i64::MAX); + let c1 = PgMoney(i64::MAX); let c2 = PgMoney(1); let _overflow = c1 + c2; } @@ -125,7 +125,7 @@ fn add_money_overflow() { #[test] #[should_panic(expected = "overflow adding money amounts")] fn add_assign_money_overflow() { - let mut c1 = PgMoney(::std::i64::MAX); + let mut c1 = PgMoney(i64::MAX); c1 += PgMoney(1); } @@ -146,7 +146,7 @@ fn sub_assign_money() { #[test] #[should_panic(expected = "underflow subtracting money amounts")] fn sub_money_underflow() { - let c1 = PgMoney(::std::i64::MIN); + let c1 = PgMoney(i64::MIN); let c2 = PgMoney(1); let _underflow = c1 - c2; } @@ -154,6 +154,6 @@ fn sub_money_underflow() { #[test] #[should_panic(expected = "underflow subtracting money amounts")] fn sub_assign_money_underflow() { - let mut c1 = PgMoney(::std::i64::MIN); + let mut c1 = PgMoney(i64::MIN); c1 -= PgMoney(1); } diff --git a/diesel_compile_tests/tests/fail/aggregate_expression_requires_column_from_same_table.stderr b/diesel_compile_tests/tests/fail/aggregate_expression_requires_column_from_same_table.stderr index 647c745e65c6..04368b866cd0 100644 --- a/diesel_compile_tests/tests/fail/aggregate_expression_requires_column_from_same_table.stderr +++ b/diesel_compile_tests/tests/fail/aggregate_expression_requires_column_from_same_table.stderr @@ -6,13 +6,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `diesel::expression::functions::aggregate_folding::sum_utils::sum` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl>` @@ -41,13 +41,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `diesel::expression::functions::aggregate_folding::avg_utils::avg` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl>` @@ -76,13 +76,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `diesel::expression::functions::aggregate_ordering::max_utils::max` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl>` @@ -111,13 +111,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `diesel::expression::functions::aggregate_ordering::min_utils::min` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl>` diff --git a/diesel_compile_tests/tests/fail/array_expressions_must_be_correct_type.stderr b/diesel_compile_tests/tests/fail/array_expressions_must_be_correct_type.stderr index 7fef62176371..6f5f54e1c148 100644 --- a/diesel_compile_tests/tests/fail/array_expressions_must_be_correct_type.stderr +++ b/diesel_compile_tests/tests/fail/array_expressions_must_be_correct_type.stderr @@ -8,14 +8,14 @@ error[E0277]: Cannot select `f64` from `NoFromClause` | = note: `f64` is no valid selection for `NoFromClause` = help: the following other types implement trait `SelectableExpression`: - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - > - > - as SelectableExpression> + <&'a T as SelectableExpression> + <(T0, T1) as SelectableExpression> + <(T0, T1, T2) as SelectableExpression> + <(T0, T1, T2, T3) as SelectableExpression> + <(T0, T1, T2, T3, T4) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6, T7) as SelectableExpression> and $N others = note: required for `(f64, f64)` to implement `SelectableExpression` = note: 1 redundant requirement hidden @@ -43,14 +43,14 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `(f64, f64)` to implement `ValidGrouping<()>` = note: 1 redundant requirement hidden @@ -78,14 +78,14 @@ error[E0277]: Cannot select `f64` from `NoFromClause` | = note: `f64` is no valid selection for `NoFromClause` = help: the following other types implement trait `SelectableExpression`: - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - > - > - as SelectableExpression> + <&'a T as SelectableExpression> + <(T0, T1) as SelectableExpression> + <(T0, T1, T2) as SelectableExpression> + <(T0, T1, T2, T3) as SelectableExpression> + <(T0, T1, T2, T3, T4) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6, T7) as SelectableExpression> and $N others = note: required for `(f64, f64)` to implement `SelectableExpression` = note: 1 redundant requirement hidden @@ -113,14 +113,14 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `(f64, f64)` to implement `ValidGrouping<()>` = note: 1 redundant requirement hidden @@ -147,14 +147,14 @@ error[E0277]: the trait bound `f64: QueryId` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `QueryId`: - Box - DeleteStatement - FromClause - diesel::query_builder::insert_statement::insert_with_default_for_sqlite::SqliteBatchInsertWrapper - diesel::query_builder::select_clause::DefaultSelectClause - BoxedSqlQuery<'_, DB, Query> - diesel::query_builder::where_clause::BoxedWhereClause<'a, DB> - query_source::joins::Join + &'a T + () + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) and $N others = note: required for `(f64, f64)` to implement `QueryId` = note: 3 redundant requirements hidden @@ -182,14 +182,14 @@ error[E0277]: `f64` is no valid SQL fragment for the `Pg` backend = note: this usually means that the `Pg` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> - as QueryFragment> - as QueryFragment> - >, Tab, QId, STATIC_QUERY_ID> as QueryFragment> - as QueryFragment> - as QueryFragment> - as QueryFragment> - as QueryFragment> + <&'a T as QueryFragment> + <() as QueryFragment> + <(T0, T1) as QueryFragment<__DB>> + <(T0, T1, T2) as QueryFragment<__DB>> + <(T0, T1, T2, T3) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5, T6) as QueryFragment<__DB>> and $N others = note: required for `(f64, f64)` to implement `QueryFragment` = note: 4 redundant requirements hidden @@ -215,14 +215,14 @@ error[E0277]: the trait bound `f64: diesel::Expression` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `diesel::Expression`: - Box - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div - now - today - In + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `f64` to implement `AsExpression` = note: required for `(f64, f64)` to implement `AsExpressionList` diff --git a/diesel_compile_tests/tests/fail/array_expressions_must_be_same_type.stderr b/diesel_compile_tests/tests/fail/array_expressions_must_be_same_type.stderr index 5f71d85cb234..3afddf74e998 100644 --- a/diesel_compile_tests/tests/fail/array_expressions_must_be_same_type.stderr +++ b/diesel_compile_tests/tests/fail/array_expressions_must_be_same_type.stderr @@ -8,14 +8,14 @@ error[E0277]: Cannot select `f64` from `NoFromClause` | = note: `f64` is no valid selection for `NoFromClause` = help: the following other types implement trait `SelectableExpression`: - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - > - > - as SelectableExpression> + <&'a T as SelectableExpression> + <(T0, T1) as SelectableExpression> + <(T0, T1, T2) as SelectableExpression> + <(T0, T1, T2, T3) as SelectableExpression> + <(T0, T1, T2, T3, T4) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6, T7) as SelectableExpression> and $N others = note: required for `(diesel::expression::bound::Bound, f64)` to implement `SelectableExpression` = note: 1 redundant requirement hidden @@ -45,14 +45,14 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `(f64,)` to implement `ValidGrouping<()>` = note: 2 redundant requirements hidden @@ -81,14 +81,14 @@ error[E0277]: Cannot select `f64` from `NoFromClause` | = note: `f64` is no valid selection for `NoFromClause` = help: the following other types implement trait `SelectableExpression`: - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - > - > - as SelectableExpression> + <&'a T as SelectableExpression> + <(T0, T1) as SelectableExpression> + <(T0, T1, T2) as SelectableExpression> + <(T0, T1, T2, T3) as SelectableExpression> + <(T0, T1, T2, T3, T4) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6, T7) as SelectableExpression> and $N others = note: required for `(diesel::expression::bound::Bound, f64)` to implement `SelectableExpression` = note: 1 redundant requirement hidden @@ -118,14 +118,14 @@ error[E0277]: the trait bound `f64: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `(f64,)` to implement `ValidGrouping<()>` = note: 2 redundant requirements hidden @@ -153,14 +153,14 @@ error[E0277]: the trait bound `f64: QueryId` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `QueryId`: - Box - DeleteStatement - FromClause - diesel::query_builder::insert_statement::insert_with_default_for_sqlite::SqliteBatchInsertWrapper - diesel::query_builder::select_clause::DefaultSelectClause - BoxedSqlQuery<'_, DB, Query> - diesel::query_builder::where_clause::BoxedWhereClause<'a, DB> - query_source::joins::Join + &'a T + () + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) and $N others = note: required for `(diesel::expression::bound::Bound, f64)` to implement `QueryId` = note: 3 redundant requirements hidden @@ -188,14 +188,14 @@ error[E0277]: `f64` is no valid SQL fragment for the `Pg` backend = note: this usually means that the `Pg` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> - as QueryFragment> - as QueryFragment> - >, Tab, QId, STATIC_QUERY_ID> as QueryFragment> - as QueryFragment> - as QueryFragment> - as QueryFragment> - as QueryFragment> + <&'a T as QueryFragment> + <() as QueryFragment> + <(T0, T1) as QueryFragment<__DB>> + <(T0, T1, T2) as QueryFragment<__DB>> + <(T0, T1, T2, T3) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5, T6) as QueryFragment<__DB>> and $N others = note: required for `(diesel::expression::bound::Bound, f64)` to implement `QueryFragment` = note: 4 redundant requirements hidden @@ -221,14 +221,14 @@ error[E0277]: the trait bound `f64: diesel::Expression` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `diesel::Expression`: - Box - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div - now - today - In + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `f64` to implement `AsExpression` = note: required for `(i32, f64)` to implement `AsExpressionList` @@ -251,14 +251,14 @@ error[E0277]: Cannot select `{integer}` from `NoFromClause` | = note: `{integer}` is no valid selection for `NoFromClause` = help: the following other types implement trait `SelectableExpression`: - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - > - > - as SelectableExpression> + <&'a T as SelectableExpression> + <(T0, T1) as SelectableExpression> + <(T0, T1, T2) as SelectableExpression> + <(T0, T1, T2, T3) as SelectableExpression> + <(T0, T1, T2, T3, T4) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6, T7) as SelectableExpression> and $N others = note: required for `({integer}, diesel::expression::bound::Bound)` to implement `SelectableExpression` = note: 1 redundant requirement hidden @@ -288,14 +288,14 @@ error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `({integer}, diesel::expression::bound::Bound)` to implement `ValidGrouping<()>` = note: 1 redundant requirement hidden @@ -324,14 +324,14 @@ error[E0277]: Cannot select `{integer}` from `NoFromClause` | = note: `{integer}` is no valid selection for `NoFromClause` = help: the following other types implement trait `SelectableExpression`: - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - as SelectableExpression> - > - > - as SelectableExpression> + <&'a T as SelectableExpression> + <(T0, T1) as SelectableExpression> + <(T0, T1, T2) as SelectableExpression> + <(T0, T1, T2, T3) as SelectableExpression> + <(T0, T1, T2, T3, T4) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6) as SelectableExpression> + <(T0, T1, T2, T3, T4, T5, T6, T7) as SelectableExpression> and $N others = note: required for `({integer}, diesel::expression::bound::Bound)` to implement `SelectableExpression` = note: 1 redundant requirement hidden @@ -361,14 +361,14 @@ error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - as ValidGrouping<__GroupByClause>> - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `({integer}, diesel::expression::bound::Bound)` to implement `ValidGrouping<()>` = note: 1 redundant requirement hidden @@ -396,14 +396,14 @@ error[E0277]: the trait bound `{integer}: QueryId` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `QueryId`: - Box - DeleteStatement - FromClause - diesel::query_builder::insert_statement::insert_with_default_for_sqlite::SqliteBatchInsertWrapper - diesel::query_builder::select_clause::DefaultSelectClause - BoxedSqlQuery<'_, DB, Query> - diesel::query_builder::where_clause::BoxedWhereClause<'a, DB> - query_source::joins::Join + &'a T + () + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) and $N others = note: required for `({integer}, diesel::expression::bound::Bound)` to implement `QueryId` = note: 3 redundant requirements hidden @@ -431,14 +431,14 @@ error[E0277]: `{integer}` is no valid SQL fragment for the `Pg` backend = note: this usually means that the `Pg` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> - as QueryFragment> - as QueryFragment> - >, Tab, QId, STATIC_QUERY_ID> as QueryFragment> - as QueryFragment> - as QueryFragment> - as QueryFragment> - as QueryFragment> + <&'a T as QueryFragment> + <() as QueryFragment> + <(T0, T1) as QueryFragment<__DB>> + <(T0, T1, T2) as QueryFragment<__DB>> + <(T0, T1, T2, T3) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5, T6) as QueryFragment<__DB>> and $N others = note: required for `({integer}, diesel::expression::bound::Bound)` to implement `QueryFragment` = note: 4 redundant requirements hidden @@ -464,14 +464,14 @@ error[E0277]: the trait bound `{integer}: diesel::Expression` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `diesel::Expression`: - Box - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div - now - today - In + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `{integer}` to implement `AsExpression` = note: required for `({integer}, f64)` to implement `AsExpressionList` diff --git a/diesel_compile_tests/tests/fail/auto_type_life_times.stderr b/diesel_compile_tests/tests/fail/auto_type_life_times.stderr index 4dcf2632d83a..1d7d873115be 100644 --- a/diesel_compile_tests/tests/fail/auto_type_life_times.stderr +++ b/diesel_compile_tests/tests/fail/auto_type_life_times.stderr @@ -31,19 +31,3 @@ help: consider introducing a named lifetime parameter | 17 | fn with_lifetime2<'a>(name: &'a str) -> _ { | ++++ ++ - -error: lifetime may not live long enough - --> tests/fail/auto_type_life_times.rs:13:5 - | -12 | fn with_lifetime(name: &'_ str) -> _ { - | - let's call the lifetime of this reference `'1` -13 | users::table.filter(users::name.eq(name)) - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ returning this value requires that `'1` must outlive `'static` - -error: lifetime may not live long enough - --> tests/fail/auto_type_life_times.rs:18:5 - | -17 | fn with_lifetime2(name: &str) -> _ { - | - let's call the lifetime of this reference `'1` -18 | users::table.filter(users::name.eq(name)) - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ returning this value requires that `'1` must outlive `'static` diff --git a/diesel_compile_tests/tests/fail/boxed_queries_and_group_by.stderr b/diesel_compile_tests/tests/fail/boxed_queries_and_group_by.stderr index d2c7ba6d23c8..0034c2f02e1e 100644 --- a/diesel_compile_tests/tests/fail/boxed_queries_and_group_by.stderr +++ b/diesel_compile_tests/tests/fail/boxed_queries_and_group_by.stderr @@ -64,12 +64,12 @@ error[E0277]: the trait bound `BoxedSelectStatement<'_, diesel::sql_types::Text, | ^^^^^^^^^^ the trait `Table` is not implemented for `BoxedSelectStatement<'_, diesel::sql_types::Text, FromClause, _, users::columns::name>`, which is required by `BoxedSelectStatement<'_, diesel::sql_types::Text, FromClause, _, users::columns::name>: JoinWithImplicitOnClause<_, Inner>` | = help: the following other types implement trait `Table`: - posts::table - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + posts::table + users::table = note: required for `BoxedSelectStatement<'_, diesel::sql_types::Text, FromClause, _, users::columns::name>` to implement `JoinTo>` = note: required for `BoxedSelectStatement<'_, diesel::sql_types::Text, FromClause, _, users::columns::name>` to implement `JoinWithImplicitOnClause, Inner>` @@ -129,12 +129,12 @@ error[E0277]: the trait bound `BoxedSelectStatement<'_, (diesel::sql_types::Inte | ^^^^^^^^ the trait `Table` is not implemented for `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause, _>`, which is required by `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause, _>: GroupByDsl<_>` | = help: the following other types implement trait `Table`: - posts::table - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + posts::table + users::table = note: required for `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause, _>` to implement `GroupByDsl<_>` error[E0277]: the trait bound `SelectStatement, _>>>: GroupByDsl<_>` is not satisfied diff --git a/diesel_compile_tests/tests/fail/cannot_join_to_non_joinable_table.stderr b/diesel_compile_tests/tests/fail/cannot_join_to_non_joinable_table.stderr index 0744935b4ba2..7c7ddc8b5685 100644 --- a/diesel_compile_tests/tests/fail/cannot_join_to_non_joinable_table.stderr +++ b/diesel_compile_tests/tests/fail/cannot_join_to_non_joinable_table.stderr @@ -7,13 +7,13 @@ error[E0277]: the trait bound `users::table: JoinTo` is not satisf | required by a bound introduced by this call | = help: the following other types implement trait `JoinTo`: - >> - , ST, DB>>> - , S, D, W, O, L, Of, G>>> >> + , ST, DB>>> >> >> + , S, D, W, O, L, Of, G>>> >> + >> = note: required for `users::table` to implement `JoinWithImplicitOnClause` note: required by a bound in `inner_join` --> $DIESEL/src/query_dsl/mod.rs @@ -33,13 +33,13 @@ error[E0277]: the trait bound `users::table: JoinTo` is not satisf | required by a bound introduced by this call | = help: the following other types implement trait `JoinTo`: - >> - , ST, DB>>> - , S, D, W, O, L, Of, G>>> >> + , ST, DB>>> >> >> + , S, D, W, O, L, Of, G>>> >> + >> = note: required for `users::table` to implement `JoinWithImplicitOnClause` note: required by a bound in `left_outer_join` --> $DIESEL/src/query_dsl/mod.rs @@ -57,13 +57,13 @@ error[E0277]: the trait bound `posts::table: JoinTo` is not satisf | ^^^^^^^^^^ the trait `JoinTo` is not implemented for `posts::table`, which is required by `users::table: JoinWithImplicitOnClause<_, Inner>` | = help: the following other types implement trait `JoinTo`: - > - >> - , ST, DB>>> - , S, D, W, O, L, Of, G>>> >> + , ST, DB>>> >> >> + , S, D, W, O, L, Of, G>>> >> + > + >> = note: required for `query_source::joins::Join` to implement `JoinTo` = note: required for `users::table` to implement `JoinWithImplicitOnClause, diesel::expression::grouped::Grouped, NullableExpression>>>>>, Inner>` diff --git a/diesel_compile_tests/tests/fail/cannot_mix_aggregate_and_non_aggregate_selects.stderr b/diesel_compile_tests/tests/fail/cannot_mix_aggregate_and_non_aggregate_selects.stderr index 4aafe179a802..402384172947 100644 --- a/diesel_compile_tests/tests/fail/cannot_mix_aggregate_and_non_aggregate_selects.stderr +++ b/diesel_compile_tests/tests/fail/cannot_mix_aggregate_and_non_aggregate_selects.stderr @@ -5,8 +5,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::No: MixedAggreg | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::No`, which is required by `SelectStatement>: SelectDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `(columns::id, CountStar)` to implement `ValidGrouping<()>` = note: required for `SelectStatement>` to implement `SelectDsl<(columns::id, CountStar)>` @@ -17,8 +17,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::No: MixedAggreg | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::No`, which is required by `SelectStatement>: SelectDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `Add, nullable_int_col>>` to implement `ValidGrouping<()>` = note: required for `SelectStatement>` to implement `SelectDsl, columns::nullable_int_col>>>` = note: consider using `--verbose` to print the full type name to the console @@ -30,8 +30,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::No: MixedAggreg | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::No`, which is required by `SelectStatement>: SelectDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > note: required for `__Derived, nullable_int_col>>` to implement `ValidGrouping<()>` --> tests/fail/cannot_mix_aggregate_and_non_aggregate_selects.rs:14:1 | diff --git a/diesel_compile_tests/tests/fail/cannot_pass_aggregate_to_where.stderr b/diesel_compile_tests/tests/fail/cannot_pass_aggregate_to_where.stderr index 96607fcc82e3..a44a613e183b 100644 --- a/diesel_compile_tests/tests/fail/cannot_pass_aggregate_to_where.stderr +++ b/diesel_compile_tests/tests/fail/cannot_pass_aggregate_to_where.stderr @@ -5,8 +5,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::Yes: MixedAggre | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::Yes`, which is required by `SelectStatement>: FilterDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `Grouped, Bound>>` to implement `NonAggregate` = note: required for `SelectStatement>` to implement `FilterDsl, diesel::expression::bound::Bound>>>` = note: consider using `--verbose` to print the full type name to the console diff --git a/diesel_compile_tests/tests/fail/cannot_update_target_with_methods_other_than_filter_called.stderr b/diesel_compile_tests/tests/fail/cannot_update_target_with_methods_other_than_filter_called.stderr index 185f9dd08341..e00ea56f145f 100644 --- a/diesel_compile_tests/tests/fail/cannot_update_target_with_methods_other_than_filter_called.stderr +++ b/diesel_compile_tests/tests/fail/cannot_update_target_with_methods_other_than_filter_called.stderr @@ -7,10 +7,10 @@ error[E0277]: the trait bound `SelectStatement, diesel: | required by a bound introduced by this call | = help: the following other types implement trait `IntoUpdateTarget`: - users::table SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, W> pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, diesel::query_builder::select_clause::SelectClause>` to implement `IntoUpdateTarget` note: required by a bound in `diesel::update` --> $DIESEL/src/query_builder/functions.rs @@ -27,10 +27,10 @@ error[E0277]: the trait bound `SelectStatement, diesel: | required by a bound introduced by this call | = help: the following other types implement trait `IntoUpdateTarget`: - users::table SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, W> pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `IntoUpdateTarget` note: required by a bound in `diesel::update` --> $DIESEL/src/query_builder/functions.rs diff --git a/diesel_compile_tests/tests/fail/custom_returning_requires_nonaggregate.stderr b/diesel_compile_tests/tests/fail/custom_returning_requires_nonaggregate.stderr index 2b557023e10f..4aa5490423d1 100644 --- a/diesel_compile_tests/tests/fail/custom_returning_requires_nonaggregate.stderr +++ b/diesel_compile_tests/tests/fail/custom_returning_requires_nonaggregate.stderr @@ -7,8 +7,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::Yes: MixedAggre | required by a bound introduced by this call | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `UpdateStatement>>>, Assign<..., ...>, ...>` to implement `Query` note: required by a bound in `UpdateStatement::::returning` --> $DIESEL/src/query_builder/update_statement/mod.rs @@ -29,8 +29,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::No: MixedAggreg | required by a bound introduced by this call | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `(columns::name, diesel::expression::count::count_utils::count)` to implement `ValidGrouping<()>` = note: required for `(columns::name, diesel::expression::count::count_utils::count)` to implement `NonAggregate` = note: required for `InsertStatement,), ...>, ..., ...>` to implement `Query` diff --git a/diesel_compile_tests/tests/fail/custom_returning_requires_selectable_expression.stderr b/diesel_compile_tests/tests/fail/custom_returning_requires_selectable_expression.stderr index fe2828928777..a18cf7963a1a 100644 --- a/diesel_compile_tests/tests/fail/custom_returning_requires_selectable_expression.stderr +++ b/diesel_compile_tests/tests/fail/custom_returning_requires_selectable_expression.stderr @@ -8,13 +8,13 @@ error[E0277]: Cannot select `bad::columns::age` from `users::table` | = note: `bad::columns::age` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `UpdateStatement>>>, Assign<..., ...>, ...>` to implement `Query` note: required by a bound in `UpdateStatement::::returning` --> $DIESEL/src/query_builder/update_statement/mod.rs @@ -36,13 +36,13 @@ error[E0277]: Cannot select `bad::columns::age` from `users::table` | = note: `bad::columns::age` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(users::columns::name, bad::columns::age)` to implement `SelectableExpression` = note: required for `InsertStatement,), ...>, ..., ...>` to implement `Query` note: required by a bound in `InsertStatement::::returning` diff --git a/diesel_compile_tests/tests/fail/delete_statement_does_not_support_returning_methods_on_sqlite.stderr b/diesel_compile_tests/tests/fail/delete_statement_does_not_support_returning_methods_on_sqlite.stderr index 467d6dd777f0..91889a2f69db 100644 --- a/diesel_compile_tests/tests/fail/delete_statement_does_not_support_returning_methods_on_sqlite.stderr +++ b/diesel_compile_tests/tests/fail/delete_statement_does_not_support_returning_methods_on_sqlite.stderr @@ -9,9 +9,9 @@ error[E0277]: `ReturningClause<(columns::id, columns::name)>` is no valid SQL fr = note: this usually means that the `Sqlite` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> as QueryFragment> as QueryFragment> + as QueryFragment> = note: required for `ReturningClause<(columns::id, columns::name)>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `DeleteStatement>>>, ReturningClause<(id, name)>>` to implement `QueryFragment` @@ -38,9 +38,9 @@ error[E0277]: `ReturningClause` is no valid SQL fragment for the = note: this usually means that the `Sqlite` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> as QueryFragment> as QueryFragment> + as QueryFragment> = note: required for `ReturningClause` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `DeleteStatement>>>, ReturningClause>` to implement `QueryFragment` diff --git a/diesel_compile_tests/tests/fail/derive/aliases.stderr b/diesel_compile_tests/tests/fail/derive/aliases.stderr index d96e3e2103a0..2a62944255fe 100644 --- a/diesel_compile_tests/tests/fail/derive/aliases.stderr +++ b/diesel_compile_tests/tests/fail/derive/aliases.stderr @@ -117,13 +117,13 @@ error[E0277]: Cannot select `users::columns::id` from `Alias` | = note: `users::columns::id` is no valid selection for `Alias` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + >> + >> + > = note: required for `SelectStatement>>` to implement `SelectDsl` = note: 1 redundant requirement hidden = note: required for `Alias` to implement `SelectDsl` @@ -146,13 +146,13 @@ error[E0277]: Cannot select `users::columns::id` from `Alias` | = note: `users::columns::id` is no valid selection for `Alias` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + >> + >> + > = note: required for `diesel::query_builder::select_clause::SelectClause` to implement `diesel::query_builder::select_clause::SelectClauseExpression>>` = note: required for `SelectStatement>, diesel::query_builder::select_clause::SelectClause>` to implement `Query` = note: required for `SelectStatement>, diesel::query_builder::select_clause::SelectClause>` to implement `LoadQuery<'_, _, i32>` @@ -172,14 +172,14 @@ error[E0277]: the trait bound `users::table: JoinTo` is not satisfi | ^^^^^^^^^^ the trait `JoinTo` is not implemented for `users::table`, which is required by `pets::table: JoinWithImplicitOnClause<_, Inner>` | = help: the following other types implement trait `JoinTo`: - > - >> - , ST, DB>>> - , S, D, W, O, L, Of, G>>> >> + , ST, DB>>> >> >> + , S, D, W, O, L, Of, G>>> >> + > + >> = note: required for `Alias` to implement `JoinTo` = note: required for `pets::table` to implement `JoinWithImplicitOnClause, Inner>` diff --git a/diesel_compile_tests/tests/fail/derive/bad_insertable.stderr b/diesel_compile_tests/tests/fail/derive/bad_insertable.stderr index 677bb64fce67..da908ef0f94b 100644 --- a/diesel_compile_tests/tests/fail/derive/bad_insertable.stderr +++ b/diesel_compile_tests/tests/fail/derive/bad_insertable.stderr @@ -5,14 +5,14 @@ error[E0277]: the trait bound `std::string::String: diesel::Expression` is not s | ^^^^^^^^^^ the trait `diesel::Expression` is not implemented for `std::string::String`, which is required by `std::string::String: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `std::string::String` to implement `AsExpression` = note: this error originates in the derive macro `Insertable` (in Nightly builds, run with -Z macro-backtrace for more info) @@ -24,14 +24,14 @@ error[E0277]: the trait bound `i32: diesel::Expression` is not satisfied | ^^^^^^^^^^ the trait `diesel::Expression` is not implemented for `i32`, which is required by `i32: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `i32` to implement `AsExpression` = note: this error originates in the derive macro `Insertable` (in Nightly builds, run with -Z macro-backtrace for more info) @@ -43,14 +43,14 @@ error[E0277]: the trait bound `std::string::String: diesel::Expression` is not s | ^^^^^^^^^^ the trait `diesel::Expression` is not implemented for `std::string::String`, which is required by `&'insert std::string::String: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `&'insert std::string::String` to implement `diesel::Expression` = note: required for `&'insert std::string::String` to implement `AsExpression` @@ -63,14 +63,14 @@ error[E0277]: the trait bound `i32: diesel::Expression` is not satisfied | ^^^^^^^^^^ the trait `diesel::Expression` is not implemented for `i32`, which is required by `&'insert i32: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `&'insert i32` to implement `diesel::Expression` = note: required for `&'insert i32` to implement `AsExpression` @@ -83,14 +83,14 @@ error[E0277]: the trait bound `std::string::String: diesel::Expression` is not s | ^^ the trait `diesel::Expression` is not implemented for `std::string::String`, which is required by `std::string::String: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `std::string::String` to implement `AsExpression` @@ -101,14 +101,14 @@ error[E0277]: the trait bound `i32: diesel::Expression` is not satisfied | ^^^^ the trait `diesel::Expression` is not implemented for `i32`, which is required by `i32: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `i32` to implement `AsExpression` @@ -119,14 +119,14 @@ error[E0277]: the trait bound `std::string::String: diesel::Expression` is not s | ^^ the trait `diesel::Expression` is not implemented for `std::string::String`, which is required by `&'insert std::string::String: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `&'insert std::string::String` to implement `diesel::Expression` = note: required for `&'insert std::string::String` to implement `AsExpression` @@ -138,14 +138,14 @@ error[E0277]: the trait bound `i32: diesel::Expression` is not satisfied | ^^^^ the trait `diesel::Expression` is not implemented for `i32`, which is required by `&'insert i32: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - Box - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `&'insert i32` to implement `diesel::Expression` = note: required for `&'insert i32` to implement `AsExpression` diff --git a/diesel_compile_tests/tests/fail/derive/queryable_type_mismatch.stderr b/diesel_compile_tests/tests/fail/derive/queryable_type_mismatch.stderr index bd92ac068d59..60dd5513d0f6 100644 --- a/diesel_compile_tests/tests/fail/derive/queryable_type_mismatch.stderr +++ b/diesel_compile_tests/tests/fail/derive/queryable_type_mismatch.stderr @@ -11,7 +11,6 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T = note: consider using `#[derive(Selectable)]` + `#[diesel(check_for_backend(_))]` on your struct `UserWithToFewFields` and in your query `.select(UserWithToFewFields::as_select())` to get a better error message = help: the following other types implement trait `load_dsl::private::CompatibleType`: - (ST0,) (ST0, ST1) (ST0, ST1, ST2) (ST0, ST1, ST2, ST3) @@ -19,6 +18,7 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T (ST0, ST1, ST2, ST3, ST4, ST5) (ST0, ST1, ST2, ST3, ST4, ST5, ST6) (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7) + (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7, ST8) and $N others = note: required for `users::table` to implement `LoadQuery<'_, _, UserWithToFewFields>` note: required by a bound in `diesel::RunQueryDsl::load` @@ -43,7 +43,6 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T = note: consider using `#[derive(Selectable)]` + `#[diesel(check_for_backend(_))]` on your struct `UserWithToManyFields` and in your query `.select(UserWithToManyFields::as_select())` to get a better error message = help: the following other types implement trait `load_dsl::private::CompatibleType`: - (ST0,) (ST0, ST1) (ST0, ST1, ST2) (ST0, ST1, ST2, ST3) @@ -51,6 +50,7 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T (ST0, ST1, ST2, ST3, ST4, ST5) (ST0, ST1, ST2, ST3, ST4, ST5, ST6) (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7) + (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7, ST8) and $N others = note: required for `users::table` to implement `LoadQuery<'_, _, UserWithToManyFields>` note: required by a bound in `diesel::RunQueryDsl::load` @@ -75,7 +75,6 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T = note: consider using `#[derive(Selectable)]` + `#[diesel(check_for_backend(_))]` on your struct `UserWrongOrder` and in your query `.select(UserWrongOrder::as_select())` to get a better error message = help: the following other types implement trait `load_dsl::private::CompatibleType`: - (ST0,) (ST0, ST1) (ST0, ST1, ST2) (ST0, ST1, ST2, ST3) @@ -83,6 +82,7 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T (ST0, ST1, ST2, ST3, ST4, ST5) (ST0, ST1, ST2, ST3, ST4, ST5, ST6) (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7) + (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7, ST8) and $N others = note: required for `users::table` to implement `LoadQuery<'_, _, UserWrongOrder>` note: required by a bound in `diesel::RunQueryDsl::load` @@ -107,7 +107,6 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T = note: consider using `#[derive(Selectable)]` + `#[diesel(check_for_backend(_))]` on your struct `UserTypeMismatch` and in your query `.select(UserTypeMismatch::as_select())` to get a better error message = help: the following other types implement trait `load_dsl::private::CompatibleType`: - (ST0,) (ST0, ST1) (ST0, ST1, ST2) (ST0, ST1, ST2, ST3) @@ -115,6 +114,7 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T (ST0, ST1, ST2, ST3, ST4, ST5) (ST0, ST1, ST2, ST3, ST4, ST5, ST6) (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7) + (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7, ST8) and $N others = note: required for `users::table` to implement `LoadQuery<'_, _, UserTypeMismatch>` note: required by a bound in `diesel::RunQueryDsl::load` diff --git a/diesel_compile_tests/tests/fail/distinct_on_allows_only_fields_of_table.stderr b/diesel_compile_tests/tests/fail/distinct_on_allows_only_fields_of_table.stderr index 7b54eb18467d..27f23a1805e7 100644 --- a/diesel_compile_tests/tests/fail/distinct_on_allows_only_fields_of_table.stderr +++ b/diesel_compile_tests/tests/fail/distinct_on_allows_only_fields_of_table.stderr @@ -8,13 +8,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `users::table` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` --> $DIESEL/src/query_dsl/mod.rs @@ -33,13 +33,13 @@ error[E0277]: Cannot select `users::columns::name` from `posts::table` | = note: `users::columns::name` is no valid selection for `posts::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + >> + >> + > = note: required for `(posts::columns::name, users::columns::name)` to implement `SelectableExpression` = note: required for `posts::table` to implement `DistinctOnDsl<(posts::columns::name, users::columns::name)>` diff --git a/diesel_compile_tests/tests/fail/distinct_on_requires_matching_order_clause.stderr b/diesel_compile_tests/tests/fail/distinct_on_requires_matching_order_clause.stderr index eb9b1a614d81..de901a3216ac 100644 --- a/diesel_compile_tests/tests/fail/distinct_on_requires_matching_order_clause.stderr +++ b/diesel_compile_tests/tests/fail/distinct_on_requires_matching_order_clause.stderr @@ -7,14 +7,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -36,14 +36,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -65,14 +65,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -94,14 +94,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, DistinctOnClause>` to implement `OrderDsl` note: required by a bound in `order_by` @@ -123,14 +123,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -152,14 +152,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -181,14 +181,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl<(columns::name, columns::id)>` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -210,14 +210,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl<(columns::name, columns::id)>` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -239,14 +239,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` @@ -268,14 +268,14 @@ error[E0277]: the trait bound `diesel::query_builder::order_clause::OrderClause< | required by a bound introduced by this call | = help: the following other types implement trait `query_dsl::order_dsl::ValidOrderingForDistinct`: - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> - > as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> + as query_dsl::order_dsl::ValidOrderingForDistinct>> and $N others = note: required for `SelectStatement, DefaultSelectClause>, DistinctOnClause>` to implement `OrderDsl` note: required by a bound in `order_by` diff --git a/diesel_compile_tests/tests/fail/ensure_sqlite_cannot_access_memory_of_dropped_bind.stderr b/diesel_compile_tests/tests/fail/ensure_sqlite_cannot_access_memory_of_dropped_bind.stderr index 54382874b24c..98e10bf03f45 100644 --- a/diesel_compile_tests/tests/fail/ensure_sqlite_cannot_access_memory_of_dropped_bind.stderr +++ b/diesel_compile_tests/tests/fail/ensure_sqlite_cannot_access_memory_of_dropped_bind.stderr @@ -12,3 +12,9 @@ error[E0505]: cannot move out of `buf` because it is borrowed 18 | 19 | assert_eq!(iter.next().is_some(), true); | ---- borrow later used here + | +help: consider cloning the value if the performance cost is acceptable + | +11 - let query = diesel::select((&buf as &[u8]).into_sql::()); +11 + let query = diesel::select((buf.clone() as &[u8]).into_sql::()); + | diff --git a/diesel_compile_tests/tests/fail/exists_can_only_take_subselects.stderr b/diesel_compile_tests/tests/fail/exists_can_only_take_subselects.stderr index 650f50c3be47..ad7ed57b409a 100644 --- a/diesel_compile_tests/tests/fail/exists_can_only_take_subselects.stderr +++ b/diesel_compile_tests/tests/fail/exists_can_only_take_subselects.stderr @@ -5,9 +5,9 @@ error[E0277]: the trait bound `bool: SelectQuery` is not satisfied | ^^^^^^ the trait `SelectQuery` is not implemented for `bool`, which is required by `SelectStatement>: FilterDsl<_>` | = help: the following other types implement trait `SelectQuery`: - diesel::query_builder::combination_clause::CombinationClause BoxedSelectStatement<'a, ST, QS, DB, GB> SelectStatement + diesel::query_builder::combination_clause::CombinationClause = note: required for `diesel::expression::subselect::Subselect` to implement `diesel::Expression` = note: 1 redundant requirement hidden = note: required for `Exists` to implement `diesel::Expression` @@ -20,9 +20,9 @@ error[E0277]: the trait bound `users::columns::id: SelectQuery` is not satisfied | ^^^^^^ the trait `SelectQuery` is not implemented for `users::columns::id`, which is required by `SelectStatement>: FilterDsl<_>` | = help: the following other types implement trait `SelectQuery`: - diesel::query_builder::combination_clause::CombinationClause BoxedSelectStatement<'a, ST, QS, DB, GB> SelectStatement + diesel::query_builder::combination_clause::CombinationClause = note: required for `diesel::expression::subselect::Subselect` to implement `diesel::Expression` = note: 1 redundant requirement hidden = note: required for `Exists` to implement `diesel::Expression` diff --git a/diesel_compile_tests/tests/fail/expressions_can_only_be_compared_for_equality_to_expressions_of_same_type.stderr b/diesel_compile_tests/tests/fail/expressions_can_only_be_compared_for_equality_to_expressions_of_same_type.stderr index 6e2cac5bd225..5eec4100d7c8 100644 --- a/diesel_compile_tests/tests/fail/expressions_can_only_be_compared_for_equality_to_expressions_of_same_type.stderr +++ b/diesel_compile_tests/tests/fail/expressions_can_only_be_compared_for_equality_to_expressions_of_same_type.stderr @@ -5,14 +5,14 @@ error[E0277]: the trait bound `str: diesel::Expression` is not satisfied | ^^ the trait `diesel::Expression` is not implemented for `str`, which is required by `&str: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - columns::name - columns::id - columns::star - Box - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul - diesel::expression::ops::numeric::Div + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `&str` to implement `diesel::Expression` = note: required for `&str` to implement `AsExpression` diff --git a/diesel_compile_tests/tests/fail/filter_requires_bool_nonaggregate_expression.stderr b/diesel_compile_tests/tests/fail/filter_requires_bool_nonaggregate_expression.stderr index 8e66f3c97aec..568e821d8aba 100644 --- a/diesel_compile_tests/tests/fail/filter_requires_bool_nonaggregate_expression.stderr +++ b/diesel_compile_tests/tests/fail/filter_requires_bool_nonaggregate_expression.stderr @@ -29,8 +29,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::Yes: MixedAggre | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::Yes`, which is required by `SelectStatement>: FilterDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `Grouped, Bound, i64>>>` to implement `NonAggregate` = note: required for `SelectStatement>` to implement `FilterDsl, diesel::expression::bound::Bound, i64>>>>` = note: consider using `--verbose` to print the full type name to the console diff --git a/diesel_compile_tests/tests/fail/find_requires_correct_type.stderr b/diesel_compile_tests/tests/fail/find_requires_correct_type.stderr index 2157249d5c62..db69fb564ff9 100644 --- a/diesel_compile_tests/tests/fail/find_requires_correct_type.stderr +++ b/diesel_compile_tests/tests/fail/find_requires_correct_type.stderr @@ -5,14 +5,14 @@ error[E0277]: the trait bound `str: diesel::Expression` is not satisfied | ^^^^ the trait `diesel::Expression` is not implemented for `str`, which is required by `SelectStatement>: FilterDsl>>` | = help: the following other types implement trait `diesel::Expression`: - Box - string_primary_key::columns::id - string_primary_key::columns::star - int_primary_key::columns::id - int_primary_key::columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `&str` to implement `diesel::Expression` = note: 1 redundant requirement hidden @@ -26,14 +26,14 @@ error[E0277]: the trait bound `str: ValidGrouping<()>` is not satisfied | ^^^^ the trait `ValidGrouping<()>` is not implemented for `str`, which is required by `SelectStatement>: FilterDsl>>` | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - > - > - > - > - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `&str` to implement `ValidGrouping<()>` = note: 1 redundant requirement hidden @@ -50,14 +50,14 @@ error[E0277]: the trait bound `{integer}: diesel::Expression` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `diesel::Expression`: - Box - string_primary_key::columns::id - string_primary_key::columns::star - int_primary_key::columns::id - int_primary_key::columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `diesel::expression::operators::Eq` to implement `diesel::Expression` note: required for `string_primary_key::columns::id` to implement `EqAll<{integer}>` @@ -84,14 +84,14 @@ error[E0277]: the trait bound `{integer}: ValidGrouping<()>` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping> - > - > - > - > - > - > - as ValidGrouping<__GroupByClause>> + <&'a T as ValidGrouping> + <(T0, T1) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6) as ValidGrouping<__GroupByClause>> + <(T0, T1, T2, T3, T4, T5, T6, T7) as ValidGrouping<__GroupByClause>> and $N others = note: required for `diesel::expression::operators::Eq` to implement `ValidGrouping<()>` = note: required for `diesel::expression::grouped::Grouped>` to implement `NonAggregate` diff --git a/diesel_compile_tests/tests/fail/having_cant_be_used_without_group_by.stderr b/diesel_compile_tests/tests/fail/having_cant_be_used_without_group_by.stderr index 4e60e7d41331..4e4a3cef1327 100644 --- a/diesel_compile_tests/tests/fail/having_cant_be_used_without_group_by.stderr +++ b/diesel_compile_tests/tests/fail/having_cant_be_used_without_group_by.stderr @@ -14,7 +14,6 @@ error[E0277]: the trait bound `(): diesel::Expression` is not satisfied | ^^^^^^ the trait `diesel::Expression` is not implemented for `()`, which is required by `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause, _>: HavingDsl<_>` | = help: the following other types implement trait `diesel::Expression`: - (T0,) (T0, T1) (T0, T1, T2) (T0, T1, T2, T3) @@ -22,6 +21,7 @@ error[E0277]: the trait bound `(): diesel::Expression` is not satisfied (T0, T1, T2, T3, T4, T5) (T0, T1, T2, T3, T4, T5, T6) (T0, T1, T2, T3, T4, T5, T6, T7) + (T0, T1, T2, T3, T4, T5, T6, T7, T8) and $N others = note: required for `BoxedSelectStatement<'_, (diesel::sql_types::Integer, diesel::sql_types::Text), FromClause, _>` to implement `HavingDsl<_>` diff --git a/diesel_compile_tests/tests/fail/insert_from_select_cant_be_used_with_tuples_or_arrays.stderr b/diesel_compile_tests/tests/fail/insert_from_select_cant_be_used_with_tuples_or_arrays.stderr index dec10330db7d..67978328adbb 100644 --- a/diesel_compile_tests/tests/fail/insert_from_select_cant_be_used_with_tuples_or_arrays.stderr +++ b/diesel_compile_tests/tests/fail/insert_from_select_cant_be_used_with_tuples_or_arrays.stderr @@ -5,14 +5,14 @@ error[E0277]: the trait bound `users::table: UndecoratedInsertRecord` is not implemented for `users::table`, which is required by `Vec: diesel::Insertable` | = help: the following other types implement trait `UndecoratedInsertRecord`: - as UndecoratedInsertRecord
> - > as UndecoratedInsertRecord<::Table>> - as UndecoratedInsertRecord<::Table>> - as UndecoratedInsertRecord<::Table>> - > as UndecoratedInsertRecord<::Table>> - as UndecoratedInsertRecord
> - as UndecoratedInsertRecord<::Table>> - as UndecoratedInsertRecord
> + <&'a T as UndecoratedInsertRecord> + <(T0, T1) as UndecoratedInsertRecord> + <(T0, T1, T2) as UndecoratedInsertRecord> + <(T0, T1, T2, T3) as UndecoratedInsertRecord> + <(T0, T1, T2, T3, T4) as UndecoratedInsertRecord> + <(T0, T1, T2, T3, T4, T5) as UndecoratedInsertRecord> + <(T0, T1, T2, T3, T4, T5, T6) as UndecoratedInsertRecord> + <(T0, T1, T2, T3, T4, T5, T6, T7) as UndecoratedInsertRecord> and $N others = note: required for `Vec` to implement `diesel::Insertable` diff --git a/diesel_compile_tests/tests/fail/insert_from_select_requires_valid_column_list.stderr b/diesel_compile_tests/tests/fail/insert_from_select_requires_valid_column_list.stderr index 407e1b4ff020..0e28e37904c7 100644 --- a/diesel_compile_tests/tests/fail/insert_from_select_requires_valid_column_list.stderr +++ b/diesel_compile_tests/tests/fail/insert_from_select_requires_valid_column_list.stderr @@ -84,7 +84,6 @@ error[E0277]: the trait bound `(comments::columns::post_id, posts::columns::titl | required by a bound introduced by this call | = help: the following other types implement trait `diesel::query_builder::insert_statement::column_list::ColumnList`: - (T0,) (T0, T1) (T0, T1, T2) (T0, T1, T2, T3) @@ -92,6 +91,7 @@ error[E0277]: the trait bound `(comments::columns::post_id, posts::columns::titl (T0, T1, T2, T3, T4, T5) (T0, T1, T2, T3, T4, T5, T6) (T0, T1, T2, T3, T4, T5, T6, T7) + (T0, T1, T2, T3, T4, T5, T6, T7, T8) and $N others note: required by a bound in `InsertStatement::, Op, Ret>::into_columns` --> $DIESEL/src/query_builder/insert_statement/mod.rs diff --git a/diesel_compile_tests/tests/fail/insert_from_select_with_on_conflict_without_where_clause_not_supported_on_sqlite.stderr b/diesel_compile_tests/tests/fail/insert_from_select_with_on_conflict_without_where_clause_not_supported_on_sqlite.stderr index d22a6697d2cd..ed217ee11598 100644 --- a/diesel_compile_tests/tests/fail/insert_from_select_with_on_conflict_without_where_clause_not_supported_on_sqlite.stderr +++ b/diesel_compile_tests/tests/fail/insert_from_select_with_on_conflict_without_where_clause_not_supported_on_sqlite.stderr @@ -11,9 +11,9 @@ error[E0277]: `OnConflictSelectWrapper, Select this SQL syntax = help: the following other types implement trait `QueryFragment`: > as QueryFragment> - , O, LOf, G, H, LC>> as QueryFragment> as QueryFragment> as QueryFragment> + , O, LOf, G, H, LC>> as QueryFragment> = note: required for `InsertFromSelect, SelectClause>>, id>` to implement `QueryFragment` = note: 3 redundant requirements hidden = note: required for `InsertStatement, ...>, ..., ...>>` to implement `QueryFragment` diff --git a/diesel_compile_tests/tests/fail/insert_requires_value_of_same_type_as_column.stderr b/diesel_compile_tests/tests/fail/insert_requires_value_of_same_type_as_column.stderr index 126529d29a89..b020c94d766f 100644 --- a/diesel_compile_tests/tests/fail/insert_requires_value_of_same_type_as_column.stderr +++ b/diesel_compile_tests/tests/fail/insert_requires_value_of_same_type_as_column.stderr @@ -5,13 +5,13 @@ error[E0277]: the trait bound `{integer}: diesel::Expression` is not satisfied | ^^ the trait `diesel::Expression` is not implemented for `{integer}`, which is required by `{integer}: AsExpression` | = help: the following other types implement trait `diesel::Expression`: - Box - columns::hair_color - columns::name - columns::id - columns::star - diesel::expression::ops::numeric::Add - diesel::expression::ops::numeric::Sub - diesel::expression::ops::numeric::Mul + &'a T + (T0, T1) + (T0, T1, T2) + (T0, T1, T2, T3) + (T0, T1, T2, T3, T4) + (T0, T1, T2, T3, T4, T5) + (T0, T1, T2, T3, T4, T5, T6) + (T0, T1, T2, T3, T4, T5, T6, T7) and $N others = note: required for `{integer}` to implement `AsExpression` diff --git a/diesel_compile_tests/tests/fail/insert_statement_does_not_support_returning_methods_on_sqlite.stderr b/diesel_compile_tests/tests/fail/insert_statement_does_not_support_returning_methods_on_sqlite.stderr index 0b9799d87fe7..a375d9b4c2d2 100644 --- a/diesel_compile_tests/tests/fail/insert_statement_does_not_support_returning_methods_on_sqlite.stderr +++ b/diesel_compile_tests/tests/fail/insert_statement_does_not_support_returning_methods_on_sqlite.stderr @@ -9,9 +9,9 @@ error[E0277]: `ReturningClause<(columns::id, columns::name)>` is no valid SQL fr = note: this usually means that the `Sqlite` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> as QueryFragment> as QueryFragment> + as QueryFragment> = note: required for `ReturningClause<(columns::id, columns::name)>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement,), ...>, ..., ...>` to implement `QueryFragment` @@ -38,9 +38,9 @@ error[E0277]: `ReturningClause` is no valid SQL fragment for the = note: this usually means that the `Sqlite` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> as QueryFragment> as QueryFragment> + as QueryFragment> = note: required for `ReturningClause` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement,), ...>, ..., ...>` to implement `QueryFragment` diff --git a/diesel_compile_tests/tests/fail/invalid_group_by.stderr b/diesel_compile_tests/tests/fail/invalid_group_by.stderr index b3a2977e8e60..88ae1c53f403 100644 --- a/diesel_compile_tests/tests/fail/invalid_group_by.stderr +++ b/diesel_compile_tests/tests/fail/invalid_group_by.stderr @@ -69,8 +69,8 @@ error[E0277]: the trait bound `AliasedField: ValidGro | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping<()>> as ValidGrouping>> + as ValidGrouping<()>> = note: required for `SelectStatement>, DefaultSelectClause>, ..., ..., ..., ..., ...>` to implement `SelectDsl>` note: required by a bound in `diesel::QueryDsl::select` --> $DIESEL/src/query_dsl/mod.rs @@ -98,14 +98,14 @@ error[E0277]: the trait bound `AliasedField: IsContai | ^^^^^^ the trait `IsContainedInGroupBy` is not implemented for `AliasedField`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause>>: SelectDsl<_>` | = help: the following other types implement trait `IsContainedInGroupBy`: - > - > - > - > - > - > - > - > + <(T0, T1) as IsContainedInGroupBy> + <(T0, T1, T2) as IsContainedInGroupBy> + <(T0, T1, T2, T3) as IsContainedInGroupBy> + <(T0, T1, T2, T3, T4) as IsContainedInGroupBy> + <(T0, T1, T2, T3, T4, T5) as IsContainedInGroupBy> + <(T0, T1, T2, T3, T4, T5, T6) as IsContainedInGroupBy> + <(T0, T1, T2, T3, T4, T5, T6, T7) as IsContainedInGroupBy> + <(T0, T1, T2, T3, T4, T5, T6, T7, T8) as IsContainedInGroupBy> and $N others note: required for `users::columns::id` to implement `ValidGrouping>` --> tests/fail/invalid_group_by.rs:8:9 @@ -133,8 +133,8 @@ error[E0277]: the trait bound `AliasedField: ValidGro | required by a bound introduced by this call | = help: the following other types implement trait `ValidGrouping`: - as ValidGrouping<()>> as ValidGrouping>> + as ValidGrouping<()>> = note: required for `SelectStatement>, DefaultSelectClause>, ..., ..., ..., ..., ...>` to implement `SelectDsl>` note: required by a bound in `diesel::QueryDsl::select` --> $DIESEL/src/query_dsl/mod.rs diff --git a/diesel_compile_tests/tests/fail/mysql_does_not_support_offset_without_limit.stderr b/diesel_compile_tests/tests/fail/mysql_does_not_support_offset_without_limit.stderr index a18a5fd95b53..dc4dd5435082 100644 --- a/diesel_compile_tests/tests/fail/mysql_does_not_support_offset_without_limit.stderr +++ b/diesel_compile_tests/tests/fail/mysql_does_not_support_offset_without_limit.stderr @@ -9,14 +9,14 @@ error[E0277]: `LimitOffsetClause`: - , OffsetClause> as QueryFragment> - , OffsetClause> as QueryFragment> + as QueryFragment> , NoOffsetClause> as QueryFragment> , NoOffsetClause> as QueryFragment> - > as QueryFragment> + , OffsetClause> as QueryFragment> + , OffsetClause> as QueryFragment> as QueryFragment> as QueryFragment> - as QueryFragment> + > as QueryFragment> = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ..., ...>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ..., ...>` to implement `QueryFragment` @@ -39,14 +39,14 @@ error[E0277]: the trait bound `LimitOffsetClause` is not implemented for `LimitOffsetClause>>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause>>>: BoxedDsl<'_, _>` | = help: the following other types implement trait `IntoBoxedClause<'a, DB>`: - , OffsetClause> as IntoBoxedClause<'a, Mysql>> - , OffsetClause> as IntoBoxedClause<'a, Sqlite>> + as IntoBoxedClause<'a, Pg>> , NoOffsetClause> as IntoBoxedClause<'a, Mysql>> , NoOffsetClause> as IntoBoxedClause<'a, Sqlite>> - > as IntoBoxedClause<'a, Sqlite>> + , OffsetClause> as IntoBoxedClause<'a, Mysql>> + , OffsetClause> as IntoBoxedClause<'a, Sqlite>> as IntoBoxedClause<'a, Mysql>> as IntoBoxedClause<'a, Sqlite>> - as IntoBoxedClause<'a, Pg>> + > as IntoBoxedClause<'a, Sqlite>> = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ..., ...>` to implement `BoxedDsl<'_, Mysql>` = note: consider using `--verbose` to print the full type name to the console @@ -57,14 +57,14 @@ error[E0277]: the trait bound `LimitOffsetClause` is not implemented for `LimitOffsetClause>>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause>>>: BoxedDsl<'_, _>` | = help: the following other types implement trait `IntoBoxedClause<'a, DB>`: - , OffsetClause> as IntoBoxedClause<'a, Mysql>> - , OffsetClause> as IntoBoxedClause<'a, Sqlite>> + as IntoBoxedClause<'a, Pg>> , NoOffsetClause> as IntoBoxedClause<'a, Mysql>> , NoOffsetClause> as IntoBoxedClause<'a, Sqlite>> - > as IntoBoxedClause<'a, Sqlite>> + , OffsetClause> as IntoBoxedClause<'a, Mysql>> + , OffsetClause> as IntoBoxedClause<'a, Sqlite>> as IntoBoxedClause<'a, Mysql>> as IntoBoxedClause<'a, Sqlite>> - as IntoBoxedClause<'a, Pg>> + > as IntoBoxedClause<'a, Sqlite>> = note: required for `SelectStatement, DefaultSelectClause>, NoDistinctClause, ..., ..., ...>` to implement `BoxedDsl<'_, Mysql>` note: required by a bound in `diesel::QueryDsl::into_boxed` --> $DIESEL/src/query_dsl/mod.rs diff --git a/diesel_compile_tests/tests/fail/mysql_on_conflict_tests.stderr b/diesel_compile_tests/tests/fail/mysql_on_conflict_tests.stderr index 8ad98eebfe29..787ccc26f3f7 100644 --- a/diesel_compile_tests/tests/fail/mysql_on_conflict_tests.stderr +++ b/diesel_compile_tests/tests/fail/mysql_on_conflict_tests.stderr @@ -10,10 +10,10 @@ error[E0277]: `OnConflictValues`: - as QueryFragment> - as QueryFragment> - as QueryFragment> > as QueryFragment> + as QueryFragment> + as QueryFragment> + as QueryFragment> = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement, ...), ...>, ..., ...>>` to implement `QueryFragment` @@ -41,10 +41,10 @@ error[E0277]: `OnConflictValues`: - as QueryFragment> - as QueryFragment> - as QueryFragment> > as QueryFragment> + as QueryFragment> + as QueryFragment> + as QueryFragment> = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement, ...), ...>, ..., ...>>` to implement `QueryFragment` @@ -69,14 +69,14 @@ error[E0277]: the trait bound `diesel::query_builder::upsert::on_conflict_target | required by a bound introduced by this call | = help: the following other types implement trait `diesel::query_builder::upsert::on_conflict_target::OnConflictTarget
`: - > as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget> - as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget> - > as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget
> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> and $N others note: required by a bound in `diesel::upsert::on_conflict_extension::>::on_conflict` --> $DIESEL/src/upsert/on_conflict_extension.rs @@ -99,10 +99,10 @@ error[E0277]: `OnConflictValues`: - as QueryFragment> - as QueryFragment> - as QueryFragment> > as QueryFragment> + as QueryFragment> + as QueryFragment> + as QueryFragment> = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement, ...), ...>, ..., ...>>` to implement `QueryFragment` @@ -130,10 +130,10 @@ error[E0277]: `OnConflictValues`: - as QueryFragment> - as QueryFragment> - as QueryFragment> > as QueryFragment> + as QueryFragment> + as QueryFragment> + as QueryFragment> = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement, ...), ...>, ..., ...>>` to implement `QueryFragment` @@ -161,10 +161,10 @@ error[E0277]: `OnConflictValues`: - as QueryFragment> - as QueryFragment> - as QueryFragment> > as QueryFragment> + as QueryFragment> + as QueryFragment> + as QueryFragment> = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `InsertStatement, ...), ...>, ..., ...>>` to implement `QueryFragment` @@ -215,14 +215,14 @@ error[E0277]: the trait bound `diesel::query_builder::upsert::on_conflict_target | required by a bound introduced by this call | = help: the following other types implement trait `diesel::query_builder::upsert::on_conflict_target::OnConflictTarget
`: - > as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget> - as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget> - > as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget
> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> and $N others note: required by a bound in `diesel::upsert::on_conflict_extension::>::on_conflict` --> $DIESEL/src/upsert/on_conflict_extension.rs @@ -244,14 +244,14 @@ error[E0277]: `diesel::query_builder::upsert::on_conflict_target::ConflictTarget = note: this usually means that the `Pg` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - > as QueryFragment> - as QueryFragment> - > as QueryFragment> as QueryFragment> as QueryFragment<_DB, _SP>> as QueryFragment<_DB, _SP>> as QueryFragment<_DB, _SP>> as QueryFragment<_DB, _SP>> + as QueryFragment<_DB, _SP>> + as QueryFragment<_DB, _SP>> + as QueryFragment<_DB, _SP>> and $N others = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 2 redundant requirements hidden @@ -277,14 +277,14 @@ error[E0277]: the trait bound `diesel::query_builder::upsert::on_conflict_target | required by a bound introduced by this call | = help: the following other types implement trait `diesel::query_builder::upsert::on_conflict_target::OnConflictTarget
`: - > as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget> - as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget> - > as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget
> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> + as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>> and $N others note: required by a bound in `diesel::upsert::on_conflict_extension::>::on_conflict` --> $DIESEL/src/upsert/on_conflict_extension.rs @@ -306,14 +306,14 @@ error[E0277]: `diesel::query_builder::upsert::on_conflict_target::ConflictTarget = note: this usually means that the `Pg` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - > as QueryFragment> - as QueryFragment> - > as QueryFragment> as QueryFragment> as QueryFragment<_DB, _SP>> as QueryFragment<_DB, _SP>> as QueryFragment<_DB, _SP>> as QueryFragment<_DB, _SP>> + as QueryFragment<_DB, _SP>> + as QueryFragment<_DB, _SP>> + as QueryFragment<_DB, _SP>> and $N others = note: required for `OnConflictValues>, ...), ...>, ..., ...>` to implement `QueryFragment` = note: 2 redundant requirements hidden diff --git a/diesel_compile_tests/tests/fail/ordering_functions_require_ord.stderr b/diesel_compile_tests/tests/fail/ordering_functions_require_ord.stderr index 5174b4427662..de04595ef856 100644 --- a/diesel_compile_tests/tests/fail/ordering_functions_require_ord.stderr +++ b/diesel_compile_tests/tests/fail/ordering_functions_require_ord.stderr @@ -18,14 +18,14 @@ error[E0277]: expressions of the type `diesel::sql_types::Bool` cannot be ordere | ^^^^^^ the trait `SqlOrd` is not implemented for `diesel::sql_types::Bool`, which is required by `stuff::table: SelectDsl<_>` | = help: the following other types implement trait `SqlOrd`: - diesel::sql_types::SmallInt - diesel::sql_types::Integer + Array BigInt - diesel::sql_types::Float - diesel::sql_types::Double - diesel::sql_types::Text - diesel::sql_types::Date + Datetime Interval + Nullable + Unsigned + Unsigned + Unsigned and $N others = note: required for `diesel::sql_types::Bool` to implement `diesel::expression::functions::aggregate_ordering::private::SqlOrdAggregate` = note: required for `diesel::expression::functions::aggregate_ordering::max_utils::max` to implement `diesel::Expression` @@ -51,14 +51,14 @@ error[E0277]: expressions of the type `diesel::sql_types::Bool` cannot be ordere | ^^^^^^ the trait `SqlOrd` is not implemented for `diesel::sql_types::Bool`, which is required by `stuff::table: SelectDsl<_>` | = help: the following other types implement trait `SqlOrd`: - diesel::sql_types::SmallInt - diesel::sql_types::Integer + Array BigInt - diesel::sql_types::Float - diesel::sql_types::Double - diesel::sql_types::Text - diesel::sql_types::Date + Datetime Interval + Nullable + Unsigned + Unsigned + Unsigned and $N others = note: required for `diesel::sql_types::Bool` to implement `diesel::expression::functions::aggregate_ordering::private::SqlOrdAggregate` = note: required for `diesel::expression::functions::aggregate_ordering::min_utils::min` to implement `diesel::Expression` diff --git a/diesel_compile_tests/tests/fail/pg_on_conflict_requires_valid_conflict_target.stderr b/diesel_compile_tests/tests/fail/pg_on_conflict_requires_valid_conflict_target.stderr index ea7bb6a02438..4a9b53401f22 100644 --- a/diesel_compile_tests/tests/fail/pg_on_conflict_requires_valid_conflict_target.stderr +++ b/diesel_compile_tests/tests/fail/pg_on_conflict_requires_valid_conflict_target.stderr @@ -51,14 +51,14 @@ error[E0277]: the trait bound `lower_utils::lower: Column | required by a bound introduced by this call | = help: the following other types implement trait `Column`: - posts::columns::title - posts::columns::id - users::columns::name - users::columns::id pg::metadata_lookup::pg_namespace::columns::nspname pg::metadata_lookup::pg_namespace::columns::oid - pg::metadata_lookup::pg_type::columns::typnamespace + pg::metadata_lookup::pg_type::columns::oid pg::metadata_lookup::pg_type::columns::typarray + pg::metadata_lookup::pg_type::columns::typname + pg::metadata_lookup::pg_type::columns::typnamespace + posts::columns::id + posts::columns::title and $N others = note: required for `diesel::query_builder::upsert::on_conflict_target::ConflictTarget>` to implement `diesel::query_builder::upsert::on_conflict_target::OnConflictTarget` note: required by a bound in `upsert::on_conflict_extension::>::on_conflict` @@ -79,14 +79,14 @@ error[E0277]: the trait bound `&str: Column` is not satisfied | required by a bound introduced by this call | = help: the following other types implement trait `Column`: - posts::columns::title - posts::columns::id - users::columns::name - users::columns::id pg::metadata_lookup::pg_namespace::columns::nspname pg::metadata_lookup::pg_namespace::columns::oid - pg::metadata_lookup::pg_type::columns::typnamespace + pg::metadata_lookup::pg_type::columns::oid pg::metadata_lookup::pg_type::columns::typarray + pg::metadata_lookup::pg_type::columns::typname + pg::metadata_lookup::pg_type::columns::typnamespace + posts::columns::id + posts::columns::title and $N others = note: required for `diesel::query_builder::upsert::on_conflict_target::ConflictTarget<&str>` to implement `diesel::query_builder::upsert::on_conflict_target::OnConflictTarget` note: required by a bound in `upsert::on_conflict_extension::>::on_conflict` diff --git a/diesel_compile_tests/tests/fail/queryable_with_typemismatch.stderr b/diesel_compile_tests/tests/fail/queryable_with_typemismatch.stderr index 3dd37cb48323..7c3be259581c 100644 --- a/diesel_compile_tests/tests/fail/queryable_with_typemismatch.stderr +++ b/diesel_compile_tests/tests/fail/queryable_with_typemismatch.stderr @@ -11,7 +11,6 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T = note: consider using `#[derive(Selectable)]` + `#[diesel(check_for_backend(_))]` on your struct `User` and in your query `.select(User::as_select())` to get a better error message = help: the following other types implement trait `load_dsl::private::CompatibleType`: - (ST0,) (ST0, ST1) (ST0, ST1, ST2) (ST0, ST1, ST2, ST3) @@ -19,6 +18,7 @@ error[E0277]: the trait bound `(diesel::sql_types::Integer, diesel::sql_types::T (ST0, ST1, ST2, ST3, ST4, ST5) (ST0, ST1, ST2, ST3, ST4, ST5, ST6) (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7) + (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7, ST8) and $N others = note: required for `users::table` to implement `LoadQuery<'_, _, User>` note: required by a bound in `diesel::RunQueryDsl::load` diff --git a/diesel_compile_tests/tests/fail/returning_clause_requires_selectable_expression.stderr b/diesel_compile_tests/tests/fail/returning_clause_requires_selectable_expression.stderr index b60c0338bcc9..4624f5b6c34b 100644 --- a/diesel_compile_tests/tests/fail/returning_clause_requires_selectable_expression.stderr +++ b/diesel_compile_tests/tests/fail/returning_clause_requires_selectable_expression.stderr @@ -8,13 +8,13 @@ error[E0277]: Cannot select `non_users::columns::noname` from `users::table` | = note: `non_users::columns::noname` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required by a bound in `DeleteStatement::::returning` --> $DIESEL/src/query_builder/delete_statement/mod.rs | @@ -34,13 +34,13 @@ error[E0277]: Cannot select `non_users::columns::noname` from `users::table` | = note: `non_users::columns::noname` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `InsertStatement,), ...>, ..., ...>` to implement `Query` note: required by a bound in `InsertStatement::::returning` --> $DIESEL/src/query_builder/insert_statement/mod.rs @@ -62,13 +62,13 @@ error[E0277]: Cannot select `non_users::columns::noname` from `users::table` | = note: `non_users::columns::noname` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `UpdateStatement, Bound>, ...>` to implement `Query` note: required by a bound in `UpdateStatement::::returning` --> $DIESEL/src/query_builder/update_statement/mod.rs diff --git a/diesel_compile_tests/tests/fail/right_side_of_left_join_requires_nullable.stderr b/diesel_compile_tests/tests/fail/right_side_of_left_join_requires_nullable.stderr index 12adad5c0802..72de63b58cea 100644 --- a/diesel_compile_tests/tests/fail/right_side_of_left_join_requires_nullable.stderr +++ b/diesel_compile_tests/tests/fail/right_side_of_left_join_requires_nullable.stderr @@ -27,13 +27,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -73,13 +73,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -147,13 +147,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -193,13 +193,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -267,13 +267,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -313,13 +313,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -387,13 +387,13 @@ error[E0277]: Cannot select `posts::columns::title` from `pets::table` | = note: `posts::columns::title` is no valid selection for `pets::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression, diesel::expression::grouped::Grouped, NullableExpression>>>>>, LeftOuter>>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -433,13 +433,13 @@ error[E0277]: Cannot select `posts::columns::title` from `pets::table` | = note: `posts::columns::title` is no valid selection for `pets::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression, diesel::expression::grouped::Grouped, NullableExpression>>>>>, LeftOuter>>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -507,13 +507,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | @@ -553,13 +553,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/right_side_of_left_join_requires_nullable.rs:16:9 | diff --git a/diesel_compile_tests/tests/fail/select_for_update_cannot_be_mixed_with_some_clauses.stderr b/diesel_compile_tests/tests/fail/select_for_update_cannot_be_mixed_with_some_clauses.stderr index 1e4cc20e1c39..018314db7d7b 100644 --- a/diesel_compile_tests/tests/fail/select_for_update_cannot_be_mixed_with_some_clauses.stderr +++ b/diesel_compile_tests/tests/fail/select_for_update_cannot_be_mixed_with_some_clauses.stderr @@ -17,11 +17,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::NoGroupByClause, diesel::query_builder::having_clause::NoHavingClause, diesel::query_builder::locking_clause::LockingClause>: DistinctDsl` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` to implement `DistinctDsl` = note: consider using `--verbose` to print the full type name to the console @@ -52,11 +52,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, DistinctClause>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::DistinctClause>: LockingDsl` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, DistinctClause>` to implement `LockingDsl` = note: consider using `--verbose` to print the full type name to the console @@ -87,11 +87,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::NoGroupByClause, diesel::query_builder::having_clause::NoHavingClause, diesel::query_builder::locking_clause::LockingClause>: DistinctOnDsl<_>` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` to implement `DistinctOnDsl<_>` = note: consider using `--verbose` to print the full type name to the console @@ -136,13 +136,13 @@ error[E0277]: Cannot select `columns::id` from `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + >> + >> + > = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` to implement `DistinctOnDsl` note: required by a bound in `diesel::QueryDsl::distinct_on` --> $DIESEL/src/query_dsl/mod.rs @@ -173,11 +173,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, DistinctOnClause>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, DistinctOnClause>: LockingDsl` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, DistinctOnClause>` to implement `LockingDsl` = note: consider using `--verbose` to print the full type name to the console @@ -208,11 +208,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::NoGroupByClause, diesel::query_builder::having_clause::NoHavingClause, diesel::query_builder::locking_clause::LockingClause>: GroupByDsl<_>` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` to implement `GroupByDsl<_>` = note: consider using `--verbose` to print the full type name to the console @@ -243,11 +243,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause>: LockingDsl` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ...>` to implement `LockingDsl` = note: consider using `--verbose` to print the full type name to the console @@ -276,11 +276,11 @@ error[E0277]: the trait bound `BoxedSelectStatement<'_, (diesel::sql_types::Inte | ^^^^^^^^^^ the trait `Table` is not implemented for `BoxedSelectStatement<'_, (diesel::sql_types::Integer,), FromClause, _>`, which is required by `BoxedSelectStatement<'_, (diesel::sql_types::Integer,), FromClause, _>: LockingDsl` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `BoxedSelectStatement<'_, (diesel::sql_types::Integer,), FromClause, _>` to implement `LockingDsl` error[E0277]: the trait bound `SelectStatement, _>>>: LockingDsl` is not satisfied @@ -310,11 +310,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::NoGroupByClause, diesel::query_builder::having_clause::NoHavingClause, diesel::query_builder::locking_clause::LockingClause>: BoxedDsl<'_, _>` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` to implement `BoxedDsl<'_, _>` = note: consider using `--verbose` to print the full type name to the console @@ -369,11 +369,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::NoGroupByClause, diesel::query_builder::having_clause::NoHavingClause, diesel::query_builder::locking_clause::LockingClause>: GroupByDsl<_>` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ..., ...>` to implement `GroupByDsl<_>` = note: consider using `--verbose` to print the full type name to the console @@ -404,11 +404,11 @@ error[E0277]: the trait bound `SelectStatement, diesel: | ^^^^^^^^^^ the trait `Table` is not implemented for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ...>`, which is required by `SelectStatement, diesel::query_builder::select_clause::DefaultSelectClause>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause, diesel::query_builder::having_clause::HavingClause>>>>: LockingDsl` | = help: the following other types implement trait `Table`: - users::table Only Tablesample pg::metadata_lookup::pg_namespace::table pg::metadata_lookup::pg_type::table + users::table = note: required for `SelectStatement, DefaultSelectClause>, ..., ..., ..., ..., ..., ...>` to implement `LockingDsl` = note: consider using `--verbose` to print the full type name to the console diff --git a/diesel_compile_tests/tests/fail/select_requires_column_from_same_table.stderr b/diesel_compile_tests/tests/fail/select_requires_column_from_same_table.stderr index b63f09cc98a6..daf06f9a6eb9 100644 --- a/diesel_compile_tests/tests/fail/select_requires_column_from_same_table.stderr +++ b/diesel_compile_tests/tests/fail/select_requires_column_from_same_table.stderr @@ -8,13 +8,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `SelectStatement>` to implement `SelectDsl` = note: 1 redundant requirement hidden = note: required for `users::table` to implement `SelectDsl` diff --git a/diesel_compile_tests/tests/fail/select_requires_valid_grouping.stderr b/diesel_compile_tests/tests/fail/select_requires_valid_grouping.stderr index 0a100d0ebac8..371583d5f83d 100644 --- a/diesel_compile_tests/tests/fail/select_requires_valid_grouping.stderr +++ b/diesel_compile_tests/tests/fail/select_requires_valid_grouping.stderr @@ -94,12 +94,12 @@ error[E0277]: the trait bound `users::columns::id: IsContainedInGroupBy` is not implemented for `users::columns::id`, which is required by `SelectStatement, diesel::expression::grouped::Grouped, NullableExpression>>>>>, Inner>, diesel::expression::grouped::Grouped, NullableExpression>>>>, diesel::query_builder::select_clause::DefaultSelectClause, diesel::expression::grouped::Grouped, NullableExpression>>>>>, Inner>, diesel::expression::grouped::Grouped, NullableExpression>>>>>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause<(users::columns::id, posts::columns::id)>>: SelectDsl<_>` | = help: the following other types implement trait `IsContainedInGroupBy`: - > - > > + > + > > - > > + > = note: required for `(users::columns::id, posts::columns::id)` to implement `IsContainedInGroupBy` note: required for `comments::columns::id` to implement `ValidGrouping<(users::columns::id, posts::columns::id)>` --> tests/fail/select_requires_valid_grouping.rs:23:9 @@ -119,12 +119,12 @@ error[E0277]: the trait bound `posts::columns::id: IsContainedInGroupBy` is not implemented for `posts::columns::id`, which is required by `SelectStatement, diesel::expression::grouped::Grouped, NullableExpression>>>>>, Inner>, diesel::expression::grouped::Grouped, NullableExpression>>>>, diesel::query_builder::select_clause::DefaultSelectClause, diesel::expression::grouped::Grouped, NullableExpression>>>>>, Inner>, diesel::expression::grouped::Grouped, NullableExpression>>>>>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause<(users::columns::id, posts::columns::id)>>: SelectDsl<_>` | = help: the following other types implement trait `IsContainedInGroupBy`: - > - > > + > + > > - > > + > = note: required for `(posts::columns::id,)` to implement `IsContainedInGroupBy` = note: 1 redundant requirement hidden = note: required for `(users::columns::id, posts::columns::id)` to implement `IsContainedInGroupBy` diff --git a/diesel_compile_tests/tests/fail/selectable.stderr b/diesel_compile_tests/tests/fail/selectable.stderr index 7b7e9cd840d3..3bc146064f8b 100644 --- a/diesel_compile_tests/tests/fail/selectable.stderr +++ b/diesel_compile_tests/tests/fail/selectable.stderr @@ -54,13 +54,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::id` to implement `SelectableExpression>` --> tests/fail/selectable.rs:14:9 | @@ -79,13 +79,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/selectable.rs:15:9 | @@ -140,13 +140,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::id` to implement `SelectableExpression>` --> tests/fail/selectable.rs:14:9 | @@ -178,13 +178,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> note: required for `posts::columns::title` to implement `SelectableExpression>` --> tests/fail/selectable.rs:15:9 | @@ -213,9 +213,9 @@ error[E0277]: the trait bound `posts::columns::id: IsContainedInGroupBy` is not implemented for `posts::columns::id`, which is required by `SelectStatement, diesel::expression::grouped::Grouped, NullableExpression>>>>, diesel::query_builder::select_clause::DefaultSelectClause, diesel::expression::grouped::Grouped, NullableExpression>>>>>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause>: SelectDsl<_>` | = help: the following other types implement trait `IsContainedInGroupBy`: - > - > > + > + > note: required for `users::columns::id` to implement `ValidGrouping` --> tests/fail/selectable.rs:7:9 | @@ -233,9 +233,9 @@ error[E0277]: the trait bound `posts::columns::id: IsContainedInGroupBy` is not implemented for `posts::columns::id`, which is required by `SelectStatement, diesel::expression::grouped::Grouped, NullableExpression>>>>, diesel::query_builder::select_clause::DefaultSelectClause, diesel::expression::grouped::Grouped, NullableExpression>>>>>, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::NoWhereClause, diesel::query_builder::order_clause::NoOrderClause, LimitOffsetClause, diesel::query_builder::group_by_clause::GroupByClause>: SelectDsl<_>` | = help: the following other types implement trait `IsContainedInGroupBy`: - > - > > + > + > note: required for `users::columns::name` to implement `ValidGrouping` --> tests/fail/selectable.rs:8:9 | @@ -253,8 +253,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::No: MixedAggreg | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::No`, which is required by `SelectStatement, diesel::expression::grouped::Grouped, NullableExpression>>>>>: SelectDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `(users::columns::name, diesel::expression::count::count_utils::count)` to implement `ValidGrouping<()>` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `ValidGrouping<()>` @@ -271,13 +271,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -302,13 +302,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -363,13 +363,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -396,13 +396,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -461,13 +461,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -492,13 +492,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -553,13 +553,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -586,13 +586,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -651,13 +651,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -680,13 +680,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -737,13 +737,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -770,13 +770,13 @@ error[E0277]: Cannot select `posts::columns::title` from `users::table` | = note: `posts::columns::title` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::title)` to implement `SelectableExpression` = note: 2 redundant requirements hidden = note: required for `diesel::expression::select_by::SelectBy` to implement `SelectableExpression` @@ -859,14 +859,14 @@ error[E0277]: the trait bound `diesel::expression::select_by::SelectBy: | required by a bound introduced by this call | = help: the following other types implement trait `SingleValue`: - Bool - TinyInt - diesel::sql_types::SmallInt - diesel::sql_types::Integer + Array BigInt - diesel::sql_types::Float - diesel::sql_types::Double - diesel::sql_types::Numeric + Bool + CChar + Cidr + Citext + Datetime + Inet and $N others = note: required for `diesel::expression::select_by::SelectBy` to implement `load_dsl::private::CompatibleType<(i32, std::string::String), _>` = note: required for `SelectStatement, SelectClause>>` to implement `LoadQuery<'_, _, (i32, std::string::String)>` @@ -889,14 +889,14 @@ error[E0277]: the trait bound `(i32, std::string::String): diesel::Queryable`: - <(std::collections::Bound, std::collections::Bound) as diesel::Queryable, Pg>> - <(T0,) as diesel::Queryable, Pg>> - <(T0,) as diesel::Queryable<(ST0,), __DB>> - <(T0, T1) as diesel::Queryable, Pg>> <(T0, T1) as diesel::Queryable<(ST0, ST1), __DB>> - <(T0, T1, T2) as diesel::Queryable, Pg>> + <(T0, T1) as diesel::Queryable, Pg>> <(T0, T1, T2) as diesel::Queryable<(ST0, ST1, ST2), __DB>> + <(T0, T1, T2) as diesel::Queryable, Pg>> + <(T0, T1, T2, T3) as diesel::Queryable<(ST0, ST1, ST2, ST3), __DB>> <(T0, T1, T2, T3) as diesel::Queryable, Pg>> + <(T0, T1, T2, T3, T4) as diesel::Queryable<(ST0, ST1, ST2, ST3, ST4), __DB>> + <(T0, T1, T2, T3, T4) as diesel::Queryable, Pg>> and $N others = note: required for `(i32, std::string::String)` to implement `FromSqlRow, _>` = note: required for `diesel::expression::select_by::SelectBy` to implement `load_dsl::private::CompatibleType<(i32, std::string::String), _>` @@ -920,14 +920,14 @@ error[E0277]: the trait bound `diesel::expression::select_by::SelectBy: | required by a bound introduced by this call | = help: the following other types implement trait `SingleValue`: - Bool - TinyInt - diesel::sql_types::SmallInt - diesel::sql_types::Integer + Array BigInt - diesel::sql_types::Float - diesel::sql_types::Double - diesel::sql_types::Numeric + Bool + CChar + Cidr + Citext + Datetime + Inet and $N others = note: required for `diesel::expression::select_by::SelectBy` to implement `load_dsl::private::CompatibleType<(i32, std::string::String), _>` = note: required for `BoxedSelectStatement<'_, diesel::expression::select_by::SelectBy, FromClause, _>` to implement `LoadQuery<'_, _, (i32, std::string::String)>` @@ -949,14 +949,14 @@ error[E0277]: the trait bound `(i32, std::string::String): diesel::Queryable`: - <(std::collections::Bound, std::collections::Bound) as diesel::Queryable, Pg>> - <(T0,) as diesel::Queryable, Pg>> - <(T0,) as diesel::Queryable<(ST0,), __DB>> - <(T0, T1) as diesel::Queryable, Pg>> <(T0, T1) as diesel::Queryable<(ST0, ST1), __DB>> - <(T0, T1, T2) as diesel::Queryable, Pg>> + <(T0, T1) as diesel::Queryable, Pg>> <(T0, T1, T2) as diesel::Queryable<(ST0, ST1, ST2), __DB>> + <(T0, T1, T2) as diesel::Queryable, Pg>> + <(T0, T1, T2, T3) as diesel::Queryable<(ST0, ST1, ST2, ST3), __DB>> <(T0, T1, T2, T3) as diesel::Queryable, Pg>> + <(T0, T1, T2, T3, T4) as diesel::Queryable<(ST0, ST1, ST2, ST3, ST4), __DB>> + <(T0, T1, T2, T3, T4) as diesel::Queryable, Pg>> and $N others = note: required for `(i32, std::string::String)` to implement `FromSqlRow, _>` = note: required for `diesel::expression::select_by::SelectBy` to implement `load_dsl::private::CompatibleType<(i32, std::string::String), _>` @@ -983,7 +983,6 @@ error[E0277]: the trait bound `(diesel::expression::select_by::SelectBy = note: consider using `#[derive(Selectable)]` + `#[diesel(check_for_backend(_))]` on your struct `((i32, std::string::String), std::string::String)` and in your query `.select(((i32, std::string::String), std::string::String)::as_select())` to get a better error message = help: the following other types implement trait `load_dsl::private::CompatibleType`: - (ST0,) (ST0, ST1) (ST0, ST1, ST2) (ST0, ST1, ST2, ST3) @@ -991,6 +990,7 @@ error[E0277]: the trait bound `(diesel::expression::select_by::SelectBy (ST0, ST1, ST2, ST3, ST4, ST5) (ST0, ST1, ST2, ST3, ST4, ST5, ST6) (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7) + (ST0, ST1, ST2, ST3, ST4, ST5, ST6, ST7, ST8) and $N others = note: required for `SelectStatement, SelectClause<(SelectBy, title)>>` to implement `LoadQuery<'_, _, ((i32, std::string::String), std::string::String)>` note: required by a bound in `diesel::RunQueryDsl::load` @@ -1012,14 +1012,14 @@ error[E0277]: the trait bound `diesel::expression::select_by::SelectBy: | required by a bound introduced by this call | = help: the following other types implement trait `SingleValue`: - Bool - TinyInt - diesel::sql_types::SmallInt - diesel::sql_types::Integer + Array BigInt - diesel::sql_types::Float - diesel::sql_types::Double - diesel::sql_types::Numeric + Bool + CChar + Cidr + Citext + Datetime + Inet and $N others = note: required for `diesel::expression::select_by::SelectBy` to implement `load_dsl::private::CompatibleType<(i32, std::string::String, i32), _>` = note: required for `InsertStatement>, table>, Insert, ...>` to implement `LoadQuery<'_, _, (i32, std::string::String, i32)>` @@ -1042,14 +1042,14 @@ error[E0277]: the trait bound `(i32, std::string::String, i32): diesel::Queryabl | required by a bound introduced by this call | = help: the following other types implement trait `diesel::Queryable`: - <(std::collections::Bound, std::collections::Bound) as diesel::Queryable, Pg>> - <(T0,) as diesel::Queryable, Pg>> - <(T0,) as diesel::Queryable<(ST0,), __DB>> - <(T0, T1) as diesel::Queryable, Pg>> <(T0, T1) as diesel::Queryable<(ST0, ST1), __DB>> - <(T0, T1, T2) as diesel::Queryable, Pg>> + <(T0, T1) as diesel::Queryable, Pg>> <(T0, T1, T2) as diesel::Queryable<(ST0, ST1, ST2), __DB>> + <(T0, T1, T2) as diesel::Queryable, Pg>> + <(T0, T1, T2, T3) as diesel::Queryable<(ST0, ST1, ST2, ST3), __DB>> <(T0, T1, T2, T3) as diesel::Queryable, Pg>> + <(T0, T1, T2, T3, T4) as diesel::Queryable<(ST0, ST1, ST2, ST3, ST4), __DB>> + <(T0, T1, T2, T3, T4) as diesel::Queryable, Pg>> and $N others = note: required for `(i32, std::string::String, i32)` to implement `FromSqlRow, _>` = note: required for `diesel::expression::select_by::SelectBy` to implement `load_dsl::private::CompatibleType<(i32, std::string::String, i32), _>` diff --git a/diesel_compile_tests/tests/fail/selecting_multiple_columns_requires_all_must_be_from_selectable_table.stderr b/diesel_compile_tests/tests/fail/selecting_multiple_columns_requires_all_must_be_from_selectable_table.stderr index 5b17cb92f965..0feff58cb931 100644 --- a/diesel_compile_tests/tests/fail/selecting_multiple_columns_requires_all_must_be_from_selectable_table.stderr +++ b/diesel_compile_tests/tests/fail/selecting_multiple_columns_requires_all_must_be_from_selectable_table.stderr @@ -6,13 +6,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::user_id)` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl<(posts::columns::id, posts::columns::user_id)>` @@ -24,13 +24,13 @@ error[E0277]: Cannot select `posts::columns::user_id` from `users::table` | = note: `posts::columns::user_id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, posts::columns::user_id)` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl<(posts::columns::id, posts::columns::user_id)>` @@ -59,13 +59,13 @@ error[E0277]: Cannot select `posts::columns::id` from `users::table` | = note: `posts::columns::id` is no valid selection for `users::table` = help: the following other types implement trait `SelectableExpression`: - > - >> - >> - >>> >> >> + >>> >> + > + >> + >> = note: required for `(posts::columns::id, users::columns::name)` to implement `SelectableExpression` = note: required for `SelectStatement>` to implement `SelectDsl<(posts::columns::id, users::columns::name)>` diff --git a/diesel_compile_tests/tests/fail/update_requires_left_side_of_eq_to_be_a_column.stderr b/diesel_compile_tests/tests/fail/update_requires_left_side_of_eq_to_be_a_column.stderr index 3f748b4fba6a..c296b4f687be 100644 --- a/diesel_compile_tests/tests/fail/update_requires_left_side_of_eq_to_be_a_column.stderr +++ b/diesel_compile_tests/tests/fail/update_requires_left_side_of_eq_to_be_a_column.stderr @@ -5,13 +5,13 @@ error[E0277]: the trait bound `diesel::expression::bound::Bound`, which is required by `diesel::expression::operators::Eq, columns::name>: AsChangeset` | = help: the following other types implement trait `Column`: - columns::name columns::id + columns::name pg::metadata_lookup::pg_namespace::columns::nspname pg::metadata_lookup::pg_namespace::columns::oid - pg::metadata_lookup::pg_type::columns::typnamespace + pg::metadata_lookup::pg_type::columns::oid pg::metadata_lookup::pg_type::columns::typarray pg::metadata_lookup::pg_type::columns::typname - pg::metadata_lookup::pg_type::columns::oid + pg::metadata_lookup::pg_type::columns::typnamespace = note: required for `diesel::expression::bound::Bound` to implement `diesel::query_builder::update_statement::changeset::AssignmentTarget` = note: required for `diesel::expression::operators::Eq, columns::name>` to implement `AsChangeset` diff --git a/diesel_compile_tests/tests/fail/update_requires_set.stderr b/diesel_compile_tests/tests/fail/update_requires_set.stderr index 244eb3f9eb25..e6b2a148b0ff 100644 --- a/diesel_compile_tests/tests/fail/update_requires_set.stderr +++ b/diesel_compile_tests/tests/fail/update_requires_set.stderr @@ -9,14 +9,14 @@ error[E0277]: `diesel::query_builder::update_statement::SetNotCalled` is no vali = note: this usually means that the `_` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - > - > - > - as QueryFragment> - as QueryFragment> - as QueryFragment> - >, Tab, QId, STATIC_QUERY_ID> as QueryFragment> - as QueryFragment> + <&'a T as QueryFragment> + <() as QueryFragment> + <(T0, T1) as QueryFragment<__DB>> + <(T0, T1, T2) as QueryFragment<__DB>> + <(T0, T1, T2, T3) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5) as QueryFragment<__DB>> + <(T0, T1, T2, T3, T4, T5, T6) as QueryFragment<__DB>> and $N others = note: required for `UpdateStatement` to implement `QueryFragment<_>` = note: required for `UpdateStatement` to implement `ExecuteDsl<_, _>` diff --git a/diesel_compile_tests/tests/fail/update_statement_does_not_support_returning_methods_on_sqlite.stderr b/diesel_compile_tests/tests/fail/update_statement_does_not_support_returning_methods_on_sqlite.stderr index 0753a6fab741..b36f75ad4250 100644 --- a/diesel_compile_tests/tests/fail/update_statement_does_not_support_returning_methods_on_sqlite.stderr +++ b/diesel_compile_tests/tests/fail/update_statement_does_not_support_returning_methods_on_sqlite.stderr @@ -9,9 +9,9 @@ error[E0277]: `ReturningClause<(columns::id, columns::name)>` is no valid SQL fr = note: this usually means that the `Sqlite` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> as QueryFragment> as QueryFragment> + as QueryFragment> = note: required for `ReturningClause<(columns::id, columns::name)>` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `UpdateStatement>>>, Assign<..., ...>, ...>` to implement `QueryFragment` @@ -38,9 +38,9 @@ error[E0277]: `ReturningClause` is no valid SQL fragment for the = note: this usually means that the `Sqlite` database system does not support this SQL syntax = help: the following other types implement trait `QueryFragment`: - as QueryFragment> as QueryFragment> as QueryFragment> + as QueryFragment> = note: required for `ReturningClause` to implement `QueryFragment` = note: 1 redundant requirement hidden = note: required for `UpdateStatement>>>, Assign<..., ...>, ...>` to implement `QueryFragment` diff --git a/diesel_compile_tests/tests/fail/upsert_with_multiple_values_not_supported_on_sqlite.stderr b/diesel_compile_tests/tests/fail/upsert_with_multiple_values_not_supported_on_sqlite.stderr index 15cfd20a4aa4..71e3190ccaa1 100644 --- a/diesel_compile_tests/tests/fail/upsert_with_multiple_values_not_supported_on_sqlite.stderr +++ b/diesel_compile_tests/tests/fail/upsert_with_multiple_values_not_supported_on_sqlite.stderr @@ -35,8 +35,8 @@ error[E0277]: `BatchInsert`: - >, Tab, QId, HAS_STATIC_QUERY_ID> as QueryFragment> as QueryFragment> + >, Tab, QId, HAS_STATIC_QUERY_ID> as QueryFragment> = note: required for `BatchInsert>, table>>, table, (), false>` to implement `QueryFragment` = note: 3 redundant requirements hidden = note: required for `InsertStatement>, ..., ..., false>, ..., ...>>` to implement `QueryFragment` diff --git a/diesel_compile_tests/tests/fail/valid_grouping_and_boxed_expressions.stderr b/diesel_compile_tests/tests/fail/valid_grouping_and_boxed_expressions.stderr index 57ec0f5f742b..385f830a9e78 100644 --- a/diesel_compile_tests/tests/fail/valid_grouping_and_boxed_expressions.stderr +++ b/diesel_compile_tests/tests/fail/valid_grouping_and_boxed_expressions.stderr @@ -67,8 +67,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::Yes: MixedAggre | ^^^^^^ the trait `MixedAggregates` is not implemented for `diesel::expression::is_aggregate::Yes`, which is required by `SelectStatement>: SelectDsl<_>` | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `(Box>>, Box<...>)` to implement `ValidGrouping<()>` = note: required for `SelectStatement>` to implement `SelectDsl<(Box>>, Box>)>` = note: consider using `--verbose` to print the full type name to the console @@ -82,8 +82,8 @@ error[E0277]: the trait bound `diesel::expression::is_aggregate::Yes: MixedAggre | required by a bound introduced by this call | = help: the following other types implement trait `MixedAggregates`: - > > + > = note: required for `(Box>>, Box<...>)` to implement `ValidGrouping<()>` = note: required for `SelectStatement, SelectClause<(Box<...>, ...)>>` to implement `Query` = note: required for `SelectStatement, SelectClause<(Box<...>, ...)>>` to implement `LoadQuery<'_, _, (Option, i32)>` diff --git a/diesel_tests/tests/expressions/ops.rs b/diesel_tests/tests/expressions/ops.rs index 0510aa233c43..82942c7540c6 100644 --- a/diesel_tests/tests/expressions/ops.rs +++ b/diesel_tests/tests/expressions/ops.rs @@ -22,7 +22,7 @@ fn overflow_returns_an_error_but_does_not_panic() { use crate::schema::users::dsl::*; let connection = &mut connection_with_sean_and_tess_in_users_table(); - let query_result = users.select(id + i32::max_value()).load::(connection); + let query_result = users.select(id + i32::MAX).load::(connection); assert!( query_result.is_err(), "Integer overflow should have returned an error" diff --git a/rust-toolchain b/rust-toolchain index 54227249d1ff..b3a8c61e6a86 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -1 +1 @@ -1.78.0 +1.79.0