Snapshot explicitly selected sequence parameters at entry

Proprietary

Opt-in ownership change: assign owned byte-array snapshots to explicitly selected by-value ReadOnlySequence<byte> parameters before the original body. Require exact source/method selection, complete bindings and explicit ownership review. Preserve signatures and original body nodes. Reject ref/in/out, defaults, attributes, generic methods, unresolved or conditional sources and source shadows. No inference of deferred execution; never included in migration composites.

OpenRewrite.Recipes.CSharp.Migration.Dotnet.Ownership.SnapshotSelectedSequenceParameters

Required

Exact source path, using forward slashes. No globs.

Exact bound key: Owner Method(System.Buffers.ReadOnlySequence<System.Byte>,System.Int32). Fully qualified argument types including generic arguments, with in/ref/out prefixes where present; no wildcards.

Comma-separated exact by-value ReadOnlySequence<byte> parameter names. All must qualify; copies follow declaration order.

Optional

OwnershipPolicyReviewedBoolean

Accept entry allocation, eager value snapshots, changed aliasing and collapsed segment layout for these parameters. Default false. Supply the complete source set for shadow detection.

mod run . --recipe=OpenRewrite.Recipes.CSharp.Migration.Dotnet.Ownership.SnapshotSelectedSequenceParameters \ -P SourcePath='<SourcePath>' \ -P MethodPattern='<MethodPattern>' \ -P ParameterNames='<ParameterNames>'

Required options SourcePath, MethodPattern, ParameterNames have no example to run with. Fill them in above.

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.