mirror of
https://github.com/erg-lang/erg.git
synced 2025-07-07 21:25:31 +00:00
fix: clippy warnings
This commit is contained in:
parent
e4489e5f41
commit
24dd989466
11 changed files with 39 additions and 38 deletions
|
@ -247,7 +247,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
l: &impl Locational,
|
l: &impl Locational,
|
||||||
r: Position,
|
r: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if !self.search.matches(expr) {
|
if !self.search.matches(expr) {
|
||||||
return None;
|
return None;
|
||||||
}
|
}
|
||||||
|
@ -263,7 +263,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
loc: &impl Locational,
|
loc: &impl Locational,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
(loc.loc().contains(pos.loc()) && self.search.matches(expr)).then_some(expr)
|
(loc.loc().contains(pos.loc()) && self.search.matches(expr)).then_some(expr)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -301,7 +301,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
acc: &'e Accessor,
|
acc: &'e Accessor,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
match acc {
|
match acc {
|
||||||
Accessor::Ident(ident) => self.return_expr_if_same(expr, ident.raw.name.token(), pos),
|
Accessor::Ident(ident) => self.return_expr_if_same(expr, ident.raw.name.token(), pos),
|
||||||
Accessor::Attr(attr) => self
|
Accessor::Attr(attr) => self
|
||||||
|
@ -315,7 +315,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
bin: &'e BinOp,
|
bin: &'e BinOp,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if bin.op.loc().contains(pos.loc()) && self.search.matches(expr) {
|
if bin.op.loc().contains(pos.loc()) && self.search.matches(expr) {
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
}
|
}
|
||||||
|
@ -328,7 +328,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
call: &'e Call,
|
call: &'e Call,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
// args: `(1, 2)`, pos: `)`
|
// args: `(1, 2)`, pos: `)`
|
||||||
call.args
|
call.args
|
||||||
.paren
|
.paren
|
||||||
|
@ -344,7 +344,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
.or_else(|| self.return_expr_if_contains(expr, pos, call))
|
.or_else(|| self.return_expr_if_contains(expr, pos, call))
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_expr_from_args<'e>(&'e self, args: &'e Args, pos: Position) -> Option<&Expr> {
|
fn get_expr_from_args<'e>(&'e self, args: &'e Args, pos: Position) -> Option<&'e Expr> {
|
||||||
for arg in args.pos_args.iter() {
|
for arg in args.pos_args.iter() {
|
||||||
if let Some(expr) = self.get_expr(&arg.expr, pos) {
|
if let Some(expr) = self.get_expr(&arg.expr, pos) {
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -368,7 +368,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
def: &'e Def,
|
def: &'e Def,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
self.return_expr_if_same(expr, def.sig.ident().raw.name.token(), pos)
|
self.return_expr_if_same(expr, def.sig.ident().raw.name.token(), pos)
|
||||||
.or_else(|| {
|
.or_else(|| {
|
||||||
def.sig
|
def.sig
|
||||||
|
@ -384,7 +384,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
class_def: &'e ClassDef,
|
class_def: &'e ClassDef,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
class_def
|
class_def
|
||||||
.require_or_sup
|
.require_or_sup
|
||||||
.as_ref()
|
.as_ref()
|
||||||
|
@ -397,7 +397,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
&'e self,
|
&'e self,
|
||||||
block: impl Iterator<Item = &'e Expr>,
|
block: impl Iterator<Item = &'e Expr>,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
for chunk in block {
|
for chunk in block {
|
||||||
if let Some(expr) = self.get_expr(chunk, pos) {
|
if let Some(expr) = self.get_expr(chunk, pos) {
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -411,12 +411,12 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
redef: &'e ReDef,
|
redef: &'e ReDef,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
self.get_expr_from_acc(expr, &redef.attr, pos)
|
self.get_expr_from_acc(expr, &redef.attr, pos)
|
||||||
.or_else(|| self.get_expr_from_block(redef.block.iter(), pos))
|
.or_else(|| self.get_expr_from_block(redef.block.iter(), pos))
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_expr_from_dummy<'e>(&'e self, dummy: &'e Dummy, pos: Position) -> Option<&Expr> {
|
fn get_expr_from_dummy<'e>(&'e self, dummy: &'e Dummy, pos: Position) -> Option<&'e Expr> {
|
||||||
for chunk in dummy.iter() {
|
for chunk in dummy.iter() {
|
||||||
if let Some(expr) = self.get_expr(chunk, pos) {
|
if let Some(expr) = self.get_expr(chunk, pos) {
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -430,7 +430,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
patch_def: &'e PatchDef,
|
patch_def: &'e PatchDef,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
self.return_expr_if_same(expr, patch_def.sig.name().token(), pos)
|
self.return_expr_if_same(expr, patch_def.sig.name().token(), pos)
|
||||||
.or_else(|| self.get_expr(&patch_def.base, pos))
|
.or_else(|| self.get_expr(&patch_def.base, pos))
|
||||||
.or_else(|| self.get_expr_from_block(patch_def.methods.iter(), pos))
|
.or_else(|| self.get_expr_from_block(patch_def.methods.iter(), pos))
|
||||||
|
@ -442,7 +442,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
lambda: &'e Lambda,
|
lambda: &'e Lambda,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if util::pos_in_loc(&lambda.params, util::loc_to_pos(pos.loc())?)
|
if util::pos_in_loc(&lambda.params, util::loc_to_pos(pos.loc())?)
|
||||||
&& self.search.matches(expr)
|
&& self.search.matches(expr)
|
||||||
{
|
{
|
||||||
|
@ -456,7 +456,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
lis: &'e List,
|
lis: &'e List,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if lis.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
if lis.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
||||||
// arr: `[1, 2]`, pos: `]`
|
// arr: `[1, 2]`, pos: `]`
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -472,7 +472,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
dict: &'e Dict,
|
dict: &'e Dict,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if dict.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
if dict.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
||||||
// arr: `{...}`, pos: `}`
|
// arr: `{...}`, pos: `}`
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -498,7 +498,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
record: &'e Record,
|
record: &'e Record,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if record.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
if record.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
||||||
// arr: `{...}`, pos: `}`
|
// arr: `{...}`, pos: `}`
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -516,7 +516,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
set: &'e Set,
|
set: &'e Set,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
if set.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
if set.ln_end() == pos.ln_end() && self.search.matches(expr) {
|
||||||
// arr: `{...}`, pos: `}`
|
// arr: `{...}`, pos: `}`
|
||||||
return Some(expr);
|
return Some(expr);
|
||||||
|
@ -532,7 +532,7 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
tuple: &'e Tuple,
|
tuple: &'e Tuple,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
match tuple {
|
match tuple {
|
||||||
Tuple::Normal(tuple) => {
|
Tuple::Normal(tuple) => {
|
||||||
// arr: `(1, 2)`, pos: `)`
|
// arr: `(1, 2)`, pos: `)`
|
||||||
|
@ -551,14 +551,14 @@ impl<'a> HIRVisitor<'a> {
|
||||||
expr: &'e Expr,
|
expr: &'e Expr,
|
||||||
type_asc: &'e TypeAscription,
|
type_asc: &'e TypeAscription,
|
||||||
pos: Position,
|
pos: Position,
|
||||||
) -> Option<&Expr> {
|
) -> Option<&'e Expr> {
|
||||||
self.get_expr(&type_asc.expr, pos)
|
self.get_expr(&type_asc.expr, pos)
|
||||||
.or_else(|| self.get_expr(&type_asc.spec.expr, pos))
|
.or_else(|| self.get_expr(&type_asc.spec.expr, pos))
|
||||||
.or_else(|| self.return_expr_if_contains(expr, pos, type_asc))
|
.or_else(|| self.return_expr_if_contains(expr, pos, type_asc))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HIRVisitor<'a> {
|
impl HIRVisitor<'_> {
|
||||||
/// Returns the smallest expression containing `token`. Literals, accessors, containers, etc. are returned.
|
/// Returns the smallest expression containing `token`. Literals, accessors, containers, etc. are returned.
|
||||||
pub fn get_info(&self, token: &Token) -> Option<VarInfo> {
|
pub fn get_info(&self, token: &Token) -> Option<VarInfo> {
|
||||||
for chunk in self.hir.module.iter() {
|
for chunk in self.hir.module.iter() {
|
||||||
|
|
|
@ -30,7 +30,7 @@ pub struct InlayHintGenerator<'s, C: BuildRunnable, P: Parsable> {
|
||||||
uri: Value,
|
uri: Value,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'s, C: BuildRunnable, P: Parsable> InlayHintGenerator<'s, C, P> {
|
impl<C: BuildRunnable, P: Parsable> InlayHintGenerator<'_, C, P> {
|
||||||
fn anot(&self, ln: u32, col: u32, cont: String) -> InlayHint {
|
fn anot(&self, ln: u32, col: u32, cont: String) -> InlayHint {
|
||||||
let position = Position::new(ln - 1, col);
|
let position = Position::new(ln - 1, col);
|
||||||
let label = InlayHintLabel::String(cont);
|
let label = InlayHintLabel::String(cont);
|
||||||
|
|
|
@ -5,7 +5,7 @@ use std::env::{current_dir, set_current_dir, temp_dir};
|
||||||
use std::fs::{canonicalize, remove_file, File};
|
use std::fs::{canonicalize, remove_file, File};
|
||||||
use std::io::Write;
|
use std::io::Write;
|
||||||
use std::path::{Path, PathBuf};
|
use std::path::{Path, PathBuf};
|
||||||
use std::process::{Command, ExitStatus, Stdio};
|
use std::process::{Child, Command, ExitStatus, Stdio};
|
||||||
|
|
||||||
use crate::env::opt_which_python;
|
use crate::env::opt_which_python;
|
||||||
use crate::fn_name_full;
|
use crate::fn_name_full;
|
||||||
|
@ -942,30 +942,30 @@ pub fn exec_py(file: impl AsRef<Path>, args: &[&str]) -> std::io::Result<ExitSta
|
||||||
child.wait()
|
child.wait()
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn env_spawn_py(code: &str) {
|
pub fn env_spawn_py(code: &str) -> Child {
|
||||||
if cfg!(windows) {
|
if cfg!(windows) {
|
||||||
Command::new(which_python())
|
Command::new(which_python())
|
||||||
.arg("-c")
|
.arg("-c")
|
||||||
.arg(code)
|
.arg(code)
|
||||||
.spawn()
|
.spawn()
|
||||||
.expect("cannot execute python");
|
.expect("cannot execute python")
|
||||||
} else {
|
} else {
|
||||||
let exec_command = format!("{} -c \"{}\"", which_python(), escape_py_code(code));
|
let exec_command = format!("{} -c \"{}\"", which_python(), escape_py_code(code));
|
||||||
Command::new("sh")
|
Command::new("sh")
|
||||||
.arg("-c")
|
.arg("-c")
|
||||||
.arg(exec_command)
|
.arg(exec_command)
|
||||||
.spawn()
|
.spawn()
|
||||||
.expect("cannot execute python");
|
.expect("cannot execute python")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn spawn_py(py_command: Option<&str>, code: &str) {
|
pub fn spawn_py(py_command: Option<&str>, code: &str) -> Child {
|
||||||
if cfg!(windows) {
|
if cfg!(windows) {
|
||||||
Command::new(py_command.unwrap_or(which_python()))
|
Command::new(py_command.unwrap_or(which_python()))
|
||||||
.arg("-c")
|
.arg("-c")
|
||||||
.arg(code)
|
.arg(code)
|
||||||
.spawn()
|
.spawn()
|
||||||
.expect("cannot execute python");
|
.expect("cannot execute python")
|
||||||
} else {
|
} else {
|
||||||
let exec_command = format!(
|
let exec_command = format!(
|
||||||
"{} -c \"{}\"",
|
"{} -c \"{}\"",
|
||||||
|
@ -976,7 +976,7 @@ pub fn spawn_py(py_command: Option<&str>, code: &str) {
|
||||||
.arg("-c")
|
.arg("-c")
|
||||||
.arg(exec_command)
|
.arg(exec_command)
|
||||||
.spawn()
|
.spawn()
|
||||||
.expect("cannot execute python");
|
.expect("cannot execute python")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -109,7 +109,7 @@ impl From<Str> for String {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> From<Str> for Cow<'a, str> {
|
impl From<Str> for Cow<'_, str> {
|
||||||
fn from(s: Str) -> Self {
|
fn from(s: Str) -> Self {
|
||||||
match s {
|
match s {
|
||||||
Str::Static(s) => Cow::Borrowed(s),
|
Str::Static(s) => Cow::Borrowed(s),
|
||||||
|
|
|
@ -3916,7 +3916,7 @@ impl Context {
|
||||||
candidates: &'m [MethodPair],
|
candidates: &'m [MethodPair],
|
||||||
namespace: &Context,
|
namespace: &Context,
|
||||||
) -> Triple<&'m MethodPair, TyCheckError> {
|
) -> Triple<&'m MethodPair, TyCheckError> {
|
||||||
if candidates.first().is_none() {
|
if candidates.is_empty() {
|
||||||
return Triple::None;
|
return Triple::None;
|
||||||
}
|
}
|
||||||
let matches = candidates
|
let matches = candidates
|
||||||
|
|
|
@ -1415,7 +1415,7 @@ impl Context {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// enumerates all the variables/methods in the current context & super contexts.
|
/// enumerates all the variables/methods in the current context & super contexts.
|
||||||
pub(crate) fn type_dir<'t>(&'t self, namespace: &'t Context) -> Dict<&VarName, &VarInfo> {
|
pub(crate) fn type_dir<'t>(&'t self, namespace: &'t Context) -> Dict<&'t VarName, &'t VarInfo> {
|
||||||
let mut attrs = self.locals.iter().collect::<Dict<_, _>>();
|
let mut attrs = self.locals.iter().collect::<Dict<_, _>>();
|
||||||
attrs.guaranteed_extend(
|
attrs.guaranteed_extend(
|
||||||
self.params
|
self.params
|
||||||
|
@ -1450,7 +1450,7 @@ impl Context {
|
||||||
attrs
|
attrs
|
||||||
}
|
}
|
||||||
|
|
||||||
fn type_impl_dir<'t>(&'t self, namespace: &'t Context) -> Dict<&VarName, &VarInfo> {
|
fn type_impl_dir<'t>(&'t self, namespace: &'t Context) -> Dict<&'t VarName, &'t VarInfo> {
|
||||||
let mut attrs = self.locals.iter().collect::<Dict<_, _>>();
|
let mut attrs = self.locals.iter().collect::<Dict<_, _>>();
|
||||||
attrs.guaranteed_extend(
|
attrs.guaranteed_extend(
|
||||||
self.methods_list
|
self.methods_list
|
||||||
|
|
|
@ -55,7 +55,7 @@ impl<'c, 'l, 'u, L: Locational> Unifier<'c, 'l, 'u, L> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'c, 'l, 'u, L: Locational> Unifier<'c, 'l, 'u, L> {
|
impl<L: Locational> Unifier<'_, '_, '_, L> {
|
||||||
/// ```erg
|
/// ```erg
|
||||||
/// occur(?T, ?T) ==> OK
|
/// occur(?T, ?T) ==> OK
|
||||||
/// occur(?T(<: ?U), ?U) ==> OK
|
/// occur(?T(<: ?U), ?U) ==> OK
|
||||||
|
|
|
@ -1655,14 +1655,14 @@ impl<A: ASTBuildable> GenericASTLowerer<A> {
|
||||||
}
|
}
|
||||||
other => {
|
other => {
|
||||||
let expr = other.map_or("nothing", |expr| expr.name());
|
let expr = other.map_or("nothing", |expr| expr.name());
|
||||||
return Err(LowerErrors::from(LowerError::syntax_error(
|
Err(LowerErrors::from(LowerError::syntax_error(
|
||||||
self.input().clone(),
|
self.input().clone(),
|
||||||
line!() as usize,
|
line!() as usize,
|
||||||
other.loc(),
|
other.loc(),
|
||||||
self.module.context.caused_by(),
|
self.module.context.caused_by(),
|
||||||
format!("expected identifier, but found {expr}"),
|
format!("expected identifier, but found {expr}"),
|
||||||
None,
|
None,
|
||||||
)));
|
)))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
Some(OperationKind::Return | OperationKind::Yield) => {
|
Some(OperationKind::Return | OperationKind::Yield) => {
|
||||||
|
|
|
@ -12,7 +12,7 @@ use crate::varinfo::{AbsLocation, VarInfo};
|
||||||
|
|
||||||
pub struct Members<'a>(MappedRwLockReadGuard<'a, Dict<AbsLocation, ModuleIndexValue>>);
|
pub struct Members<'a>(MappedRwLockReadGuard<'a, Dict<AbsLocation, ModuleIndexValue>>);
|
||||||
|
|
||||||
impl<'a> Members<'a> {
|
impl Members<'_> {
|
||||||
pub fn iter(&self) -> Iter<AbsLocation, ModuleIndexValue> {
|
pub fn iter(&self) -> Iter<AbsLocation, ModuleIndexValue> {
|
||||||
self.0.iter()
|
self.0.iter()
|
||||||
}
|
}
|
||||||
|
|
|
@ -809,7 +809,7 @@ impl SubrType {
|
||||||
let non_defaults = self
|
let non_defaults = self
|
||||||
.non_default_params
|
.non_default_params
|
||||||
.iter()
|
.iter()
|
||||||
.filter(|pt| !pt.name().is_some_and(|n| &n[..] == "self"));
|
.filter(|pt| pt.name().is_none_or(|n| &n[..] != "self"));
|
||||||
let defaults = self.default_params.iter();
|
let defaults = self.default_params.iter();
|
||||||
if let Some(var_params) = self.var_params.as_ref() {
|
if let Some(var_params) = self.var_params.as_ref() {
|
||||||
non_defaults
|
non_defaults
|
||||||
|
|
|
@ -206,7 +206,8 @@ impl New for DummyVM {
|
||||||
let code = include_str!("scripts/repl_server.py")
|
let code = include_str!("scripts/repl_server.py")
|
||||||
.replace("__PORT__", port.to_string().as_str())
|
.replace("__PORT__", port.to_string().as_str())
|
||||||
.replace("__MODULE__", &cfg.dump_filename().replace('/', "."));
|
.replace("__MODULE__", &cfg.dump_filename().replace('/', "."));
|
||||||
spawn_py(cfg.py_command, &code);
|
#[allow(clippy::zombie_processes)]
|
||||||
|
let _ = spawn_py(cfg.py_command, &code);
|
||||||
let addr = SocketAddrV4::new(Ipv4Addr::LOCALHOST, port);
|
let addr = SocketAddrV4::new(Ipv4Addr::LOCALHOST, port);
|
||||||
if !cfg.quiet_repl {
|
if !cfg.quiet_repl {
|
||||||
println!("Connecting to the REPL server...");
|
println!("Connecting to the REPL server...");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue