Skip to main content

Instruction

Enum Instruction 

Source
#[repr(u8)]
pub enum Instruction {
Show 227 variants Cache = 0, BinarySlice = 1, BuildTemplate = 2, BinaryOpInplaceAddUnicode = 3, CallFunctionEx = 4, CheckEgMatch = 5, CheckExcMatch = 6, CleanupThrow = 7, DeleteSubscr = 8, EndFor = 9, EndSend = 10, ExitInitCheck = 11, FormatSimple = 12, FormatWithSpec = 13, GetAIter = 14, GetANext = 15, GetIter = 16, Reserved = 17, GetLen = 18, GetYieldFromIter = 19, InterpreterExit = 20, LoadBuildClass = 21, LoadLocals = 22, MakeFunction = 23, MatchKeys = 24, MatchMapping = 25, MatchSequence = 26, Nop = 27, NotTaken = 28, PopExcept = 29, PopIter = 30, PopTop = 31, PushExcInfo = 32, PushNull = 33, ReturnGenerator = 34, ReturnValue = 35, SetupAnnotations = 36, StoreSlice = 37, StoreSubscr = 38, ToBool = 39, UnaryInvert = 40, UnaryNegative = 41, UnaryNot = 42, WithExceptStart = 43, BinaryOp { op: Arg<BinaryOperator>, }, BuildInterpolation { format: Arg<u32>, }, BuildList { count: Arg<u32>, }, BuildMap { count: Arg<u32>, }, BuildSet { count: Arg<u32>, }, BuildSlice { argc: Arg<BuildSliceArgCount>, }, BuildString { count: Arg<u32>, }, BuildTuple { count: Arg<u32>, }, Call { argc: Arg<u32>, }, CallIntrinsic1 { func: Arg<IntrinsicFunction1>, }, CallIntrinsic2 { func: Arg<IntrinsicFunction2>, }, CallKw { argc: Arg<u32>, }, CompareOp { opname: Arg<ComparisonOperator>, }, ContainsOp { invert: Arg<Invert>, }, ConvertValue { oparg: Arg<ConvertValueOparg>, }, Copy { i: Arg<u32>, }, CopyFreeVars { n: Arg<u32>, }, DeleteAttr { namei: Arg<u32>, }, DeleteDeref { i: Arg<VarNum>, }, DeleteFast { var_num: Arg<VarNum>, }, DeleteGlobal { namei: Arg<u32>, }, DeleteName { namei: Arg<u32>, }, DictMerge { i: Arg<u32>, }, DictUpdate { i: Arg<u32>, }, EndAsyncFor = 68, ExtendedArg = 69, ForIter { delta: Arg<Label>, }, GetAwaitable { where: Arg<u32>, }, ImportFrom { namei: Arg<u32>, }, ImportName { namei: Arg<u32>, }, IsOp { invert: Arg<Invert>, }, JumpBackward { delta: Arg<Label>, }, JumpBackwardNoInterrupt { delta: Arg<Label>, }, JumpForward { delta: Arg<Label>, }, ListAppend { i: Arg<u32>, }, ListExtend { i: Arg<u32>, }, LoadAttr { namei: Arg<LoadAttr>, }, LoadCommonConstant { idx: Arg<CommonConstant>, }, LoadConst { consti: Arg<ConstIdx>, }, LoadDeref { i: Arg<VarNum>, }, LoadFast { var_num: Arg<VarNum>, }, LoadFastAndClear { var_num: Arg<VarNum>, }, LoadFastBorrow { var_num: Arg<VarNum>, }, LoadFastBorrowLoadFastBorrow { var_nums: Arg<VarNums>, }, LoadFastCheck { var_num: Arg<VarNum>, }, LoadFastLoadFast { var_nums: Arg<VarNums>, }, LoadFromDictOrDeref { i: Arg<VarNum>, }, LoadFromDictOrGlobals { i: Arg<u32>, }, LoadGlobal { namei: Arg<u32>, }, LoadName { namei: Arg<u32>, }, LoadSmallInt { i: Arg<u32>, }, LoadSpecial { method: Arg<SpecialMethod>, }, LoadSuperAttr { namei: Arg<LoadSuperAttr>, }, MakeCell { i: Arg<VarNum>, }, MapAdd { i: Arg<u32>, }, MatchClass { count: Arg<u32>, }, PopJumpIfFalse { delta: Arg<Label>, }, PopJumpIfNone { delta: Arg<Label>, }, PopJumpIfNotNone { delta: Arg<Label>, }, PopJumpIfTrue { delta: Arg<Label>, }, RaiseVarargs { argc: Arg<RaiseKind>, }, Reraise { depth: Arg<u32>, }, Send { delta: Arg<Label>, }, SetAdd { i: Arg<u32>, }, SetFunctionAttribute { flag: Arg<MakeFunctionFlag>, }, SetUpdate { i: Arg<u32>, }, StoreAttr { namei: Arg<u32>, }, StoreDeref { i: Arg<VarNum>, }, StoreFast { var_num: Arg<VarNum>, }, StoreFastLoadFast { var_nums: Arg<VarNums>, }, StoreFastStoreFast { var_nums: Arg<VarNums>, }, StoreGlobal { namei: Arg<u32>, }, StoreName { namei: Arg<u32>, }, Swap { i: Arg<u32>, }, UnpackEx { counts: Arg<UnpackExArgs>, }, UnpackSequence { count: Arg<u32>, }, YieldValue { arg: Arg<u32>, }, Resume { context: Arg<ResumeContext>, }, BinaryOpAddFloat = 129, BinaryOpAddInt = 130, BinaryOpAddUnicode = 131, BinaryOpExtend = 132, BinaryOpMultiplyFloat = 133, BinaryOpMultiplyInt = 134, BinaryOpSubscrDict = 135, BinaryOpSubscrGetitem = 136, BinaryOpSubscrListInt = 137, BinaryOpSubscrListSlice = 138, BinaryOpSubscrStrInt = 139, BinaryOpSubscrTupleInt = 140, BinaryOpSubtractFloat = 141, BinaryOpSubtractInt = 142, CallAllocAndEnterInit = 143, CallBoundMethodExactArgs = 144, CallBoundMethodGeneral = 145, CallBuiltinClass = 146, CallBuiltinFast = 147, CallBuiltinFastWithKeywords = 148, CallBuiltinO = 149, CallIsinstance = 150, CallKwBoundMethod = 151, CallKwNonPy = 152, CallKwPy = 153, CallLen = 154, CallListAppend = 155, CallMethodDescriptorFast = 156, CallMethodDescriptorFastWithKeywords = 157, CallMethodDescriptorNoargs = 158, CallMethodDescriptorO = 159, CallNonPyGeneral = 160, CallPyExactArgs = 161, CallPyGeneral = 162, CallStr1 = 163, CallTuple1 = 164, CallType1 = 165, CompareOpFloat = 166, CompareOpInt = 167, CompareOpStr = 168, ContainsOpDict = 169, ContainsOpSet = 170, ForIterGen = 171, ForIterList = 172, ForIterRange = 173, ForIterTuple = 174, JumpBackwardJit = 175, JumpBackwardNoJit = 176, LoadAttrClass = 177, LoadAttrClassWithMetaclassCheck = 178, LoadAttrGetattributeOverridden = 179, LoadAttrInstanceValue = 180, LoadAttrMethodLazyDict = 181, LoadAttrMethodNoDict = 182, LoadAttrMethodWithValues = 183, LoadAttrModule = 184, LoadAttrNondescriptorNoDict = 185, LoadAttrNondescriptorWithValues = 186, LoadAttrProperty = 187, LoadAttrSlot = 188, LoadAttrWithHint = 189, LoadConstImmortal = 190, LoadConstMortal = 191, LoadGlobalBuiltin = 192, LoadGlobalModule = 193, LoadSuperAttrAttr = 194, LoadSuperAttrMethod = 195, ResumeCheck = 196, SendGen = 197, StoreAttrInstanceValue = 198, StoreAttrSlot = 199, StoreAttrWithHint = 200, StoreSubscrDict = 201, StoreSubscrListInt = 202, ToBoolAlwaysTrue = 203, ToBoolBool = 204, ToBoolInt = 205, ToBoolList = 206, ToBoolNone = 207, ToBoolStr = 208, UnpackSequenceList = 209, UnpackSequenceTuple = 210, UnpackSequenceTwoTuple = 211, InstrumentedEndFor = 234, InstrumentedPopIter = 235, InstrumentedEndSend = 236, InstrumentedForIter = 237, InstrumentedInstruction = 238, InstrumentedJumpForward = 239, InstrumentedNotTaken = 240, InstrumentedPopJumpIfTrue = 241, InstrumentedPopJumpIfFalse = 242, InstrumentedPopJumpIfNone = 243, InstrumentedPopJumpIfNotNone = 244, InstrumentedResume = 245, InstrumentedReturnValue = 246, InstrumentedYieldValue = 247, InstrumentedEndAsyncFor = 248, InstrumentedLoadSuperAttr = 249, InstrumentedCall = 250, InstrumentedCallKw = 251, InstrumentedCallFunctionEx = 252, InstrumentedJumpBackward = 253, InstrumentedLine = 254, EnterExecutor = 255,
}
Expand description

