From 42aa79a197d63cd9280a807e34571ba994b07e62 Mon Sep 17 00:00:00 2001 From: jimenezz22 Date: Thu, 29 Aug 2024 15:05:36 -0600 Subject: [PATCH] fix: latest conflicts --- crates/cairo-lint-core/src/fix.rs | 7 ------- crates/cairo-lint-core/src/plugin.rs | 13 ------------- 2 files changed, 20 deletions(-) diff --git a/crates/cairo-lint-core/src/fix.rs b/crates/cairo-lint-core/src/fix.rs index 960358a3..ff2271f1 100644 --- a/crates/cairo-lint-core/src/fix.rs +++ b/crates/cairo-lint-core/src/fix.rs @@ -4,11 +4,7 @@ use cairo_lang_defs::plugin::PluginDiagnostic; use cairo_lang_filesystem::span::TextSpan; use cairo_lang_semantic::diagnostic::SemanticDiagnosticKind; use cairo_lang_semantic::SemanticDiagnostic; -<<<<<<< HEAD use cairo_lang_syntax::node::ast::{Expr, ExprBinary, ExprMatch, Pattern}; -======= -use cairo_lang_syntax::node::ast::{Expr, ExprIf, ExprMatch, Pattern, Statement}; ->>>>>>> dd9a1c1 (feat: add collapsible_if) use cairo_lang_syntax::node::db::SyntaxGroup; use cairo_lang_syntax::node::kind::SyntaxKind; use cairo_lang_syntax::node::{SyntaxNode, TypedStablePtr, TypedSyntaxNode}; @@ -147,15 +143,12 @@ impl Fixer { self.fix_double_parens(db.upcast(), plugin_diag.stable_ptr.lookup(db.upcast())) } CairoLintKind::DestructMatch => self.fix_destruct_match(db, plugin_diag.stable_ptr.lookup(db.upcast())), -<<<<<<< HEAD CairoLintKind::BreakUnit => self.fix_break_unit(db, plugin_diag.stable_ptr.lookup(db.upcast())), CairoLintKind::BoolComparison => self.fix_bool_comparison( db, ExprBinary::from_syntax_node(db.upcast(), plugin_diag.stable_ptr.lookup(db.upcast())), ), CairoLintKind::CollapsibleIf => self.fix_collapsible_if(db, diag.stable_ptr.lookup(db.upcast())), -======= ->>>>>>> dd9a1c1 (feat: add collapsible_if) _ => "".to_owned(), _ => return None, }; diff --git a/crates/cairo-lint-core/src/plugin.rs b/crates/cairo-lint-core/src/plugin.rs index e03af863..3dabf948 100644 --- a/crates/cairo-lint-core/src/plugin.rs +++ b/crates/cairo-lint-core/src/plugin.rs @@ -2,21 +2,12 @@ use cairo_lang_defs::ids::{FunctionWithBodyId, ModuleId, ModuleItemId}; use cairo_lang_defs::plugin::PluginDiagnostic; use cairo_lang_semantic::db::SemanticGroup; use cairo_lang_semantic::plugin::{AnalyzerPlugin, PluginSuite}; -<<<<<<< HEAD use cairo_lang_semantic::Expr; use cairo_lang_syntax::node::ast::{Expr as AstExpr, ExprBinary}; -======= -use cairo_lang_syntax::node::ast::{Expr, ExprMatch}; -use cairo_lang_syntax::node::ast::ExprIf; ->>>>>>> dd9a1c1 (feat: add collapsible_if) use cairo_lang_syntax::node::kind::SyntaxKind; use cairo_lang_syntax::node::{TypedStablePtr, TypedSyntaxNode}; -<<<<<<< HEAD use crate::lints::{bool_comparison, breaks, double_parens, loops, single_match, collapsible_if}; -======= -use crate::lints::{double_parens, single_match, collapsible_if}; ->>>>>>> dd9a1c1 (feat: add collapsible_if) pub fn cairo_lint_plugin_suite() -> PluginSuite { let mut suite = PluginSuite::default(); @@ -42,14 +33,10 @@ pub fn diagnostic_kind_from_message(message: &str) -> CairoLintKind { single_match::DESTRUCT_MATCH => CairoLintKind::DestructMatch, single_match::MATCH_FOR_EQUALITY => CairoLintKind::MatchForEquality, double_parens::DOUBLE_PARENS => CairoLintKind::DoubleParens, -<<<<<<< HEAD breaks::BREAK_UNIT => CairoLintKind::BreakUnit, bool_comparison::BOOL_COMPARISON => CairoLintKind::BoolComparison, collapsible_if::COLLAPSIBLE_IF => CairoLintKind::CollapsibleIf, -======= - collapsible_if::COLLAPSIBLE_IF => CairoLintKind::CollapsibleIf, ->>>>>>> dd9a1c1 (feat: add collapsible_if) _ => CairoLintKind::Unknown, } }