diff --git a/diesel/src/lib.rs b/diesel/src/lib.rs
index 340b20534923..e2d5e338b6bb 100644
--- a/diesel/src/lib.rs
+++ b/diesel/src/lib.rs
@@ -597,6 +597,4 @@ pub use crate::query_builder::functions::{
};
pub use crate::result::Error::NotFound;
-pub(crate) mod diesel {
- pub(crate) use super::*;
-}
+extern crate self as diesel;
diff --git a/diesel_derives/src/table.rs b/diesel_derives/src/table.rs
index 9d7494191672..db3b1eaa0742 100644
--- a/diesel_derives/src/table.rs
+++ b/diesel_derives/src/table.rs
@@ -168,7 +168,7 @@ pub(crate) fn expand(input: TableDecl) -> TokenStream {
pub const all_columns: (#(#column_names,)*) = (#(#column_names,)*);
#[allow(non_camel_case_types)]
- #[derive(Debug, Clone, Copy, self::diesel::query_builder::QueryId, Default)]
+ #[derive(Debug, Clone, Copy, diesel::query_builder::QueryId, Default)]
/// The actual table struct
///
/// This is the type which provides the base methods of the query
@@ -189,43 +189,43 @@ pub(crate) fn expand(input: TableDecl) -> TokenStream {
pub type SqlType = (#(#column_ty,)*);
/// Helper type for representing a boxed query from this table
- pub type BoxedQuery<'a, DB, ST = SqlType> = self::diesel::internal::table_macro::BoxedSelectStatement<'a, ST, self::diesel::internal::table_macro::FromClause
, DB>;
+ pub type BoxedQuery<'a, DB, ST = SqlType> = diesel::internal::table_macro::BoxedSelectStatement<'a, ST, diesel::internal::table_macro::FromClause, DB>;
- impl self::diesel::QuerySource for table {
- type FromClause = self::diesel::internal::table_macro::StaticQueryFragmentInstance;
- type DefaultSelection = ::AllColumns;
+ impl diesel::QuerySource for table {
+ type FromClause = diesel::internal::table_macro::StaticQueryFragmentInstance;
+ type DefaultSelection = ::AllColumns;
fn from_clause(&self) -> Self::FromClause {
- self::diesel::internal::table_macro::StaticQueryFragmentInstance::new()
+ diesel::internal::table_macro::StaticQueryFragmentInstance::new()
}
fn default_selection(&self) -> Self::DefaultSelection {
- use self::diesel::Table;
+ use diesel::Table;
Self::all_columns()
}
}
- impl self::diesel::query_builder::QueryFragment for table where
- DB: self::diesel::backend::Backend,
- ::Component: self::diesel::query_builder::QueryFragment
+ impl diesel::query_builder::QueryFragment for table where
+ DB: diesel::backend::Backend,
+ ::Component: diesel::query_builder::QueryFragment
{
- fn walk_ast<'b>(&'b self, __diesel_internal_pass: self::diesel::query_builder::AstPass<'_, 'b, DB>) -> self::diesel::result::QueryResult<()> {
- ::STATIC_COMPONENT.walk_ast(__diesel_internal_pass)
+ fn walk_ast<'b>(&'b self, __diesel_internal_pass: diesel::query_builder::AstPass<'_, 'b, DB>) -> diesel::result::QueryResult<()> {
+ ::STATIC_COMPONENT.walk_ast(__diesel_internal_pass)
}
}
#static_query_fragment_impl_for_table
- impl self::diesel::query_builder::AsQuery for table {
+ impl diesel::query_builder::AsQuery for table {
type SqlType = SqlType;
- type Query = self::diesel::internal::table_macro::SelectStatement>;
+ type Query = diesel::internal::table_macro::SelectStatement>;
fn as_query(self) -> Self::Query {
- self::diesel::internal::table_macro::SelectStatement::simple(self)
+ diesel::internal::table_macro::SelectStatement::simple(self)
}
}
- impl self::diesel::Table for table {
+ impl diesel::Table for table {
type PrimaryKey = #primary_key;
type AllColumns = (#(#column_names,)*);
@@ -238,7 +238,7 @@ pub(crate) fn expand(input: TableDecl) -> TokenStream {
}
}
- impl self::diesel::associations::HasTable for table {
+ impl diesel::associations::HasTable for table {
type Table = Self;
fn table() -> Self::Table {
@@ -246,143 +246,143 @@ pub(crate) fn expand(input: TableDecl) -> TokenStream {
}
}
- impl self::diesel::query_builder::IntoUpdateTarget for table {
- type WhereClause = <::Query as self::diesel::query_builder::IntoUpdateTarget>::WhereClause;
+ impl diesel::query_builder::IntoUpdateTarget for table {
+ type WhereClause = <::Query as diesel::query_builder::IntoUpdateTarget>::WhereClause;
- fn into_update_target(self) -> self::diesel::query_builder::UpdateTarget {
- use self::diesel::query_builder::AsQuery;
- let q: self::diesel::internal::table_macro::SelectStatement> = self.as_query();
+ fn into_update_target(self) -> diesel::query_builder::UpdateTarget {
+ use diesel::query_builder::AsQuery;
+ let q: diesel::internal::table_macro::SelectStatement> = self.as_query();
q.into_update_target()
}
}
- impl self::diesel::query_source::AppearsInFromClause for table {
- type Count = self::diesel::query_source::Once;
+ impl diesel::query_source::AppearsInFromClause for table {
+ type Count = diesel::query_source::Once;
}
// impl> AppearsInFromClause for Alias
- impl self::diesel::internal::table_macro::AliasAppearsInFromClause for table
- where S: self::diesel::query_source::AliasSource,
+ impl diesel::internal::table_macro::AliasAppearsInFromClause for table
+ where S: diesel::query_source::AliasSource,
{
- type Count = self::diesel::query_source::Never;
+ type Count = diesel::query_source::Never;
}
// impl, S2: AliasSource> AppearsInFromClause> for Alias
// Those are specified by the `alias!` macro, but this impl will allow it to implement this trait even in downstream
// crates from the schema
- impl self::diesel::internal::table_macro::AliasAliasAppearsInFromClause for table
- where S1: self::diesel::query_source::AliasSource,
- S2: self::diesel::query_source::AliasSource,
- S1: self::diesel::internal::table_macro::AliasAliasAppearsInFromClauseSameTable,
+ impl diesel::internal::table_macro::AliasAliasAppearsInFromClause for table
+ where S1: diesel::query_source::AliasSource,
+ S2: diesel::query_source::AliasSource,
+ S1: diesel::internal::table_macro::AliasAliasAppearsInFromClauseSameTable,
{
- type Count = >::Count;
+ type Count = >::Count;
}
- impl self::diesel::query_source::AppearsInFromClause> for table
- where S: self::diesel::query_source::AliasSource,
+ impl diesel::query_source::AppearsInFromClause> for table
+ where S: diesel::query_source::AliasSource,
{
- type Count = self::diesel::query_source::Never;
+ type Count = diesel::query_source::Never;
}
- impl self::diesel::internal::table_macro::FieldAliasMapperAssociatedTypesDisjointnessTrick for table
+ impl diesel::internal::table_macro::FieldAliasMapperAssociatedTypesDisjointnessTrick for table
where
- S: self::diesel::query_source::AliasSource + ::std::clone::Clone,
- C: self::diesel::query_source::Column,
+ S: diesel::query_source::AliasSource + ::std::clone::Clone,
+ C: diesel::query_source::Column,
{
- type Out = self::diesel::query_source::AliasedField;
+ type Out = diesel::query_source::AliasedField;
- fn map(__diesel_internal_column: C, __diesel_internal_alias: &self::diesel::query_source::Alias) -> Self::Out {
+ fn map(__diesel_internal_column: C, __diesel_internal_alias: &diesel::query_source::Alias) -> Self::Out {
__diesel_internal_alias.field(__diesel_internal_column)
}
}
- impl self::diesel::query_source::AppearsInFromClause for self::diesel::internal::table_macro::NoFromClause {
- type Count = self::diesel::query_source::Never;
+ impl diesel::query_source::AppearsInFromClause for diesel::internal::table_macro::NoFromClause {
+ type Count = diesel::query_source::Never;
}
- impl self::diesel::JoinTo> for table where
- self::diesel::internal::table_macro::Join: self::diesel::JoinTo,
- Left: self::diesel::query_source::QuerySource,
+ impl diesel::JoinTo> for table where
+ diesel::internal::table_macro::Join: diesel::JoinTo,
+ Left: diesel::query_source::QuerySource,
Right: diesel::query_source::QuerySource,
{
- type FromClause = self::diesel::internal::table_macro::Join;
- type OnClause = as self::diesel::JoinTo>::OnClause;
+ type FromClause = diesel::internal::table_macro::Join;
+ type OnClause = as diesel::JoinTo>::OnClause;
- fn join_target(__diesel_internal_rhs: self::diesel::internal::table_macro::Join) -> (Self::FromClause, Self::OnClause) {
- let (_, __diesel_internal_on_clause) = self::diesel::internal::table_macro::Join::join_target(table);
+ fn join_target(__diesel_internal_rhs: diesel::internal::table_macro::Join) -> (Self::FromClause, Self::OnClause) {
+ let (_, __diesel_internal_on_clause) = diesel::internal::table_macro::Join::join_target(table);
(__diesel_internal_rhs, __diesel_internal_on_clause)
}
}
- impl self::diesel::JoinTo> for table where
- self::diesel::internal::table_macro::JoinOn: self::diesel::JoinTo,
+ impl diesel::JoinTo> for table where
+ diesel::internal::table_macro::JoinOn: diesel::JoinTo,
{
- type FromClause = self::diesel::internal::table_macro::JoinOn;
- type OnClause = as self::diesel::JoinTo>::OnClause;
+ type FromClause = diesel::internal::table_macro::JoinOn;
+ type OnClause = as diesel::JoinTo>::OnClause;
- fn join_target(__diesel_internal_rhs: self::diesel::internal::table_macro::JoinOn) -> (Self::FromClause, Self::OnClause) {
- let (_, __diesel_internal_on_clause) = self::diesel::internal::table_macro::JoinOn::join_target(table);
+ fn join_target(__diesel_internal_rhs: diesel::internal::table_macro::JoinOn) -> (Self::FromClause, Self::OnClause) {
+ let (_, __diesel_internal_on_clause) = diesel::internal::table_macro::JoinOn::join_target(table);
(__diesel_internal_rhs, __diesel_internal_on_clause)
}
}
- impl self::diesel::JoinTo, S, D, W, O, L, Of, G>> for table where
- self::diesel::internal::table_macro::SelectStatement, S, D, W, O, L, Of, G>: self::diesel::JoinTo,
- F: self::diesel::query_source::QuerySource
+ impl diesel::JoinTo, S, D, W, O, L, Of, G>> for table where
+ diesel::internal::table_macro::SelectStatement, S, D, W, O, L, Of, G>: diesel::JoinTo,
+ F: diesel::query_source::QuerySource
{
- type FromClause = self::diesel::internal::table_macro::SelectStatement, S, D, W, O, L, Of, G>;
- type OnClause = , S, D, W, O, L, Of, G> as self::diesel::JoinTo>::OnClause;
+ type FromClause = diesel::internal::table_macro::SelectStatement, S, D, W, O, L, Of, G>;
+ type OnClause = , S, D, W, O, L, Of, G> as diesel::JoinTo>::OnClause;
- fn join_target(__diesel_internal_rhs: self::diesel::internal::table_macro::SelectStatement, S, D, W, O, L, Of, G>) -> (Self::FromClause, Self::OnClause) {
- let (_, __diesel_internal_on_clause) = self::diesel::internal::table_macro::SelectStatement::join_target(table);
+ fn join_target(__diesel_internal_rhs: diesel::internal::table_macro::SelectStatement, S, D, W, O, L, Of, G>) -> (Self::FromClause, Self::OnClause) {
+ let (_, __diesel_internal_on_clause) = diesel::internal::table_macro::SelectStatement::join_target(table);
(__diesel_internal_rhs, __diesel_internal_on_clause)
}
}
- impl<'a, QS, ST, DB> self::diesel::JoinTo, ST, DB>> for table where
- self::diesel::internal::table_macro::BoxedSelectStatement<'a, self::diesel::internal::table_macro::FromClause, ST, DB>: self::diesel::JoinTo,
- QS: self::diesel::query_source::QuerySource,
+ impl<'a, QS, ST, DB> diesel::JoinTo, ST, DB>> for table where
+ diesel::internal::table_macro::BoxedSelectStatement<'a, diesel::internal::table_macro::FromClause, ST, DB>: diesel::JoinTo,
+ QS: diesel::query_source::QuerySource,
{
- type FromClause = self::diesel::internal::table_macro::BoxedSelectStatement<'a, self::diesel::internal::table_macro::FromClause, ST, DB>;
- type OnClause = , ST, DB> as self::diesel::JoinTo>::OnClause;
- fn join_target(__diesel_internal_rhs: self::diesel::internal::table_macro::BoxedSelectStatement<'a, self::diesel::internal::table_macro::FromClause, ST, DB>) -> (Self::FromClause, Self::OnClause) {
- let (_, __diesel_internal_on_clause) = self::diesel::internal::table_macro::BoxedSelectStatement::join_target(table);
+ type FromClause = diesel::internal::table_macro::BoxedSelectStatement<'a, diesel::internal::table_macro::FromClause, ST, DB>;
+ type OnClause = , ST, DB> as diesel::JoinTo>::OnClause;
+ fn join_target(__diesel_internal_rhs: diesel::internal::table_macro::BoxedSelectStatement<'a, diesel::internal::table_macro::FromClause, ST, DB>) -> (Self::FromClause, Self::OnClause) {
+ let (_, __diesel_internal_on_clause) = diesel::internal::table_macro::BoxedSelectStatement::join_target(table);
(__diesel_internal_rhs, __diesel_internal_on_clause)
}
}
- impl self::diesel::JoinTo> for table
+ impl diesel::JoinTo> for table
where
- self::diesel::query_source::Alias: self::diesel::JoinTo,
+ diesel::query_source::Alias: diesel::JoinTo,
{
- type FromClause = self::diesel::query_source::Alias;
- type OnClause = as self::diesel::JoinTo>::OnClause;
+ type FromClause = diesel::query_source::Alias;
+ type OnClause = as diesel::JoinTo>::OnClause;
- fn join_target(__diesel_internal_rhs: self::diesel::query_source::Alias) -> (Self::FromClause, Self::OnClause) {
- let (_, __diesel_internal_on_clause) = self::diesel::query_source::Alias::::join_target(table);
+ fn join_target(__diesel_internal_rhs: diesel::query_source::Alias) -> (Self::FromClause, Self::OnClause) {
+ let (_, __diesel_internal_on_clause) = diesel::query_source::Alias::::join_target(table);
(__diesel_internal_rhs, __diesel_internal_on_clause)
}
}
// This impl should be able to live in Diesel,
// but Rust tries to recurse for no reason
- impl self::diesel::insertable::Insertable for table
+ impl diesel::insertable::Insertable for table
where
- ::Query: self::diesel::insertable::Insertable,
+ ::Query: diesel::insertable::Insertable,
{
- type Values = <::Query as self::diesel::insertable::Insertable>::Values;
+ type Values = <::Query as diesel::insertable::Insertable>::Values;
fn values(self) -> Self::Values {
- use self::diesel::query_builder::AsQuery;
+ use diesel::query_builder::AsQuery;
self.as_query().values()
}
}
- impl<'a, T> self::diesel::insertable::Insertable for &'a table
+ impl<'a, T> diesel::insertable::Insertable for &'a table
where
- table: self::diesel::insertable::Insertable,
+ table: diesel::insertable::Insertable,
{
- type Values = >::Values;
+ type Values = >::Values;
fn values(self) -> Self::Values {
(*self).values()
@@ -398,34 +398,34 @@ pub(crate) fn expand(input: TableDecl) -> TokenStream {
#(#imports_for_column_module)*
#[allow(non_camel_case_types, dead_code)]
- #[derive(Debug, Clone, Copy, self::diesel::query_builder::QueryId)]
+ #[derive(Debug, Clone, Copy, diesel::query_builder::QueryId)]
/// Represents `table_name.*`, which is sometimes needed for
/// efficient count queries. It cannot be used in place of
/// `all_columns`, and has a `SqlType` of `()` to prevent it
/// being used that way
pub struct star;
- impl<__GB> self::diesel::expression::ValidGrouping<__GB> for star
+ impl<__GB> diesel::expression::ValidGrouping<__GB> for star
where
- (#(#column_names,)*): self::diesel::expression::ValidGrouping<__GB>,
+ (#(#column_names,)*): diesel::expression::ValidGrouping<__GB>,
{
- type IsAggregate = <(#(#column_names,)*) as self::diesel::expression::ValidGrouping<__GB>>::IsAggregate;
+ type IsAggregate = <(#(#column_names,)*) as diesel::expression::ValidGrouping<__GB>>::IsAggregate;
}
- impl self::diesel::Expression for star {
- type SqlType = self::diesel::expression::expression_types::NotSelectable;
+ impl diesel::Expression for star {
+ type SqlType = diesel::expression::expression_types::NotSelectable;
}
- impl self::diesel::query_builder::QueryFragment for star where
- ::FromClause: self::diesel::query_builder::QueryFragment,
+ impl diesel::query_builder::QueryFragment for star where
+ ::FromClause: diesel::query_builder::QueryFragment,
{
#[allow(non_snake_case)]
- fn walk_ast<'b>(&'b self, mut __diesel_internal_out: self::diesel::query_builder::AstPass<'_, 'b, DB>) -> self::diesel::result::QueryResult<()>
+ fn walk_ast<'b>(&'b self, mut __diesel_internal_out: diesel::query_builder::AstPass<'_, 'b, DB>) -> diesel::result::QueryResult<()>
{
- use self::diesel::QuerySource;
+ use diesel::QuerySource;
if !__diesel_internal_out.should_skip_from() {
- const FROM_CLAUSE: self::diesel::internal::table_macro::StaticQueryFragmentInstance = self::diesel::internal::table_macro::StaticQueryFragmentInstance::new();
+ const FROM_CLAUSE: diesel::internal::table_macro::StaticQueryFragmentInstance = diesel::internal::table_macro::StaticQueryFragmentInstance::new();
FROM_CLAUSE.walk_ast(__diesel_internal_out.reborrow())?;
__diesel_internal_out.push_sql(".");
@@ -435,10 +435,10 @@ pub(crate) fn expand(input: TableDecl) -> TokenStream {
}
}
- impl self::diesel::SelectableExpression for star {
+ impl diesel::SelectableExpression for star {
}
- impl self::diesel::AppearsOnTable for star {
+ impl diesel::AppearsOnTable for star {
}
#(#column_defs)*
@@ -481,12 +481,12 @@ fn generate_valid_grouping_for_table_columns(table: &TableDecl) -> Vec for #left_col {
- type Output = self::diesel::expression::is_contained_in_group_by::#right_to_left;
+ impl diesel::expression::IsContainedInGroupBy<#right_col> for #left_col {
+ type Output = diesel::expression::is_contained_in_group_by::#right_to_left;
}
- impl self::diesel::expression::IsContainedInGroupBy<#left_col> for #right_col {
- type Output = self::diesel::expression::is_contained_in_group_by::#left_to_right;
+ impl diesel::expression::IsContainedInGroupBy<#left_col> for #right_col {
+ type Output = diesel::expression::is_contained_in_group_by::#left_to_right;
}
});
}
@@ -605,14 +605,14 @@ fn generate_op_impl(op: &str, tpe: &syn::Ident) -> TokenStream {
quote::quote! {
impl ::std::ops::#op for #tpe
where
- Rhs: self::diesel::expression::AsExpression<
- <<#tpe as self::diesel::Expression>::SqlType as self::diesel::sql_types::ops::#op>::Rhs,
+ Rhs: diesel::expression::AsExpression<
+ <<#tpe as diesel::Expression>::SqlType as diesel::sql_types::ops::#op>::Rhs,
>,
{
- type Output = self::diesel::internal::table_macro::ops::#op;
+ type Output = diesel::internal::table_macro::ops::#op;
fn #fn_name(self, __diesel_internal_rhs: Rhs) -> Self::Output {
- self::diesel::internal::table_macro::ops::#op::new(self, __diesel_internal_rhs.as_expression())
+ diesel::internal::table_macro::ops::#op::new(self, __diesel_internal_rhs.as_expression())
}
}
}
@@ -629,12 +629,12 @@ fn expand_column_def(column_def: &ColumnDef) -> TokenStream {
let backend_specific_column_impl = if cfg!(feature = "postgres") {
Some(quote::quote! {
- impl self::diesel::query_source::AppearsInFromClause>
+ impl diesel::query_source::AppearsInFromClause>
for #column_name
{
- type Count = self::diesel::query_source::Once;
+ type Count = diesel::query_source::Once;
}
- impl self::diesel::SelectableExpression> for #column_name {}
+ impl diesel::SelectableExpression> for #column_name {}
})
} else {
None
@@ -665,22 +665,22 @@ fn expand_column_def(column_def: &ColumnDef) -> TokenStream {
quote::quote_spanned! {span=>
#(#meta)*
#[allow(non_camel_case_types, dead_code)]
- #[derive(Debug, Clone, Copy, self::diesel::query_builder::QueryId, Default)]
+ #[derive(Debug, Clone, Copy, diesel::query_builder::QueryId, Default)]
pub struct #column_name;
- impl self::diesel::expression::Expression for #column_name {
+ impl diesel::expression::Expression for #column_name {
type SqlType = #sql_type;
}
- impl self::diesel::query_builder::QueryFragment for #column_name where
- DB: self::diesel::backend::Backend,
- self::diesel::internal::table_macro::StaticQueryFragmentInstance: self::diesel::query_builder::QueryFragment,
+ impl diesel::query_builder::QueryFragment for #column_name where
+ DB: diesel::backend::Backend,
+ diesel::internal::table_macro::StaticQueryFragmentInstance: diesel::query_builder::QueryFragment,
{
#[allow(non_snake_case)]
- fn walk_ast<'b>(&'b self, mut __diesel_internal_out: self::diesel::query_builder::AstPass<'_, 'b, DB>) -> self::diesel::result::QueryResult<()>
+ fn walk_ast<'b>(&'b self, mut __diesel_internal_out: diesel::query_builder::AstPass<'_, 'b, DB>) -> diesel::result::QueryResult<()>
{
if !__diesel_internal_out.should_skip_from() {
- const FROM_CLAUSE: self::diesel::internal::table_macro::StaticQueryFragmentInstance = self::diesel::internal::table_macro::StaticQueryFragmentInstance::new();
+ const FROM_CLAUSE: diesel::internal::table_macro::StaticQueryFragmentInstance = diesel::internal::table_macro::StaticQueryFragmentInstance::new();
FROM_CLAUSE.walk_ast(__diesel_internal_out.reborrow())?;
__diesel_internal_out.push_sql(".");
@@ -689,80 +689,80 @@ fn expand_column_def(column_def: &ColumnDef) -> TokenStream {
}
}
- impl self::diesel::SelectableExpression for #column_name {
+ impl diesel::SelectableExpression for #column_name {
}
- impl self::diesel::AppearsOnTable for #column_name where
- QS: self::diesel::query_source::AppearsInFromClause,
+ impl diesel::AppearsOnTable for #column_name where
+ QS: diesel::query_source::AppearsInFromClause,
{
}
- impl self::diesel::SelectableExpression<
- self::diesel::internal::table_macro::Join,
+ impl diesel::SelectableExpression<
+ diesel::internal::table_macro::Join,
> for #column_name where
- #column_name: self::diesel::AppearsOnTable>,
- Self: self::diesel::SelectableExpression,
+ #column_name: diesel::AppearsOnTable>,
+ Self: diesel::SelectableExpression,
// If our table is on the right side of this join, only
// `Nullable` can be selected
- Right: self::diesel::query_source::AppearsInFromClause + self::diesel::query_source::QuerySource,
- Left: self::diesel::query_source::QuerySource
+ Right: diesel::query_source::AppearsInFromClause + diesel::query_source::QuerySource,
+ Left: diesel::query_source::QuerySource
{
}
- impl self::diesel::SelectableExpression<
- self::diesel::internal::table_macro::Join,
+ impl diesel::SelectableExpression<
+ diesel::internal::table_macro::Join,
> for #column_name where
- #column_name: self::diesel::AppearsOnTable>,
- Left: self::diesel::query_source::AppearsInFromClause + self::diesel::query_source::QuerySource,
- Right: self::diesel::query_source::AppearsInFromClause + self::diesel::query_source::QuerySource,
- (Left::Count, Right::Count): self::diesel::internal::table_macro::Pick,
- Self: self::diesel::SelectableExpression<
- <(Left::Count, Right::Count) as self::diesel::internal::table_macro::Pick>::Selection,
+ #column_name: diesel::AppearsOnTable>,
+ Left: diesel::query_source::AppearsInFromClause + diesel::query_source::QuerySource,
+ Right: diesel::query_source::AppearsInFromClause + diesel::query_source::QuerySource,
+ (Left::Count, Right::Count): diesel::internal::table_macro::Pick,
+ Self: diesel::SelectableExpression<
+ <(Left::Count, Right::Count) as diesel::internal::table_macro::Pick>::Selection,
>,
{
}
// FIXME: Remove this when overlapping marker traits are stable
- impl self::diesel::SelectableExpression> for #column_name where
- #column_name: self::diesel::SelectableExpression + self::diesel::AppearsOnTable>,
+ impl diesel::SelectableExpression> for #column_name where
+ #column_name: diesel::SelectableExpression + diesel::AppearsOnTable>,
{
}
// FIXME: Remove this when overlapping marker traits are stable
- impl self::diesel::SelectableExpression>> for #column_name where
- From: self::diesel::query_source::QuerySource,
- #column_name: self::diesel::SelectableExpression + self::diesel::AppearsOnTable>>,
+ impl diesel::SelectableExpression>> for #column_name where
+ From: diesel::query_source::QuerySource,
+ #column_name: diesel::SelectableExpression + diesel::AppearsOnTable>>,
{
}
- impl<__GB> self::diesel::expression::ValidGrouping<__GB> for #column_name
- where __GB: self::diesel::expression::IsContainedInGroupBy<#column_name, Output = self::diesel::expression::is_contained_in_group_by::Yes>,
+ impl<__GB> diesel::expression::ValidGrouping<__GB> for #column_name
+ where __GB: diesel::expression::IsContainedInGroupBy<#column_name, Output = diesel::expression::is_contained_in_group_by::Yes>,
{
- type IsAggregate = self::diesel::expression::is_aggregate::Yes;
+ type IsAggregate = diesel::expression::is_aggregate::Yes;
}
- impl self::diesel::expression::ValidGrouping<()> for #column_name {
- type IsAggregate = self::diesel::expression::is_aggregate::No;
+ impl diesel::expression::ValidGrouping<()> for #column_name {
+ type IsAggregate = diesel::expression::is_aggregate::No;
}
- impl self::diesel::expression::IsContainedInGroupBy<#column_name> for #column_name {
- type Output = self::diesel::expression::is_contained_in_group_by::Yes;
+ impl diesel::expression::IsContainedInGroupBy<#column_name> for #column_name {
+ type Output = diesel::expression::is_contained_in_group_by::Yes;
}
- impl self::diesel::query_source::Column for #column_name {
+ impl diesel::query_source::Column for #column_name {
type Table = super::table;
const NAME: &'static str = #sql_name;
}
- impl self::diesel::EqAll for #column_name where
- T: self::diesel::expression::AsExpression<#sql_type>,
- self::diesel::dsl::Eq<#column_name, T::Expression>: self::diesel::Expression,
+ impl diesel::EqAll