A Single bytecode instruction that are executed by the VM.

Currently aligned with CPython 3.14.

§See also

Variants§

§

Cache = 0

§

BinarySlice = 1

§

BuildTemplate = 2

§

BinaryOpInplaceAddUnicode = 3

§

CallFunctionEx = 4

§

CheckEgMatch = 5

§

CheckExcMatch = 6

§

CleanupThrow = 7

§

DeleteSubscr = 8

§

EndFor = 9

§

EndSend = 10

§

ExitInitCheck = 11

§

FormatSimple = 12

§

FormatWithSpec = 13

§

GetAIter = 14

§

GetANext = 15

§

GetIter = 16

§

Reserved = 17

§

GetLen = 18

§

GetYieldFromIter = 19

§

InterpreterExit = 20

§

LoadBuildClass = 21

§

LoadLocals = 22

§

MakeFunction = 23

§

MatchKeys = 24

§

MatchMapping = 25

§

MatchSequence = 26

§

Nop = 27

§

NotTaken = 28

§

PopExcept = 29

§

PopIter = 30

§

PopTop = 31

§

PushExcInfo = 32

§

PushNull = 33

§

ReturnGenerator = 34

§

ReturnValue = 35

§

SetupAnnotations = 36

§

StoreSlice = 37

§

StoreSubscr = 38

