Skip to content

fix: remove unused dat macro imports#171

Open
seriouscoderone wants to merge 2 commits intoWebOfTrust:mainfrom
seriouscoderone:fix/remove-unused-dat-imports
Open

fix: remove unused dat macro imports#171
seriouscoderone wants to merge 2 commits intoWebOfTrust:mainfrom
seriouscoderone:fix/remove-unused-dat-imports

Conversation

@seriouscoderone
Copy link

@seriouscoderone seriouscoderone commented Feb 3, 2026

Summary

  • Remove redundant dat macro imports that cause compilation failures
  • Modernize GitHub Actions CI workflow
  • The dat! macro is already available crate-wide via #[macro_use] on the data module

Bug Fix

The project currently fails to compile because of unused import warnings treated as errors:

error: unused import: `dat`
 --> src/core/common.rs:1:19
  |
1 | use crate::data::{dat, Value};
  |                   ^^^

Since lib.rs declares #[macro_use] pub mod data;, the dat! macro is automatically available throughout the crate without explicit imports.

CI Improvements

  • Replace deprecated actions-rs/toolchain with dtolnay/rust-toolchain
  • Update actions/checkout to v4
  • Add cargo caching for faster builds
  • Split into parallel jobs (check, audit, wasm)
  • Properly install cargo-audit before running security audit

Files Changed

Bug fix:

  • src/core/common.rs - module and test
  • src/core/creder.rs
  • src/core/pather.rs - test
  • src/core/prefixer.rs - test
  • src/core/sadder.rs - test
  • src/core/saider.rs - module and test
  • src/core/serder.rs
  • src/core/tholder.rs
  • src/data.rs - test

CI:

  • .github/workflows/test.yml

Test plan

  • cargo test passes (832 tests)
  • cargo build succeeds
  • Doc tests pass
  • CI workflow will run on this PR

🤖 Generated with Claude Code

The `dat!` macro is already available crate-wide via `#[macro_use]`
on the data module in lib.rs. These explicit imports are redundant
and cause compilation failures with `#![deny(warnings)]`.

Removes unused imports from:
- src/core/common.rs (module and test)
- src/core/creder.rs
- src/core/pather.rs (test)
- src/core/prefixer.rs (test)
- src/core/sadder.rs (test)
- src/core/saider.rs (module and test)
- src/core/serder.rs
- src/core/tholder.rs
- src/data.rs (test)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Replace deprecated actions-rs/toolchain with dtolnay/rust-toolchain
- Update actions/checkout to v4
- Add cargo caching for faster builds
- Split into parallel jobs (check, audit, wasm)
- Remove cargo-outdated (too strict for contributions)
- Remove tarpaulin (can be added later with proper setup)
- Install cargo-audit before running audit

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@seriouscoderone seriouscoderone force-pushed the fix/remove-unused-dat-imports branch from 7eaab70 to ec369d4 Compare February 3, 2026 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant