squash (some) warnings

This commit is contained in:
Niko Matsakis 2022-08-05 14:32:12 -04:00
parent 5efda5c21d
commit fa2d24a0be
5 changed files with 6 additions and 12 deletions

View file

@ -345,11 +345,3 @@ impl SalsaField {
!self.has_no_eq_attr
}
}
/// True if this an attribute that salsa permits users to attach to
/// entity/interned fields.
fn is_entity_like_field_attribute(a: &syn::Attribute) -> bool {
FIELD_OPTION_ATTRIBUTES
.iter()
.any(|(fa, _)| a.path.is_ident(fa))
}

View file

@ -370,10 +370,9 @@ fn specify_fn(
item_fn: &syn::ItemFn,
config_ty: &syn::Type,
) -> syn::Result<Option<syn::ImplItemMethod>> {
let specify = match &args.specify {
Some(s) => s,
None => return Ok(None),
};
if args.specify.is_none() {
return Ok(None);
}
// `specify` has the same signature as the original,
// but it takes a value arg and has no return type.

View file

@ -1,5 +1,6 @@
//! Test that a `tracked` fn on a `salsa::input`
//! compiles and executes successfully.
#![allow(warnings)]
#[salsa::jar(db = Db)]
struct Jar(MyInput, tracked_fn);

View file

@ -1,5 +1,6 @@
//! Test that a `tracked` fn on a `salsa::input`
//! compiles and executes successfully.
#![allow(dead_code)]
#[salsa::jar(db = Db)]
struct Jar(MyInput, MyTracked, tracked_fn);

View file

@ -1,5 +1,6 @@
//! Test that a `tracked` fn on a `salsa::input`
//! compiles and executes successfully.
#![allow(warnings)]
#[salsa::jar(db = Db)]
struct Jar(MyInput, MyTracked, tracked_fn, tracked_fn_extra);