§

ToBool = 39

§

UnaryInvert = 40

§

UnaryNegative = 41

§

UnaryNot = 42

§

WithExceptStart = 43

§

BinaryOp

§

BuildInterpolation

Build an Interpolation from value, expression string, and optional format_spec on stack.

oparg encoding: (conversion << 2) | has_format_spec

  • has_format_spec (bit 0): if 1, format_spec is on stack
  • conversion (bits 2+): 0=None, 1=Str, 2=Repr, 3=Ascii

Stack: [value, expression_str, format_spec?] -> [interpolation]

Fields

§format: Arg<u32>
§

BuildList

Fields

§count: Arg<u32>
§

BuildMap

Fields

§count: Arg<u32>
§

BuildSet

Fields

§count: Arg<u32>
§

BuildSlice

§

BuildString

Fields

§count: Arg<u32>
§

BuildTuple

Fields

§count: Arg<u32>
§

Call

Fields

§argc: Arg<u32>
§

CallIntrinsic1

§

CallIntrinsic2

§

CallKw

Fields

§argc: Arg<u32>
§

CompareOp

Fields

§

ContainsOp

Fields

§invert: Arg<Invert>
§

ConvertValue

Fields

§

Copy

Fields

§

CopyFreeVars

Fields

§

DeleteAttr

