Project

General

Profile

Actions

Feature #34

open

Missing 'to_decimal' function for Int

Feature #34: Missing 'to_decimal' function for Int

Added by Anonymous over 18 years ago. Updated over 17 years ago.

Status:
Assigned
Priority:
Normal
Assignee:
Category:
Compiler
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Platform:
Resolution:
Triage Stage:

Description

There is a 'abs_to_decimal()' function for Int, but no 'to_decimal()' thus there is one for all other numerical types.

Updated by Alain Prouté over 18 years ago Actions #1

  • Status changed from New to Assigned

The reason was that I did not want to impose some precise formatting for Ints. A default to_decimal may be added to basis.anubis:

public define String
to_decimal
(
Int x
) =
if x < 0 then "-"+abs_to_decimal(x) else abs_to_decimal(x).

Note: I see it's already done in my version of basis.anubis.

Updated by Anonymous over 17 years ago Actions #2

  • Target version changed from 1.9 to 1.10
  • Platform deleted (All)
Actions

Also available in: PDF Atom