314 |
clippy::blocks_in_if_conditions,
|
315 |
clippy::if_same_then_else,
|
316 |
clippy::needless_bool
|
32 |
pub(crate) fn merge(a: ArchiveContents, b: ArchiveContents) -> ArchiveContents {
|
33 |
#[allow(clippy::if_same_then_else)] // Two of the cases return `a`, that's okay
|
34 |
if a == ArchiveContents::Mixed || b == ArchiveContents::Mixed {
|
28 |
) -> Result<(), MergeError> {
|
29 |
#[allow(clippy::if_same_then_else)] // Clippy can't see both [cfg] at once
|
30 |
if contents_type == ArchiveContents::Elf {
|
456 |
#[allow(clippy::if_same_then_else)] // clippy bug doesn't notice the two
|
457 |
// closures below are different.
|
6 |
/// the value permits. Constructs an error message based on `msg` otherwise.
|
7 |
#[allow(clippy::cast_possible_wrap, clippy::cast_possible_truncation, clippy::if_same_then_else)]
|
8 |
pub fn int_to_usize_with_msg<T: Into<i64>>(x: T, msg: &str) -> Result<usize> {
|
146 |
// the other color. Note that the closest_pair cannot contain only fixed colors.
|
147 |
#[allow(clippy::if_same_then_else)]
|
148 |
if result.closest_pair.0 < self.parameters.num_fixed_colors {
|
602 |
/// [`Btor::duplicate()`](struct.Btor.html#method.duplicate).
|
603 |
#[allow(clippy::if_same_then_else)]
|
604 |
pub fn get_matching_bv<R: Borrow<Btor> + Clone>(btor: R, bv: &BV<R>) -> Option<BV<R>> {
|
641 |
/// given `BV` in the new `Btor`.
|
642 |
#[allow(clippy::if_same_then_else)]
|
643 |
pub fn get_bv_by_symbol<R: Borrow<Btor> + Clone>(btor: R, symbol: &str) -> Option<BV<R>> {
|
1730 |
fn target_symbol_kind(target: &str) -> Option<SymbolKind> {
|
1731 |
#[allow(clippy::if_same_then_else)]
|
1732 |
if target.contains("windows-msvc") {
|
44 |
for (ix, line) in lines.iter().enumerate() {
|
45 |
#[allow(clippy::if_same_then_else)]
|
46 |
if line.is_section_start() {
|
250 |
#[allow(clippy::if_same_then_else)]
|
251 |
if trimmed.starts_with("[package]") {
|
192 |
// C.NOP
|
193 |
#[allow(clippy::if_same_then_else)]
|
194 |
if nzimm == 0 {
|
402 |
/// The lower the `HandRankValue` the higher the value of the `HandRank`, unless it's invalid.
|
403 |
#[allow(clippy::if_same_then_else)]
|
404 |
impl Ord for HandRank {
|
301 |
#[allow(clippy::if_same_then_else)] // allows explanation of separate cases
|
302 |
if (a > T::zero() && b > T::zero()) || d < T::zero() {
|
41 |
while let Some(fd) = fditer.next() {
|
42 |
#[allow(clippy::if_same_then_else)]
|
43 |
if fd > max_keep_fd {
|
43 |
fn test_capture(x: u8) -> SpanTrace {
|
44 |
#[allow(clippy::if_same_then_else)]
|
45 |
if x == 42 {
|
199 |
#[allow(clippy::if_same_then_else)] // conditionals get too crazy if combined
|
200 |
if let Some(throttled) = error.cause().downcast_ref::<ThrottledError>() {
|
121 |
#[allow(clippy::if_same_then_else)] // readability
|
122 |
if !enabled {
|
517 |
for byte in &bytes {
|
518 |
#[allow(clippy::if_same_then_else)] // I find it easier to follow this way
|
519 |
if byte.is_ascii_alphabetic() || byte.is_ascii_digit() || *byte == b'_' || *byte == b' ' {
|
297 |
#[allow(clippy::if_same_then_else)] // false positive
|
298 |
fn get_output_format(matches: &ArgMatches) -> OutputFormat {
|
1834 |
OpType::LLoop(children, info) => {
|
1835 |
#[allow(clippy::needless_bool, clippy::if_same_then_else)]
|
1836 |
if !children.is_empty()
|
551 |
serde_json::from_value(value).unwrap();
|
552 |
#[allow(clippy::if_same_then_else)]
|
553 |
if classic_crunchyroll_exception.contains_key("episode/series")
|
727 |
serde_json::from_value(value).unwrap();
|
728 |
#[allow(clippy::if_same_then_else)]
|
729 |
if classic_crunchyroll_exception.contains_key("episode/series")
|
376 |
// "Identical" branches are working towards different semantics
|
377 |
#[allow(clippy::if_same_then_else)]
|
378 |
if self.level >= target.subscripts.len() {
|
406 |
#[allow(clippy::if_same_then_else)]
|
407 |
if checked_extension && !loaded_hash_map.contains_key(&name) {
|
568 |
#[allow(clippy::if_same_then_else)]
|
569 |
for vec_file_entry in self.files_with_identical_size.values() {
|
313 |
for (name, file_entry) in &self.music_to_check {
|
314 |
#[allow(clippy::if_same_then_else)]
|
315 |
if !loaded_hash_map.contains_key(name) {
|
497 |
for (name, file_entry) in &self.images_to_check {
|
498 |
#[allow(clippy::if_same_then_else)]
|
499 |
if !loaded_hash_map.contains_key(name) {
|
453 |
for (name, file_entry) in &self.videos_to_check {
|
454 |
#[allow(clippy::if_same_then_else)]
|
455 |
if !loaded_hash_map.contains_key(name) {
|
46 |
/// This does not check sender and path of the message, which is likely relevant to you as well.
|
47 |
#[allow(clippy::if_same_then_else)]
|
48 |
fn from_message(m: &Message) -> Option<Self> where Self: Sized + arg::ReadAll {
|
182 |
// The code is more readable this way.
|
183 |
#[allow(clippy::if_same_then_else)]
|
184 |
if adjusted_position_x.abs() <= fmin_bounds
|
6 |
#[allow(clippy::if_same_then_else)]
|
7 |
pub fn encode_qp(mut data: Vec<u8>) -> Vec<u8> {
|
377 |
feature = "cargo-clippy",
|
378 |
allow(if_let_redundant_pattern_matching, if_same_then_else)
|
379 |
)]
|
398 |
feature = "cargo-clippy",
|
399 |
allow(if_let_redundant_pattern_matching, if_same_then_else)
|
400 |
)]
|
7 |
#[cfg(not(feature = "static"))]
|
8 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
9 |
fn infer_static(name: &str) -> bool {
|
169 |
// Render the link line
|
170 |
#[allow(clippy::if_same_then_else)]
|
171 |
if let Some(link_row) = line.link_line {
|
221 |
let conc_ev = graph.events.get(&conc_evid).unwrap();
|
222 |
#[allow(clippy::if_same_then_else)]
|
223 |
let is_indep = if &cur_st == base_st {
|
138 |
#[allow(clippy::if_same_then_else)]
|
139 |
if ret == -1 {
|
80 |
impl Drop for ConsoleScreenBuffer {
|
81 |
#[allow(clippy::if_same_then_else)]
|
82 |
fn drop(&mut self) {
|
84 |
#[allow(clippy::if_same_then_else)]
|
85 |
/// Returns reading_frame, start, end
|
228 |
#[allow(clippy::match_same_arms)]
|
229 |
#[allow(clippy::if_same_then_else)]
|
230 |
pub fn linguist_heuristic(ext: &str, content: &[String]) -> Option<&'static str> {
|
178 |
/// The lower the `HandRankValue` the higher the value of the `HandRank`, unless it's invalid.
|
179 |
#[allow(clippy::if_same_then_else)]
|
180 |
impl Ord for Eval {
|
1495 |
// requirements
|
1496 |
#[allow(clippy::if_same_then_else)]
|
1497 |
impl<'r> std::fmt::Display for RenderNode<'r> {
|
100 |
/// [`glib::idle_add_local`](crate::idle_add_local) instead.
|
101 |
#[allow(clippy::if_same_then_else)]
|
102 |
pub fn invoke_local_with_priority<F>(&self, _priority: Priority, func: F)
|
151 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
152 |
fn needs_update_v2(hakari_package: &PackageMetadata<'_>, link: PackageLink<'_>) -> bool {
|
1492 |
#[allow(clippy::if_same_then_else)] // in this case, having some identical `if` blocks actually improves readability, I think
|
1493 |
fn resolve_function(
|
74 |
#[allow(clippy::needless_bool)]
|
75 |
#[allow(clippy::if_same_then_else)]
|
76 |
let prepend = if cfg!(target_os = "linux") || cfg!(target_os = "macos") {
|
18 |
#[allow(clippy::if_same_then_else)]
|
19 |
fn capitalize_after_mac(word: &str) -> bool {
|
81 |
#[allow(clippy::if_same_then_else)]
|
82 |
pub fn from_word_and_counts(
|
5210 |
#[allow(clippy::if_same_then_else)]
|
5211 |
if !table_and_joins.joins.is_empty() {
|
97 |
#[allow(clippy::if_same_then_else)]
|
98 |
if x.ident == y {
|
150 |
if let Some(Cell::String(value)) = left_trimmed_row.iter().next() {
|
151 |
#[allow(clippy::if_same_then_else)]
|
152 |
if value.starts_with(TITLE_PREFIX) {
|
363 |
#[allow(clippy::if_same_then_else)]
|
364 |
let indentation = if rest.starts_with('\n') || rest.starts_with("\r\n") || rest.is_empty() {
|
157 |
// so like `0x401000`.
|
158 |
#[allow(clippy::if_same_then_else)]
|
159 |
pub fn get_memory_operand_ptr(
|
215 |
// which is *not* `0x401000` in this example.
|
216 |
#[allow(clippy::if_same_then_else)]
|
217 |
pub fn get_memory_operand_xref(
|
129 |
#[inline(always)]
|
130 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
131 |
pub const fn nan_str_is_valid(&self) -> bool {
|
150 |
#[inline(always)]
|
151 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
152 |
pub const fn inf_str_is_valid(&self) -> bool {
|
176 |
#[inline(always)]
|
177 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
178 |
pub const fn infinity_string_is_valid(&self) -> bool {
|
201 |
#[inline(always)]
|
202 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
203 |
pub const fn is_valid(&self) -> bool {
|
238 |
#[inline(always)]
|
239 |
#[allow(clippy::if_same_then_else)]
|
240 |
pub const fn build(&self) -> Result<Options> {
|
733 |
/// Get the error type from the format.
|
734 |
#[allow(clippy::if_same_then_else)]
|
735 |
pub const fn error(&self) -> Error {
|
740 |
#[inline]
|
741 |
#[allow(clippy::if_same_then_else)]
|
742 |
pub const fn is_valid_punctuation(format: u128) -> bool {
|
765 |
#[inline]
|
766 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
767 |
pub const fn is_valid_options_punctuation(format: u128, exponent: u8, decimal_point: u8) -> bool {
|
702 |
/// Compute the interval I = (w−,w]..
|
703 |
#[allow(clippy::comparison_chain, clippy::if_same_then_else)]
|
704 |
pub fn compute_right_closed_directed<F: RawFloat>(float: F, shorter: bool) -> ExtendedFloat80 {
|
226 |
#[inline(always)]
|
227 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
228 |
pub const fn nan_str_is_valid(&self) -> bool {
|
247 |
#[inline(always)]
|
248 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
249 |
pub const fn inf_str_is_valid(&self) -> bool {
|
268 |
#[inline(always)]
|
269 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
270 |
pub const fn is_valid(&self) -> bool {
|
308 |
#[inline(always)]
|
309 |
#[allow(clippy::if_same_then_else)]
|
310 |
pub const fn build(&self) -> Result<Options> {
|
381 |
impl ErrorModeGuard {
|
382 |
#[allow(clippy::if_same_then_else)]
|
383 |
fn new() -> Option<ErrorModeGuard> {
|
84 |
if source.is_registry() {
|
85 |
#[allow(clippy::if_same_then_else)]
|
86 |
if source.is_default_registry() {
|
77 |
#[test]
|
78 |
#[allow(clippy::if_same_then_else)]
|
79 |
fn adjacency_matrix_test() {
|
92 |
#[allow(clippy::if_same_then_else)]
|
93 |
if !valid_north_range.contains(&north) || !valid_east_range.contains(&east) {
|
253 |
#[allow(clippy::if_same_then_else)]
|
254 |
if reached_end_of_line {
|
7 |
#[cfg(feature = "cuda")]
|
8 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
9 |
fn infer_static(name: &str) -> bool {
|
100 |
// x y or -x or -3 x or -x y or -3 x y or x° or n° or -x° or -n°
|
101 |
#[allow(clippy::if_same_then_else)]
|
102 |
if is_times_mi(elem) {
|
368 |
.filter(|(target, source)| {
|
369 |
#[allow(clippy::if_same_then_else)]
|
370 |
// Skip generated files. See https://github.com/rust-lang/cargo/issues/7938#issuecomment-593280660
|
40 |
#[allow(clippy::if_same_then_else)]
|
41 |
fn has_leading_timestamp(line: &str) -> bool {
|
390 |
let pos = patch.address();
|
391 |
#[allow(clippy::if_same_then_else)]
|
392 |
let at = if self.buffer.read_byte(pos) == 0x0F && (self.buffer.read_byte(pos + 1) & 0xF0) == 0x80 {
|
287 |
let src2 = src2.into();
|
288 |
#[allow(clippy::if_same_then_else)]
|
289 |
if !matches!(src1, Value::Register(_)) {
|
599 |
if v[i].is_useless() {
|
600 |
#[allow(clippy::if_same_then_else)]
|
601 |
if ip.is_some() && v[ip.unwrap()] == Token::Char(ReservedChar::CloseBracket) {
|
172 |
// The conditions are complex, and it is easier to read if we put them to separate if blocks.
|
173 |
#[allow(clippy::if_same_then_else)]
|
174 |
let is_full_heap = if crate::plan::generational::FULL_NURSERY_GC {
|
113 |
// in different if branches.
|
114 |
#[allow(clippy::if_same_then_else)]
|
115 |
#[allow(clippy::branches_sharing_code)]
|
94 |
// The blocks are not identical, clippy is wrong. Probably it does not recognize the constant type parameter.
|
95 |
#[allow(clippy::if_same_then_else)]
|
96 |
if in_defrag {
|
606 |
#[allow(clippy::needless_bool)]
|
607 |
#[allow(clippy::if_same_then_else)]
|
608 |
fn format(&mut self) -> Vec<Attribute> {
|
1 |
#![allow(clippy::many_single_char_names)]
|
2 |
#![allow(clippy::if_same_then_else)]
|
3 |
#![allow(clippy::neg_cmp_op_on_partial_ord)]
|
152 |
#[allow(clippy::if_same_then_else)]
|
153 |
if is_constant(f, lhs) {
|
36 |
impl ColumnType {
|
37 |
#[allow(clippy::if_same_then_else)]
|
38 |
fn from_bitfield(type_bits: i32) -> io::Result<ColumnType> {
|
65 |
#[allow(clippy::if_same_then_else)] // No idea what Clippy is trying to say here
|
66 |
#[allow(clippy::collapsible_else_if)] // Intentional for clarity
|
5 |
fn infer_static(name: &str) -> bool {
|
6 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
7 |
if env::var(format!("{}_STATIC", name.to_uppercase())).is_ok() {
|
215 |
impl MsgValidator for MsgHeader {
|
216 |
#[allow(clippy::if_same_then_else)]
|
217 |
fn is_valid(&self) -> bool {
|
183 |
/// - `chunk_size`: size of data to be read from the zlib stream.
|
184 |
#[allow(clippy::if_same_then_else)]
|
185 |
pub fn begin_read(&mut self, chunk_size: u64) -> Result<u32> {
|
61 |
/// NOTE: This code is not super pretty on purpose to make it clear that we're covering all of the cases
|
62 |
#[allow(clippy::if_same_then_else)]
|
63 |
#[allow(clippy::branches_sharing_code)]
|
39 |
None => {
|
40 |
#[allow(clippy::if_same_then_else)]
|
41 |
if target.contains("windows") {
|
83 |
if let Some(str_type) = type_ref.as_string() {
|
84 |
#[allow(clippy::if_same_then_else)]
|
85 |
return if matches!(
|
696 |
// COMMA val=( DECIMAL_LITERAL | INTEGER_LITERAL ) { $value = $val.getText(); $type = ValueType.Number; }
|
697 |
#[allow(clippy::if_same_then_else)]
|
698 |
fn parse_number(lex: &mut Lexer<MatcherDefinitionToken>, v: &str) -> anyhow::Result<(String, ValueType, Option<MatchingRule>, Option<Generator>, Option<MatchingReference>)> {
|
729 |
// COMMA val=DECIMAL_LITERAL { $value = $val.getText(); $type = ValueType.Decimal; }
|
730 |
#[allow(clippy::if_same_then_else)]
|
731 |
fn parse_decimal(lex: &mut Lexer<MatcherDefinitionToken>, v: &str) -> anyhow::Result<(String, ValueType, Option<MatchingRule>, Option<Generator>, Option<MatchingReference>)> {
|
12 |
#[cfg(not(feature = "static"))]
|
13 |
#[allow(clippy::if_same_then_else, clippy::needless_bool)]
|
14 |
fn infer_static(name: &str) -> bool {
|
146 |
// the other color. Note that the closest_pair cannot contain only fixed colors.
|
147 |
#[allow(clippy::if_same_then_else)]
|
148 |
if result.closest_pair.0 < self.parameters.num_fixed_colors {
|
1434 |
#[allow(clippy::if_same_then_else)]
|
1435 |
fn decode_number_token(
|
59 |
/// [RFC 8264](https://datatracker.ietf.org/doc/html/rfc8264#section-8)
|
60 |
#[allow(clippy::if_same_then_else)]
|
61 |
fn get_derived_property_value(
|
360 |
// Allow some block when logic requires it.
|
361 |
#[allow(clippy::if_same_then_else)]
|
362 |
if new_value.is_valid() {
|
451 |
// Allow for chained `if let` without complaining
|
452 |
#[allow(clippy::if_same_then_else)]
|
453 |
if VariableNodeType::SvdRegister == self.variable_node_type {
|
701 |
// Allow for chained `if let` without complaining
|
702 |
#[allow(clippy::if_same_then_else)]
|
703 |
if !self.value.is_empty() {
|
601 |
if let Some(relation) = relation_name {
|
602 |
#[allow(clippy::if_same_then_else)]
|
603 |
if ctx.dialect.big_query_quoting() {
|
553 |
/// Resolve Python extension modules that are compliant with the policy.
|
554 |
#[allow(clippy::if_same_then_else)]
|
555 |
pub fn resolve_python_extension_modules<'a>(
|
1307 |
/// Add a Python extension module using an add context.
|
1308 |
#[allow(clippy::if_same_then_else)]
|
1309 |
pub fn add_python_extension_module_with_context(
|
8 |
/// Attempts to convert a `usize` to an `int` without overflow.
|
9 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else, cast_possible_truncation, cast_possible_wrap))]
|
10 |
pub fn usize_to_int(n: usize) -> Result<c_int> {
|
20 |
/// Attempts to convert an `int` to a `usize` without under- or overflow.
|
21 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else, cast_possible_truncation, cast_possible_wrap))]
|
22 |
pub fn int_to_usize(n: c_int) -> Result<usize> {
|
23 |
#[allow(clippy::if_same_then_else)]
|
24 |
pub fn handle_message(
|
658 |
#[allow(clippy::if_same_then_else)]
|
659 |
if last_sequence_for_key <= compaction_state.get_smallest_snapshot() {
|
39 |
#[allow(clippy::needless_bool)]
|
40 |
#[allow(clippy::if_same_then_else)]
|
41 |
fn joins_to(&self, to: &Joiner) -> bool {
|
210 |
// match.
|
211 |
#[allow(clippy::if_same_then_else)]
|
212 |
if provides_pkgname != master_pkgname {
|
36 |
// https://github.com/rust-lang/rust-clippy/issues/7383
|
37 |
#[allow(clippy::if_same_then_else)]
|
38 |
if start == &Bound::Unbounded || end == &Bound::Unbounded {
|
39 |
if let Some(k) = evt.get(0) {
|
40 |
#[allow(clippy::if_same_then_else)]
|
41 |
if *k == KeyEvent::ctrl('E') {
|
910 |
if cmd.is_repeatable_change() {
|
911 |
#[allow(clippy::if_same_then_else)]
|
912 |
if let (Cmd::Replace(..), Cmd::SelfInsert(..)) = (&self.last_cmd, &cmd) {
|
39 |
if let Some(k) = evt.get(0) {
|
40 |
#[allow(clippy::if_same_then_else)]
|
41 |
if *k == KeyEvent::ctrl('E') {
|
910 |
if cmd.is_repeatable_change() {
|
911 |
#[allow(clippy::if_same_then_else)]
|
912 |
if let (Cmd::Replace(..), Cmd::SelfInsert(..)) = (&self.last_cmd, &cmd) {
|
716 |
fn path_equal(p1: &Path, p2: &Path) -> bool {
|
717 |
#[allow(clippy::if_same_then_else)]
|
718 |
if p1.leading_colon.is_some() != p2.leading_colon.is_some() {
|
17 |
#[allow(clippy::if_same_then_else)] // seems to be a false positive by clippy
|
18 |
const UNSAFE_OPTIMISATIONS: bool = if cfg!(test) {
|
692 |
#[allow(unused)]
|
693 |
#[allow(clippy::if_same_then_else)]
|
694 |
unsafe extern "system" fn debug_report_callback(
|
2380 |
#[allow(clippy::if_same_then_else)]
|
2381 |
pub(crate) fn poll_at(&self, cx: &mut Context) -> PollAt {
|
89 |
/// [set_protocol_len]: #method.set_protocol_len
|
90 |
#[allow(clippy::if_same_then_else)]
|
91 |
pub fn check_len(&self) -> Result<()> {
|
309 |
/// [set_total_len]: #method.set_total_len
|
310 |
#[allow(clippy::if_same_then_else)]
|
311 |
pub fn check_len(&self) -> Result<()> {
|
57 |
let curtime = clock::get_time()?;
|
58 |
#[allow(clippy::if_same_then_else)]
|
59 |
let allowed =
|
438 |
#[inline(always)]
|
439 |
#[allow(clippy::if_same_then_else)]
|
440 |
fn count_line_breaks_up_to(bytes: &[u8], max_bytes: usize, max_breaks: usize) -> (usize, usize) {
|
5514 |
#[allow(clippy::if_same_then_else)]
|
5515 |
if !table_and_joins.joins.is_empty() {
|
1086 |
// 1.3.2.1
|
1087 |
#[allow(clippy::if_same_then_else)]
|
1088 |
if property == AT_TYPE
|
155 |
#[inline(always)]
|
156 |
#[allow(clippy::if_same_then_else)]
|
157 |
fn count_breaks_up_to(bytes: &[u8], max_bytes: usize, max_breaks: usize) -> (usize, usize) {
|
115 |
// without being buried in a big boolean expression.
|
116 |
#[allow(clippy::if_same_then_else)]
|
117 |
#[allow(clippy::needless_bool)]
|
166 |
if can_remove {
|
167 |
#[allow(clippy::if_same_then_else)]
|
168 |
if *op == op!("&&") {
|
96 |
// 340.19 MiB/s
|
97 |
#[allow(clippy::if_same_then_else)]
|
98 |
pub fn find_syncmers_anonfn<const N: usize>(
|
135 |
/// Vec<usize> of positions of syncmers (kmers meeting above critera) in the sequence
|
136 |
#[allow(clippy::if_same_then_else)]
|
137 |
pub fn find_syncmers_pos<const N: usize>(
|
210 |
#[allow(clippy::if_same_then_else)]
|
211 |
impl<'syncmer, const N: usize> Iterator for Syncmers<'syncmer, N> {
|
160 |
#[allow(clippy::if_same_then_else)]
|
161 |
fn input_open_name_with_abspath(
|
37 |
#[allow(clippy::if_same_then_else)]
|
38 |
pub(crate) const fn parse(string: &'a str) -> Result<(Self, RangeFrom<usize>), Error> {
|
127 |
impl EncodeSet for UrlEncodeSet {
|
128 |
#[allow(clippy::if_same_then_else)]
|
129 |
fn contains(&self, byte: u8) -> bool {
|
388 |
#[allow(clippy::cognitive_complexity)]
|
389 |
#[allow(clippy::if_same_then_else)]
|
390 |
#[rustfmt::skip]
|
318 |
// `Some(true)` in order to respect the current configuration.
|
319 |
#[allow(clippy::if_same_then_else)]
|
320 |
if self.quote.is_some() {
|
126 |
fn eq(&self, other: &Self) -> bool {
|
127 |
#[allow(clippy::if_same_then_else)]
|
128 |
match (self, other) {
|
83 |
if let Ok(meta_child) = meta_child {
|
84 |
#[allow(clippy::if_same_then_else)]
|
85 |
if meta_child.len() == result.size {
|
151 |
/// This could yield false positives.
|
152 |
#[allow(clippy::if_same_then_else)]
|
153 |
pub fn is_signable_binary_header(data: &[u8]) -> bool {
|
462 |
impl Utf8Parser {
|
463 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
464 |
fn set_char_info(&mut self, b: u8) {
|
324 |
#[allow(clippy::if_same_then_else)]
|
325 |
pub fn set_input<S: AsRef<str>>(&mut self, name: S, value: Tensor) {
|
354 |
// If a punctuation exists in only one, we can't order.
|
355 |
#[allow(clippy::if_same_then_else)]
|
356 |
if this.as_ref().as_str().contains('.') ^ other.as_ref().as_str().contains('.') {
|
847 |
// If a punctuation exists in only one, we can't order.
|
848 |
#[allow(clippy::if_same_then_else)]
|
849 |
if this.as_ref().as_str().contains('.') ^ other.as_ref().as_str().contains('.') {
|
161 |
// https://www.unicode.org/reports/tr46/#Validity_Criteria
|
162 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
163 |
fn validate(label: &str, is_bidi_domain: bool, flags: Flags, errors: &mut Vec<Error>) {
|
194 |
#[allow(clippy::if_same_then_else)]
|
195 |
if matches.get_flag(options::FILE_SYSTEM) {
|
332 |
#[allow(clippy::if_same_then_else)]
|
333 |
pub(crate) fn set_device_irqs(_device: &VfioDevice, irq_sets: &[vfio_irq_set]) -> Result<()> {
|
73 |
#[allow(clippy::if_same_then_else)]
|
74 |
fn insert(&mut self, ent: OverloadedEnt<'a>) -> Result<(), Diagnostic> {
|
351 |
impl<T: Req> VhostUserMsgValidator for VhostUserMsgHeader<T> {
|
352 |
#[allow(clippy::if_same_then_else)]
|
353 |
fn is_valid(&self) -> bool {
|
456 |
impl VhostUserMsgValidator for VhostUserMemory {
|
457 |
#[allow(clippy::if_same_then_else)]
|
458 |
fn is_valid(&self) -> bool {
|
637 |
impl VhostUserMsgValidator for VhostUserVringAddr {
|
638 |
#[allow(clippy::if_same_then_else)]
|
639 |
fn is_valid(&self) -> bool {
|
689 |
impl VhostUserMsgValidator for VhostUserConfig {
|
690 |
#[allow(clippy::if_same_then_else)]
|
691 |
fn is_valid(&self) -> bool {
|
2993 |
#[allow(clippy::if_same_then_else)]
|
2994 |
if !table_and_joins.joins.is_empty() {
|
14 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
15 |
impl PartialOrd for Point {
|
40 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
41 |
impl PartialOrd for Size {
|
66 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
67 |
impl PartialOrd for Geometry {
|
14 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
15 |
impl PartialOrd for Point {
|
40 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
41 |
impl PartialOrd for Size {
|
66 |
#[cfg_attr(feature = "cargo-clippy", allow(if_same_then_else))]
|
67 |
impl PartialOrd for Geometry {
|
51 |
}
|
52 |
#[allow(clippy::if_same_then_else)]
|
53 |
#[allow(clippy::collapsible_if)]
|
469 |
}
|
470 |
#[allow(dead_code, clippy::if_same_then_else)]
|
470 |
#[allow(clippy::if_same_then_else)]
|
471 |
fn unquote(s: String) -> Result<String> {
|
2370 |
#[allow(clippy::if_same_then_else)]
|
2371 |
pub(crate) fn poll_at(&self, cx: &mut Context) -> PollAt {
|
89 |
/// [set_protocol_len]: #method.set_protocol_len
|
90 |
#[allow(clippy::if_same_then_else)]
|
91 |
pub fn check_len(&self) -> Result<()> {
|
309 |
/// [set_total_len]: #method.set_total_len
|
310 |
#[allow(clippy::if_same_then_else)]
|
311 |
pub fn check_len(&self) -> Result<()> {
|
39 |
if let Some(k) = evt.get(0) {
|
40 |
#[allow(clippy::if_same_then_else)]
|
41 |
if *k == KeyEvent::ctrl('E') {
|
910 |
if cmd.is_repeatable_change() {
|
911 |
#[allow(clippy::if_same_then_else)]
|
912 |
if let (Cmd::Replace(..), Cmd::SelfInsert(..)) = (&self.last_cmd, &cmd) {
|
49 |
/// assert_eq!(is_leap_year(dt.year()) as i32, 0)
|
50 |
#[allow(clippy::if_same_then_else)]
|
51 |
pub fn is_leap_year(year: i32) -> bool {
|
37 |
None => {
|
38 |
#[allow(clippy::if_same_then_else)]
|
39 |
if target.contains("windows") {
|
386 |
#[allow(clippy::if_same_then_else)]
|
387 |
#[allow(clippy::needless_bool)]
|
247 |
#[allow(clippy::if_same_then_else)]
|
248 |
if draw_pane_frames && !pane.borderless() {
|
23 |
fn from(event: termwiz::input::MouseEvent) -> Self {
|
24 |
#[allow(clippy::if_same_then_else)]
|
25 |
if event
|
1001 |
}
|
1002 |
#[allow(clippy::if_same_then_else)] // Only necessary because of detailed comment
|
1003 |
let protective_drop = if self.is_copy {
|
3 |
clippy::diverging_sub_expression,
|
4 |
clippy::if_same_then_else,
|
5 |
clippy::ifs_same_cond,
|
94 |
#![cfg_attr(test, deny(warnings))]
|
95 |
#![allow(clippy::if_same_then_else)]
|
96 |
#![allow(clippy::len_zero)]
|
78 |
#![deny(rust_2018_idioms)]
|
79 |
#![allow(clippy::if_same_then_else)]
|
80 |
#![allow(clippy::large_enum_variant)]
|
26 |
// Discarded lints
|
27 |
#![allow(clippy::if_same_then_else)]
|
28 |
// Force missing implementations
|
10 |
// Discarded lints
|
11 |
#![allow(clippy::if_same_then_else)]
|
12 |
// Force missing implementations
|
1 |
#![allow(clippy::if_same_then_else)]
|
1 |
#![allow(clippy::needless_bool)]
|
2 |
#![allow(clippy::if_same_then_else)]
|
20 |
clippy::manual_strip,
|
21 |
clippy::if_same_then_else,
|
22 |
clippy::unknown_clippy_lints,
|
92 |
// Doesn't allow for debug statements, etc to be unique
|
93 |
#![allow(clippy::if_same_then_else)]
|
94 |
// Breaks up parallelism that clarifies intent
|
92 |
// Doesn't allow for debug statements, etc to be unique
|
93 |
#![allow(clippy::if_same_then_else)]
|
94 |
// Breaks up parallelism that clarifies intent
|
7 |
// Clippy is confused by the complex configuration
|
8 |
#![allow(clippy::if_same_then_else)]
|
9 |
#![allow(clippy::needless_bool)]
|
55 |
clippy::explicit_auto_deref,
|
56 |
clippy::if_same_then_else,
|
57 |
clippy::inherent_to_string,
|
16 |
clippy::enum_glob_use,
|
17 |
clippy::if_same_then_else,
|
18 |
clippy::inherent_to_string,
|
6 |
clippy::enum_glob_use,
|
7 |
clippy::if_same_then_else,
|
8 |
clippy::inherent_to_string,
|
6 |
clippy::enum_glob_use,
|
7 |
clippy::if_same_then_else,
|
8 |
clippy::inherent_to_string,
|
6 |
// body for readability.
|
7 |
#![allow(clippy::if_same_then_else)]
|
16 |
// body for readability.
|
17 |
#![allow(clippy::if_same_then_else)]
|
18 |
// Purely stylistic, and ignores whether there are explanatory
|
3 |
#![allow(clippy::comparison_chain)]
|
4 |
#![allow(clippy::if_same_then_else)]
|
5 |
#![allow(clippy::vec_init_then_push)]
|
3 |
#![allow(clippy::if_same_then_else)]
|
469 |
{
|
470 |
#![allow(clippy::if_same_then_else)]
|
471 |
if let Rany::Null(_) = self.as_any() {
|
1 |
#![allow(clippy::if_same_then_else)]
|
2 |
#![allow(clippy::len_zero)]
|
30 |
#![allow(clippy::collapsible_else_if)] // Often used to clarify algorithm structure
|
31 |
#![allow(clippy::if_same_then_else)] // Often used to clarify algorithm structure
|
32 |
#![allow(clippy::module_inception)] // The 'line' module has a 'Line' type in it, for example. Makes sense the file is called 'line'...
|
2 |
#![allow(clippy::let_and_return)]
|
3 |
#![allow(clippy::if_same_then_else)]
|
4 |
#![allow(clippy::bool_to_int_with_if)]
|
2 |
#![allow(clippy::bool_to_int_with_if)]
|
3 |
#![allow(clippy::if_same_then_else)]
|
108 |
clippy::len_without_is_empty,
|
109 |
clippy::if_same_then_else,
|
110 |
// Maybe we'll fix these later, but not right now
|
6 |
#![allow(clippy::if_same_then_else)]
|
7 |
#![allow(clippy::missing_inline_in_public_items)]
|
24 |
// This is actually useful to make a bunch of empty branches with different comments in them.
|
25 |
#![allow(clippy::if_same_then_else)]
|
26 |
// This just makes things look much worse.
|
1 |
#![allow(clippy::if_same_then_else)]
|
94 |
#![cfg_attr(test, deny(warnings))]
|
95 |
#![allow(clippy::if_same_then_else)]
|
96 |
#![allow(clippy::len_zero)]
|
191 |
clippy::match_like_matches_macro,
|
192 |
clippy::if_same_then_else,
|
193 |
clippy::collapsible_if,
|
1 |
#![allow(clippy::if_same_then_else)]
|
2 |
#![allow(clippy::never_loop)]
|
23 |
// Doesn't allow for debug statements, etc to be unique
|
24 |
#![allow(clippy::if_same_then_else)]
|
1 |
//! Count trailing zeros
|
2 |
#![allow(clippy::if_same_then_else)]
|
243 |
) {
|
244 |
#![allow(clippy::if_same_then_else)] // false positive
|
245 |
if self.is_forked(global_fork_counter) {
|
130 |
#![deny(rust_2018_idioms)]
|
131 |
#![allow(clippy::if_same_then_else)]
|
132 |
#![allow(clippy::large_enum_variant)]
|
8 |
#![allow(clippy::collapsible_if)]
|
9 |
#![allow(clippy::if_same_then_else)]
|
10 |
#![allow(clippy::absurd_extreme_comparisons)] // FIXME
|
1 |
#![allow(clippy::if_same_then_else)]
|
2 |
#![allow(clippy::needless_bool)]
|
4 |
clippy::from_over_into,
|
5 |
clippy::if_same_then_else,
|
6 |
clippy::float_cmp,
|
14 |
clippy::redundant_closure,
|
15 |
clippy::if_same_then_else,
|
16 |
clippy::new_without_default,
|
15 |
#![allow(
|
16 |
clippy::if_same_then_else,
|
17 |
clippy::needless_bool,
|