这是indexloc提供的服务,不要输入任何密码
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion crates/turborepo-ci/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,10 @@ mod tests {
unsafe { env::set_var(key, val) };
}

assert_eq!(Vendor::infer_inner(), want.as_ref());
assert_eq!(
Vendor::infer_inner().map(|v| v.name),
want.as_ref().map(|v| v.name)
);

if Vendor::get_name() == Some("GitHub Actions") {
if let Some(live_ci) = live_ci {
Expand Down
2 changes: 1 addition & 1 deletion crates/turborepo-ci/src/vendor_behavior.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use chrono::{DateTime, Utc};
pub type GroupPrefixFn = Arc<dyn Fn(DateTime<Utc>) -> String + Send + Sync>;
type GroupPrefixFnFactory = fn(group_name: String) -> GroupPrefixFn;

#[derive(Clone, Debug, PartialEq)]
#[derive(Clone, Debug)]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just because this diff doesn't make it clear. The issue here is that PartialEq on function pointers has nuance. Removing equality implementation since we don't use it.

See https://doc.rust-lang.org/nightly/core/ptr/fn.fn_addr_eq.html for more info

pub struct VendorBehavior {
pub group_prefix: GroupPrefixFnFactory,
pub group_suffix: GroupPrefixFnFactory,
Expand Down
2 changes: 1 addition & 1 deletion crates/turborepo-ci/src/vendors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ pub struct VendorEnvs {
pub(crate) all: Vec<&'static str>,
}

#[derive(Clone, Debug, PartialEq)]
#[derive(Clone, Debug)]
#[allow(dead_code)]
pub struct Vendor {
pub(crate) name: &'static str,
Expand Down
10 changes: 5 additions & 5 deletions crates/turborepo-filewatch/src/fsevent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -562,11 +562,11 @@ unsafe fn callback_impl(
if *r || &path == p {
handle_event = true;
break;
} else if let Some(parent_path) = path.parent() {
if parent_path == p {
handle_event = true;
break;
}
} else if let Some(parent_path) = path.parent()
&& parent_path == p
{
handle_event = true;
break;
}
}
}
Expand Down
1 change: 1 addition & 0 deletions crates/turborepo-wax/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
#![doc(
html_logo_url = "https://raw.githubusercontent.com/olson-sean-k/wax/master/doc/wax.svg?sanitize=true"
)]
#![allow(dead_code)]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doing this instead of fixing the lint since this is a vendored library

#![allow(clippy::all)]
#![deny(
clippy::cast_lossless,
Expand Down
Loading