Skip to content
Bit Quirky Round Trip
Visual Scripting

Search documentation

All topics and APIs

Close returns focus to Search.

What are you looking for?

Try a common topic or enter a complete API identifier.

Browse the reference instead

Esc closes · Tab reaches results · Enter opens the focused link

v0.89.0
Menu

When it refuses

Read the named refusal, keep source unchanged, and choose a safe recovery.

A refusal is a source-safety result. Round Trip found a draft or parsed shape it cannot reproduce faithfully, so it does not write an approximation.

The .cs file stays byte-for-byte unchanged. The draft remains visible, and the compile state records failure. Repair or discard the draft, or make the edit in C# and let Round Trip reparse it.

Use the refusal message to decide whether a draft is incomplete, the source has changed, or the method contains a shape that must stay source-owned. Do not work around the message by deleting code you still need.

The message names the construct or declaration Round Trip declined to rewrite.

  1. Read the complete refusal and identify the named construct or declaration.
  2. Confirm that the .cs file is unchanged.
  3. Repair or undo an incomplete graph draft when the message names a missing input.
  4. For an unsupported source shape, discard the draft, right-click the node that stands for it and choose Go to Source.
  5. Save the C# edit and let Round Trip re-index before starting a new graph draft.

A concurrent file change reports:

{file} changed while compiling; discard and try Compile again.

A parser placeholder reports:

The method contains a construct the parser could not represent ('{placeholderReason}'), so it cannot be regenerated faithfully and was left unchanged.

The internal refusal categories separate the failure stage: UnsupportedConstruct, UnsupportedStatement, PlaceholderPresent, BodyAbsent, MissingSourceMetadata, FormCannotExpressGraph, SegmentationIncomplete, ComposedTextDisagreesWithSource, HandlerStructureInvalid, CatchFilterNotComposable, HandlerBodiesUnresolvable, BranchArmsUnresolvable, BranchConditionMissing, SwitchCaseBodiesUnresolvable, and SwitchJumpTargetMissing.

The visible reason names the actual shape. Examples include:

  • an argument passed by parameter name, an argument marked ref, out, or in, a call to a method taking a params argument list, a lambda passed as an argument, and a generic method group
  • an if statement with an else block, an if statement with no condition, an assignment with no target, and an assignment with no value input
  • a loop built on the canvas whose body was never recorded, a loop with no condition to test, and a statement that reads a loop variable from outside the loop that declares it
  • an array created with a size rather than a list of elements, a multi-dimensional array, a stack-allocated array, an array creation with no recorded element type, and a struct construction with an object initializer
  • a tuple with no elements, a tuple element read with no element recorded, a deconstruction with nothing to take apart, and a deconstruction nested inside another deconstruction
  • a throw with no exception to throw, a throw used as an expression rather than a statement, an object creation with no recorded type, and a target-typed object creation ('new()' with no type written)
  • a using statement, an unsafe block, a fixed statement, a local function declaration, a coalescing assignment (the '??=' operator), a yield return, a yield break, an await foreach loop, and an operation with a missing operand

These labels describe current whole-body writing limits. Source may still be parsed and displayed around an unsupported shape.

Round Trip also refuses a field or enum member inside #if, or a new declaration whose insertion point would land there. It will not edit a field of a partial class when that field is declared in another file. It refuses an attribute edit on a multi-variable declaration such as int a, b;, an attribute it cannot find, or a member or type no longer present in the file.

New fields are refused in structs, records, and interfaces. A new enum cannot have a base type. Whole-enum composition is refused when members share a source line.

For a refusal, it writes no replacement. This source remains unchanged:

When it goes wrong

SymptomCheckFix
The file changed while compilingCompare the open draft with the newest source.Discard the stale draft, reopen the method, and make the edit against current source.
A placeholder blocks body writingRead the construct named on the placeholder.Edit that method in C#, or remove the unsupported shape before graph authoring.
A declaration edit refusesLook for conditional compilation, another partial file, shared declarations, or a missing span.Make that declaration edit directly in C#, then wait for re-indexing.
Full-size image