[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
common warning id for double->object conversion
From: |
Colin Macdonald |
Subject: |
common warning id for double->object conversion |
Date: |
Wed, 22 Jun 2016 11:07:27 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 |
[moving to maintainers list]
Summary: if you do `sym(1/3)` instead of `sym(1)/3`, we give a warning.
On 22/06/16 08:48, Oliver Heimlich wrote:
There is the exactly same issue in the interval package. If you want
to implement this feature in the construtors (maybe with a regexp
to identify fractions and decimal numbers) we should use the same
warning id.
Good idea. Do you think its appropriate to use the "Octave" namespace?
Maybe something lke:
2. warning("Octave:possible-precision-loss", <custom message>)
3. warning("Octave:lossy-object-from-double", ...)
For `sym` objects its currently:
warning('OctSymPy:sym:rationalapprox', ...
'Using rat() heuristics for double-precision input (is this what you
wanted?)');
(but I'm happy to change it).
Colin
- common warning id for double->object conversion,
Colin Macdonald <=