MethodMappingWriter.Clone Method |
Namespace: PostSharp.Sdk.AspectInfrastructure
Assembly: PostSharp.Compiler.Engine (in PostSharp.Compiler.Engine.dll) Version: 2023.0.3.0 (2023.0.3.0)
public virtual MethodMappingWriter Clone()
Return Value
Type: MethodMappingWriterA clone of the current MethodMappingWriter.
Because of optimizations, instances of MethodMappingWriter are stateful. Therefore, the same instance cannot be shared among non-sequential InstructionSequence. A MethodMappingWriter should typically be cloned before using it to emit code in a InstructionSequence following a conditional branching instruction.