Jump to content

Category talk:Wren-fmt: Difference between revisions

→‎Source code: Minor bug fix.
(→‎Source code: Bug fix plus new method group.)
(→‎Source code: Minor bug fix.)
Line 164:
// Adds 'thousand separators' to a decimal integer or string.
static commatize(n, c) {
if (!(n is Num && n.isInteger) && !isDecimalisDecimal_(n)) Fiber.abort("Argument is not a decimal integer nor string.")
if (!(c is String) || c.count != 1) Fiber.abort("Separator must be a single character string.")
if (n is Num) n = "%(Conv.dec(n))"
9,485

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.