mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-28 10:44:36 +08:00
Fix warnings for rust 1.87
This commit is contained in:
1 parent
72dc4954ad
commit
2c02e2776b
3 files changed
+9
-4
No files matched your search
@@ -1165,8 +1165,7 @@ impl<'a, 'b> FunctionCompiler<'a, 'b> {
|
||||
|
||||
// ----- Merge: Return the final result.
|
||||
self.builder.switch_to_block(merge_block);
|
||||
let final_val = self.builder.block_params(merge_block)[0];
|
||||
final_val
|
||||
self.builder.block_params(merge_block)[0]
|
||||
}
|
||||
|
||||
fn compile_ipow(&mut self, a: Value, b: Value) -> Value {
|
||||
|
||||
+7
-1
@@ -15,7 +15,13 @@ pub enum JitCompileError {
|
||||
#[error("bad bytecode")]
|
||||
BadBytecode,
|
||||
#[error("error while compiling to machine code: {0}")]
|
||||
CraneliftError(#[from] ModuleError),
|
||||
CraneliftError(Box<ModuleError>),
|
||||
}
|
||||
|
||||
impl From<ModuleError> for JitCompileError {
|
||||
fn from(err: ModuleError) -> Self {
|
||||
Self::CraneliftError(Box::new(err))
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, thiserror::Error, Eq, PartialEq)]
|
||||
|
||||
+1
-1
@@ -78,7 +78,7 @@ impl StackMachine {
|
||||
|
||||
pub fn run(&mut self, code: CodeObject) {
|
||||
let mut oparg_state = OpArgState::default();
|
||||
code.instructions.iter().try_for_each(|&word| {
|
||||
let _ = code.instructions.iter().try_for_each(|&word| {
|
||||
let (instruction, arg) = oparg_state.get(word);
|
||||
self.process_instruction(instruction, arg, &code.constants, &code.names)
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user