Fields

§namei: Arg<u32>
§

DeleteDeref

Fields

§

DeleteFast

Fields

§var_num: Arg<VarNum>
§

DeleteGlobal

Fields

§namei: Arg<u32>
§

DeleteName

Fields

§namei: Arg<u32>
§

DictMerge

Fields

§

DictUpdate

Fields

§

EndAsyncFor = 68

§

ExtendedArg = 69

§

ForIter

Fields

§delta: Arg<Label>
§

GetAwaitable

Fields

§where: Arg<u32>
§

ImportFrom

Fields

§namei: Arg<u32>
§

ImportName

Fields

§namei: Arg<u32>
§

IsOp

Fields

§invert: Arg<Invert>
§

JumpBackward

Fields

§delta: Arg<Label>
§

JumpBackwardNoInterrupt

Fields

§delta: Arg<Label>
§

JumpForward

Fields

§delta: Arg<Label>
§

ListAppend

Fields

§

ListExtend

Fields

§

LoadAttr

Fields

§namei: Arg<LoadAttr>
§

LoadCommonConstant

Fields

§

LoadConst

Fields

§consti: Arg<ConstIdx>
§

LoadDeref

Fields

§

LoadFast

Fields

§var_num: Arg<VarNum>
§

LoadFastAndClear

Fields

§var_num: Arg<VarNum>
§

LoadFastBorrow

Fields

§var_num: Arg<VarNum>
§

LoadFastBorrowLoadFastBorrow

Fields

§var_nums: Arg<VarNums>
§

LoadFastCheck

Fields

§var_num: Arg<VarNum>
§

LoadFastLoadFast

Fields

§var_nums: Arg<VarNums>
§

LoadFromDictOrDeref

Fields

§

LoadFromDictOrGlobals

Fields

§

LoadGlobal

Fields

§namei: Arg<u32>
§

LoadName

Fields

§namei: Arg<u32>
§

LoadSmallInt

Fields

§

LoadSpecial

Fields

§

LoadSuperAttr

Fields

§

MakeCell

Fields

§

MapAdd

Fields

§

MatchClass

Fields

§count: Arg<u32>
§

PopJumpIfFalse

Fields

§delta: Arg<Label>
§

PopJumpIfNone

Fields

§delta: Arg<Label>
§

PopJumpIfNotNone

Fields

§delta: Arg<Label>
§

PopJumpIfTrue

Fields

§delta: Arg<Label>
§

RaiseVarargs

Fields

§

Reraise

Fields

§depth: Arg<u32>
§

Send

Fields

§delta: Arg<Label>
§

SetAdd

Fields

§

SetFunctionAttribute

Fields

§

SetUpdate

Fields

§

StoreAttr

Fields

§namei: Arg<u32>
§

StoreDeref

Fields

§

StoreFast

Fields

§var_num: Arg<VarNum>
§

StoreFastLoadFast

Fields

§var_nums: Arg<VarNums>
§

StoreFastStoreFast

Fields

§var_nums: Arg<VarNums>
§

StoreGlobal

Fields

§namei: Arg<u32>
§

StoreName

Fields

§namei: Arg<u32>
§

Swap

Fields

§

UnpackEx

Fields

§

UnpackSequence

Fields

§count: Arg<u32>
§

YieldValue

Fields

§arg: Arg<u32>
§

Resume

Fields

§

BinaryOpAddFloat = 129

§

BinaryOpAddInt = 130

§

BinaryOpAddUnicode = 131

§

BinaryOpExtend = 132

§

BinaryOpMultiplyFloat = 133

§

BinaryOpMultiplyInt = 134

§

BinaryOpSubscrDict = 135

§

BinaryOpSubscrGetitem = 136

§

BinaryOpSubscrListInt = 137

§

BinaryOpSubscrListSlice = 138

