mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
refactor/polish ~ fix cargo clippy
complaints (allow trivially_copy_pass_by_ref)
This commit is contained in:
parent
b5d541a814
commit
c4a69f2f4e
2 changed files with 3 additions and 2 deletions
|
@ -68,6 +68,7 @@ impl Sieve {
|
||||||
#[allow(dead_code)]
|
#[allow(dead_code)]
|
||||||
#[inline]
|
#[inline]
|
||||||
pub fn primes() -> PrimeSieve {
|
pub fn primes() -> PrimeSieve {
|
||||||
|
#[allow(clippy::trivially_copy_pass_by_ref)]
|
||||||
fn deref(x: &u64) -> u64 {
|
fn deref(x: &u64) -> u64 {
|
||||||
*x
|
*x
|
||||||
}
|
}
|
||||||
|
@ -78,6 +79,7 @@ impl Sieve {
|
||||||
#[allow(dead_code)]
|
#[allow(dead_code)]
|
||||||
#[inline]
|
#[inline]
|
||||||
pub fn odd_primes() -> PrimeSieve {
|
pub fn odd_primes() -> PrimeSieve {
|
||||||
|
#[allow(clippy::trivially_copy_pass_by_ref)]
|
||||||
fn deref(x: &u64) -> u64 {
|
fn deref(x: &u64) -> u64 {
|
||||||
*x
|
*x
|
||||||
}
|
}
|
||||||
|
|
|
@ -84,8 +84,7 @@ fn print_version() {
|
||||||
fn print_usage(opts: &Options) {
|
fn print_usage(opts: &Options) {
|
||||||
let brief = "Run COMMAND, with modified buffering operations for its standard streams\n \
|
let brief = "Run COMMAND, with modified buffering operations for its standard streams\n \
|
||||||
Mandatory arguments to long options are mandatory for short options too.";
|
Mandatory arguments to long options are mandatory for short options too.";
|
||||||
let explanation =
|
let explanation = "If MODE is 'L' the corresponding stream will be line buffered.\n \
|
||||||
"If MODE is 'L' the corresponding stream will be line buffered.\n \
|
|
||||||
This option is invalid with standard input.\n\n \
|
This option is invalid with standard input.\n\n \
|
||||||
If MODE is '0' the corresponding stream will be unbuffered.\n\n \
|
If MODE is '0' the corresponding stream will be unbuffered.\n\n \
|
||||||
Otherwise MODE is a number which may be followed by one of the following:\n\n \
|
Otherwise MODE is a number which may be followed by one of the following:\n\n \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue