Skip to content

Commit

Permalink
[fix] fixes some compilertests due to renaming of an associated type.
Browse files Browse the repository at this point in the history
  • Loading branch information
coderPaddyS committed Jun 20, 2024
1 parent f1ffc68 commit bca7e68
Show file tree
Hide file tree
Showing 7 changed files with 37 additions and 37 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ error[E0599]: the method `load` exists for struct `CopyToQuery<table, CopyToOpti
::: $DIESEL/src/pg/query_builder/copy/copy_to.rs
|
| pub struct CopyToQuery<T, O> {
| ---------------------------- doesn't satisfy `_: RunQueryDsl<_>` or `_: Table`
| ---------------------------- doesn't satisfy `_: RunQueryDsl<_>` or `_: View`
|
= note: the following trait bounds were not satisfied:
`CopyToQuery<users::table, pg::query_builder::copy::copy_to::CopyToOptions>: Table`
Expand Down
4 changes: 2 additions & 2 deletions diesel_compile_tests/tests/fail/derive/aliases.stderr
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
error[E0271]: type mismatch resolving `<id as Column>::Table == table`
error[E0271]: type mismatch resolving `<id as Column>::Source == table`
--> tests/fail/derive/aliases.rs:36:22
|
36 | user_alias.field(posts::id);
| ----- ^^^^^^^^^ type mismatch resolving `<id as Column>::Table == table`
| ----- ^^^^^^^^^ type mismatch resolving `<id as Column>::Source == table`
| |
| required by a bound introduced by this call
|
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
error[E0271]: type mismatch resolving `<id as Column>::Table == table`
error[E0271]: type mismatch resolving `<id as Column>::Source == table`
--> tests/fail/insert_cannot_reference_columns_from_other_table.rs:22:18
|
22 | .values(&posts::id.eq(1));
| ------ ^^^^^^^^^^^^^^^ type mismatch resolving `<id as Column>::Table == table`
| ------ ^^^^^^^^^^^^^^^ type mismatch resolving `<id as Column>::Source == table`
| |
| required by a bound introduced by this call
|
Expand Down Expand Up @@ -114,11 +114,11 @@ note: required by a bound in `IncompleteInsertStatement::<T, Op>::values`
= note: consider using `--verbose` to print the full type name to the console
= note: this error originates in the macro `table` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0271]: type mismatch resolving `<id as Column>::Table == table`
error[E0271]: type mismatch resolving `<id as Column>::Source == table`
--> tests/fail/insert_cannot_reference_columns_from_other_table.rs:25:18
|
25 | .values(&(posts::id.eq(1), users::id.eq(2)));
| ------ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch resolving `<id as Column>::Table == table`
| ------ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch resolving `<id as Column>::Source == table`
| |
| required by a bound introduced by this call
|
Expand Down
48 changes: 24 additions & 24 deletions diesel_compile_tests/tests/fail/mysql_on_conflict_tests.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -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<Table>`:
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(T,)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5, T6)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(T,)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5, T6)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
and $N others
note: required by a bound in `diesel::upsert::on_conflict_extension::<impl InsertStatement<T, U, Op, Ret>>::on_conflict`
--> $DIESEL/src/upsert/on_conflict_extension.rs
Expand Down Expand Up @@ -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<Table>`:
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(T,)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5, T6)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(T,)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5, T6)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
and $N others
note: required by a bound in `diesel::upsert::on_conflict_extension::<impl InsertStatement<T, U, Op, Ret>>::on_conflict`
--> $DIESEL/src/upsert/on_conflict_extension.rs
Expand Down Expand Up @@ -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<Table>`:
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(T,)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5, T6)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Table>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(T,)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
<diesel::query_builder::upsert::on_conflict_target::ConflictTarget<(_T, T0, T1, T2, T3, T4, T5, T6)> as diesel::query_builder::upsert::on_conflict_target::OnConflictTarget<<_T as Column>::Source>>
and $N others
note: required by a bound in `diesel::upsert::on_conflict_extension::<impl InsertStatement<T, U, Op, Ret>>::on_conflict`
--> $DIESEL/src/upsert/on_conflict_extension.rs
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
error[E0271]: type mismatch resolving `<id as Column>::Table == table`
error[E0271]: type mismatch resolving `<id as Column>::Source == table`
--> tests/fail/pg_on_conflict_requires_valid_conflict_target.rs:38:22
|
38 | .on_conflict(posts::id);
| ----------- ^^^^^^^^^ type mismatch resolving `<id as Column>::Table == table`
| ----------- ^^^^^^^^^ type mismatch resolving `<id as Column>::Source == table`
| |
| required by a bound introduced by this call
|
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ error[E0599]: the method `execute` exists for struct `IncompleteOnConflict<Inser
::: $DIESEL/src/upsert/on_conflict_extension.rs
|
| pub struct IncompleteOnConflict<Stmt, Target> {
| --------------------------------------------- doesn't satisfy `_: RunQueryDsl<_>` or `_: Table`
| --------------------------------------------- doesn't satisfy `_: RunQueryDsl<_>` or `_: View`
|
= note: consider using `--verbose` to print the full type name to the console
= note: the following trait bounds were not satisfied:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ error[E0599]: the method `execute` exists for struct `IncompleteDoUpdate<InsertS
::: $DIESEL/src/upsert/on_conflict_extension.rs
|
| pub struct IncompleteDoUpdate<Stmt, Target> {
| ------------------------------------------- doesn't satisfy `_: RunQueryDsl<_>` or `_: Table`
| ------------------------------------------- doesn't satisfy `_: RunQueryDsl<_>` or `_: View`
|
= note: consider using `--verbose` to print the full type name to the console
= note: the following trait bounds were not satisfied:
Expand Down Expand Up @@ -84,11 +84,11 @@ note: required for `posts::columns::title` to implement `AppearsOnTable<users::t
= note: associated types for the current `impl` cannot be restricted in `where` clauses
= note: required for `diesel::expression::operators::Eq<users::columns::name, posts::columns::title>` to implement `AsChangeset`

error[E0271]: type mismatch resolving `<title as Column>::Table == table`
error[E0271]: type mismatch resolving `<title as Column>::Source == table`
--> tests/fail/pg_upsert_do_update_requires_valid_update.rs:65:10
|
65 | .set(name.eq(excluded(posts::title)));
| ^^^ type mismatch resolving `<title as Column>::Table == table`
| ^^^ type mismatch resolving `<title as Column>::Source == table`
|
note: expected this to be `posts::table`
--> tests/fail/pg_upsert_do_update_requires_valid_update.rs:16:9
Expand Down

0 comments on commit bca7e68

Please sign in to comment.