Skip to content

Allow clippy public API related complaints #317

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

wprzytula
Copy link
Collaborator

This is fully analogous to scylladb/scylla-rust-driver@15448c4. Pasting the commit message:

Turns out clippy has a terrible and shocking default: it won't make
suggestions that require introducing breaking changes.
This means that e.g. if we introduce a type which has a naming that
clippy would normally complain about, it won't if the type is pub!

  1. Clippy is made check public API, too.
  2. The affected names are fixed.

Pre-review checklist

  • I have split my patch into logically separate commits.
  • All commit messages clearly explain what they change and why.
  • PR description sums up the changes and reasons why they should be introduced.
  • [ ] I have implemented Rust unit tests for the features/changes introduced.
  • [ ] I have enabled appropriate tests in .github/workflows/build.yml in gtest_filter.
  • [ ] I have enabled appropriate tests in .github/workflows/cassandra.yml in gtest_filter.

wprzytula added 3 commits June 6, 2025 18:29
The following name changes were introduced:
1. CassDataTypeInner::UDT -> CassDataTypeInner::Udt
  - rationale: "UDT" is an acronym, and Rust style guide suggests using
    CapitalizedCamelCase for acronyms.
2. UDTDataType -> Udt
  - rationale1: ditto about the prefix;
  - rationale2: "DataType" is redundant, as UDT is a data type by
    definition.

Clippy didn't complain about previous naming, because the lint
`avoid-breaking-exported-api` was implicitly enabled. The next commit
explicitly disables it, so that Clippy will warn about such naming
issues.
The lint `avoid-breaking-exported-api` was implicitly enabled. Therefore,
Clippy didn't complain about bad naming in public API.
As the crate is not exposed to the public, we can disable this lint
without any loss.
The tests are no longer configured in the GitHub workflows, but in
the Makefile. This change updates the PR template to reflect that.
@wprzytula wprzytula mentioned this pull request Jun 6, 2025
4 tasks
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