Skip to content

Commit de14a5d

Browse files
author
Jonathan Moore
committed
Update lifetime name
1 parent f222031 commit de14a5d

File tree

1 file changed

+3
-3
lines changed
  • postgres-from-row-derive/src

1 file changed

+3
-3
lines changed

postgres-from-row-derive/src/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -170,21 +170,21 @@ impl FromRowField {
170170

171171
/// Pushes the needed where clause predicates for this field.
172172
///
173-
/// By default this is `T: for<'z> postgres::types::FromSql<'z>`,
173+
/// By default this is `T: for<'__from_row_lifetime> postgres::types::FromSql<'__from_row_lifetime>`,
174174
/// when using `flatten` it's: `T: postgres_from_row::FromRow`
175175
/// and when using either `from` or `try_from` attributes it additionally pushes this bound:
176176
/// `T: std::convert::From<R>`, where `T` is the type specified in the struct and `R` is the
177177
/// type specified in the `[try]_from` attribute.
178178
///
179-
/// Note: 'z is used here to avoid conflicts with common user-specified lifetimes like 'a
179+
/// Note: '__from_row_lifetime is used here to avoid conflicts with common user-specified lifetimes like 'a
180180
fn add_predicates(&self, predicates: &mut Vec<TokenStream2>) -> Result<()> {
181181
let target_ty = &self.target_ty()?;
182182
let ty = &self.ty;
183183

184184
predicates.push(if self.flatten {
185185
quote! (#target_ty: postgres_from_row::FromRow)
186186
} else {
187-
quote! (#target_ty: for<'z> postgres_from_row::tokio_postgres::types::FromSql<'z>)
187+
quote! (#target_ty: for<'__from_row_lifetime> postgres_from_row::tokio_postgres::types::FromSql<'__from_row_lifetime>)
188188
});
189189

190190
if self.from.is_some() {

0 commit comments

Comments
 (0)