§

BinaryOpSubscrStrInt = 139

§

BinaryOpSubscrTupleInt = 140

§

BinaryOpSubtractFloat = 141

§

BinaryOpSubtractInt = 142

§

CallAllocAndEnterInit = 143

§

CallBoundMethodExactArgs = 144

§

CallBoundMethodGeneral = 145

§

CallBuiltinClass = 146

§

CallBuiltinFast = 147

§

CallBuiltinFastWithKeywords = 148

§

CallBuiltinO = 149

§

CallIsinstance = 150

§

CallKwBoundMethod = 151

§

CallKwNonPy = 152

§

CallKwPy = 153

§

CallLen = 154

§

CallListAppend = 155

§

CallMethodDescriptorFast = 156

§

CallMethodDescriptorFastWithKeywords = 157

§

CallMethodDescriptorNoargs = 158

§

CallMethodDescriptorO = 159

§

CallNonPyGeneral = 160

§

CallPyExactArgs = 161

§

CallPyGeneral = 162

§

CallStr1 = 163

§

CallTuple1 = 164

§

CallType1 = 165

§

CompareOpFloat = 166

§

CompareOpInt = 167

§

CompareOpStr = 168

§

ContainsOpDict = 169

§

ContainsOpSet = 170

§

ForIterGen = 171

§

ForIterList = 172

§

ForIterRange = 173

§

ForIterTuple = 174

§

JumpBackwardJit = 175

§

JumpBackwardNoJit = 176

§

LoadAttrClass = 177

§

LoadAttrClassWithMetaclassCheck = 178

§

LoadAttrGetattributeOverridden = 179

§

LoadAttrInstanceValue = 180

§

LoadAttrMethodLazyDict = 181

§

LoadAttrMethodNoDict = 182

§

LoadAttrMethodWithValues = 183

§

LoadAttrModule = 184

§

LoadAttrNondescriptorNoDict = 185

§

LoadAttrNondescriptorWithValues = 186

§

LoadAttrProperty = 187

§

LoadAttrSlot = 188

§

LoadAttrWithHint = 189

§

LoadConstImmortal = 190

§

LoadConstMortal = 191

§

LoadGlobalBuiltin = 192

§

LoadGlobalModule = 193

§

LoadSuperAttrAttr = 194

§

LoadSuperAttrMethod = 195

§

ResumeCheck = 196

§

SendGen = 197

§

StoreAttrInstanceValue = 198

§

StoreAttrSlot = 199

§

StoreAttrWithHint = 200

§

StoreSubscrDict = 201

§

StoreSubscrListInt = 202

§

ToBoolAlwaysTrue = 203

§

ToBoolBool = 204

§

ToBoolInt = 205

§

ToBoolList = 206

§

ToBoolNone = 207

§

ToBoolStr = 208

§

UnpackSequenceList = 209

§

UnpackSequenceTuple = 210

§

UnpackSequenceTwoTuple = 211

§

InstrumentedEndFor = 234

§

InstrumentedPopIter = 235

§

InstrumentedEndSend = 236

§

InstrumentedForIter = 237

§

InstrumentedInstruction = 238

§

InstrumentedJumpForward = 239

§

InstrumentedNotTaken = 240

§

InstrumentedPopJumpIfTrue = 241

§

InstrumentedPopJumpIfFalse = 242

§

InstrumentedPopJumpIfNone = 243

§

InstrumentedPopJumpIfNotNone = 244

§

InstrumentedResume = 245

§

InstrumentedReturnValue = 246

§

InstrumentedYieldValue = 247

§

InstrumentedEndAsyncFor = 248

§

InstrumentedLoadSuperAttr = 249

§

InstrumentedCall = 250

§

InstrumentedCallKw = 251

§

InstrumentedCallFunctionEx = 252

§

InstrumentedJumpBackward = 253

§

InstrumentedLine = 254

§

EnterExecutor = 255

Implementations§

Source§

impl Instruction

Source

