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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ mod
*.generated.*
CLAUDE.md
.claude
.idea
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ exclude = ["test_app"]

[package]
name = "cargo_pup"
version = "0.1.5"
version = "0.1.6"
edition = "2024"
description = "A Rust architectural linting tool that integrates with rustc to enforce architectural patterns and boundaries"
license = "Apache-2.0"
Expand All @@ -34,9 +34,9 @@ anyhow = { workspace = true }
tempfile = { workspace = true }
ron = { workspace = true }
cargo_metadata = { workspace = true }
cargo_pup_common = { path = "cargo_pup_common", version = "=0.1.5" }
cargo_pup_lint_impl = { path = "cargo_pup_lint_impl", version = "=0.1.5" }
cargo_pup_lint_config = { path = "cargo_pup_lint_config", version = "=0.1.5" }
cargo_pup_common = { path = "cargo_pup_common", version = "=0.1.6" }
cargo_pup_lint_impl = { path = "cargo_pup_lint_impl", version = "=0.1.6" }
cargo_pup_lint_config = { path = "cargo_pup_lint_config", version = "=0.1.6" }

#
# These bits are just to keep rust rover happy.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ First, add the following to your `Cargo.toml`:

```toml
[dev-dependencies]
cargo_pup_lint_config = "0.1.5"
cargo_pup_lint_config = "0.1.6"
```

## Examples
Expand Down
2 changes: 1 addition & 1 deletion cargo_pup_common/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cargo_pup_common"
version = "0.1.5"
version = "0.1.6"
edition = "2024"
description = "Common utilities and shared components for cargo-pup architectural linting tool"
license = "Apache-2.0"
Expand Down
4 changes: 2 additions & 2 deletions cargo_pup_lint_config/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cargo_pup_lint_config"
version = "0.1.5"
version = "0.1.6"
edition = "2024"
description = "Configuration and rule builder utilities for cargo-pup architectural linting"
license = "Apache-2.0"
Expand All @@ -13,4 +13,4 @@ serde.workspace = true
ron.workspace = true
tempfile.workspace = true
anyhow.workspace = true
cargo_pup_common = { path = "../cargo_pup_common", version = "=0.1.5" }
cargo_pup_common = { path = "../cargo_pup_common", version = "=0.1.6" }
2 changes: 1 addition & 1 deletion cargo_pup_lint_config/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Add this to your `Cargo.toml`:

```toml
[dev-dependencies]
cargo_pup_lint_config = "0.1.5"
cargo_pup_lint_config = "0.1.6"
```

## Example
Expand Down
6 changes: 3 additions & 3 deletions cargo_pup_lint_impl/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cargo_pup_lint_impl"
version = "0.1.5"
version = "0.1.6"
edition = "2024"
description = "Core lint implementations and rustc integration for cargo-pup architectural linting"
license = "Apache-2.0"
Expand All @@ -9,8 +9,8 @@ homepage = "https://github.com/datadog/cargo-pup"
readme = "README.md"

[dependencies]
cargo_pup_lint_config = { path = "../cargo_pup_lint_config", version = "=0.1.5" }
cargo_pup_common = { path = "../cargo_pup_common", version = "=0.1.5" }
cargo_pup_lint_config = { path = "../cargo_pup_lint_config", version = "=0.1.6" }
cargo_pup_common = { path = "../cargo_pup_common", version = "=0.1.6" }
anyhow.workspace = true
regex.workspace = true
serde_json.workspace = true
Expand Down
4 changes: 4 additions & 0 deletions cargo_pup_lint_impl/src/helpers/queries.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ pub fn implements_trait<'tcx>(
|| ty.walk().any(|t| {
if let Some(ty) = t.as_type() {
matches!(ty.kind(), ty::Alias(ty::Projection, _) | ty::Param(_))
} else if let Some(ct) = t.as_const() {
// Const generic parameters (e.g., N in Index<N>) also need
// Analysis mode — Coherence's orphan check panics on them.
matches!(ct.kind(), ty::ConstKind::Param(_))
} else {
false
}
Expand Down
4 changes: 2 additions & 2 deletions test_app/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading