Diagnostic

W3302

A call that keeps a state stands in a block that may not run (an `if` or `else` block, a `match` arm, a `state` initializer, the lines after a conditional `return`, `break` or `continue`): legal, and its state moves only on the bars where the block runs.

Kind
WARNING
Raised
While the script is read and checked
Group
Language rules

Message

The message has several forms. The parts in color are filled in with the details of the problem.

{call} moves its state only on the bars where runs; on the other bars its state stays as it wasthis if block{if}this else block{else}this match arm{match}this state initializer{state}this line{exit}this block{block}

Details the message can carry

block, call, else, exit, if, match, state

The code is stable; the wording may change. Back to the index.