pub const fn is_instrumented(self) -> bool

Returns true if this is any instrumented opcode (regular INSTRUMENTED_*, INSTRUMENTED_LINE, or INSTRUMENTED_INSTRUCTION).

Source

pub fn to_instrumented(self) -> Option<Instruction>

Map a base opcode to its INSTRUMENTED_* variant. Returns None if this opcode has no instrumented counterpart.

§Panics (debug)

Panics if called on an already-instrumented opcode.

Source

pub const fn to_base(self) -> Option<Instruction>

Map an INSTRUMENTED_* opcode back to its base variant. Returns None for non-instrumented opcodes, and also for InstrumentedLine / InstrumentedInstruction which are event-layer placeholders without a fixed base opcode (the real opcode is stored in CoMonitoringData).

The returned base opcode uses Arg::marker() for typed fields — only the opcode byte matters since replace_op preserves the arg byte.

Source

pub const fn deopt(self) -> Option<Instruction>

Map a specialized opcode back to its adaptive (base) variant. _PyOpcode_Deopt

Source

pub const fn deoptimize(self) -> Instruction

Map a specialized or instrumented opcode back to its adaptive (base) variant.

Source

pub const fn cache_entries(self) -> usize

Number of CACHE code units that follow this instruction. _PyOpcode_Caches

Trait Implementations§

Source§

impl Clone for Instruction

Source§

fn clone(&self) -> Instruction

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Instruction

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl From<Instruction> for AnyInstruction

Source§

fn from(value: Instruction) -> AnyInstruction

Converts to this type from the input type.
Source§

impl InstructionMetadata for Instruction

Source§

fn label_arg(&self) -> Option<Arg<Label>>

Gets the label stored inside this instruction, if it exists.
Source§

fn is_unconditional_jump(&self) -> bool

Source§

fn is_scope_exit(&self) -> bool

Source§

fn stack_effect_info(&self, oparg: u32) -> StackEffect

Stack effect info for how many items are pushed/popped from the stack, for this instruction.
Source§

fn fmt_dis( &self, arg: OpArg, f: &mut Formatter<'_>, ctx: &impl InstrDisplayContext, expand_code_objects: bool, pad: usize, level: usize, ) -> Result<(), Error>

Source§

fn stack_effect(&self, oparg: u32) -> i32

Stack effect of Self::stack_effect_info.
Source§

fn display(&self, arg: OpArg, ctx: &impl InstrDisplayContext) -> impl Display

Source§

impl TryFrom<u8> for Instruction

Source§

type Error = MarshalError

The type returned in the event of a conversion error.
Source§

fn try_from(value: u8) -> Result<Instruction, MarshalError>

Performs the conversion.
Source§

impl Copy for Instruction

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T, U> ExactFrom<T> for U
where U: TryFrom<T>,

Source§

fn exact_from(value: T) -> U

Source§

impl<T, U> ExactInto<U> for T
where U: ExactFrom<T>,

Source§

fn exact_into(self) -> U

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T, U> OverflowingInto<U> for T
where U: OverflowingFrom<T>,

Source§

impl<T, U> RoundingInto<U> for T
where U: RoundingFrom<T>,

Source§

impl<T, U> SaturatingInto<U> for T
where U: SaturatingFrom<T>,

Source§

impl<T> ToDebugString for T
where T: Debug,

Source§

fn to_debug_string(&self) -> String

Returns the String produced by Ts Debug implementation.

§Examples
use malachite_base::strings::ToDebugString;

assert_eq!([1, 2, 3].to_debug_string(), "[1, 2, 3]");
assert_eq!(
    [vec![2, 3], vec![], vec![4]].to_debug_string(),
    "[[2, 3], [], [4]]"
);
assert_eq!(Some(5).to_debug_string(), "Some(5)");
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T, U> WrappingInto<U> for T
where U: WrappingFrom<T>,

Source§

fn wrapping_into(self) -> U

Source§

impl<T> PyThreadingConstraint for T