ruff/crates/ruff_linter
Steve C dacda0f202
[pylint] Show verbatim constant in magic-value-comparison (PLR2004) (#9694)
## Summary

Tweaks PLR2004 to show the literal source text, rather than the constant
value.

I noticed this when I had a hexadecimal constant, and the linter turned
it into base-10.

Now, if you have `0x300`, it will show `0x300` instead of `768`.

Also, added backticks around the constant in the output message.

## Test Plan

`cargo test`
2024-01-30 00:22:09 -05:00
..
resources [pylint] Show verbatim constant in magic-value-comparison (PLR2004) (#9694) 2024-01-30 00:22:09 -05:00
src [pylint] Show verbatim constant in magic-value-comparison (PLR2004) (#9694) 2024-01-30 00:22:09 -05:00
__init__.py [pylint] (Re-)Implement import-private-name (C2701) (#9553) 2024-01-16 14:03:11 -05:00
Cargo.toml Bump version to v0.1.15 (#9690) 2024-01-29 17:44:05 -05:00