canaryThese pages document the canary: an unreleased build. What they describe may not be in the version you have, and may change before it is.The stable build
Try it in your browsercanary Source

BreakLuau✎

Exits the innermost loop. Only valid inside a loop body.

Pending review

Break
  • the language itself, so it works in Roblox and in Lune
  • terminal — it ends the flow it is in

Inputs

  • in:execution

What it compiles to

Script StartFor LoopBodyCompleted1FirstIndex10Last1StepLuau ExpressionfoundCodeBranchTrueFalseConditionBreak
The graph this output was compiled from.
luau
for i = 1, 10 do
	if found then
		break
	end
end

Not reviewed yet