Range consolidation: Difference between revisions

m
→‎{{header|Wren}}: Changed to Wren S/H
m (syntax highlighting fixup automation)
m (→‎{{header|Wren}}: Changed to Wren S/H)
Line 2,414:
=={{header|Wren}}==
As Wren already has a built-in Range class (which is not quite the same as what's required here), we create a Span class instead.
<syntaxhighlight lang="ecmascriptwren">class Span {
construct new(r) {
if (r.type != Range || !r.isInclusive) Fiber.abort("Argument must be an inclusive range.")
9,482

edits